Autoscroll on parent panel, when there is overflow on child panels.Extjs
I'm having a single Parent Panel, which has 2 child panels. One has content dynamically created, while the other is fixed height and width. The Parent panel is using border layout, with center and east regions defined. I'm trying to get autoscroll to trigger on the parent panel when there is an overflow on on the center region panel开发者_运维知识库. I've set the autoscroll option to true to the parent panel, but everytime there is an overflow on the center panel, it just gets cuts off. When I'm adding an overflow to center region panel, i get a scrollbar for that panel alone. I don't need that, but rather I want it on the entire Parent Panel. Let me know if anyone has any suggestions..
This issue is usually a result of over-nesting Panels, and/or one or more Panels in the layout not having a layout
config specified. Some layout configuration code would help.
Here is my view from what I understood.. You have two panels that go into the center region of the border layout.. and you need a scroll bar for the center when one of the panels overflow.
Here is how I worked out a similar situation. In my center region, I have a panel with autoScroll set to true. I have two panels added to this panel. The first is fixed height (its a grid) and second is panel (displayed below the grid) is a large form panel. Due to the parent panel having a autoScroll property set, you will have a scroll bar for the entire panel and not the second panel alone!
I don't think you can use fit layout. In fit layout, the panel will take up the whole area of its container and you will not be able to add another panel (the second panel will be hidden I suppose!).
Note: I am using the default layout (Container Layout) I do not specify any layout in my parent panel.
精彩评论