PDA

View Full Version : SplitBar Example needed



bryans99
5 May 2009, 7:10 AM
Does anyone have or can point me to an example of using the Ext.SplitBar (aside from the BorderLayout which I don't currently have the expertise to understand)?

I need to create a component where I can arrange N number of panels either vertically or horizontally and allow each one to be resized either horizontally or vertically such that adjacent panel takes or gives space according to the direction that the splitbar is being moved.

I was surprised to find that the "hbox" and "vbox" layouts did not automatically give me this feature (or am I missing something?).

I know I can do it by nesting panels with BorderLayout inside of each other (if I need 5 panels horizontally I will nest a second BorderLayout panels inside of the "east" region of the first pane, the second panel will only have the "west" and "center" regions). However, this solution just doesn't seem elegant although its probably the way I will go.

Its possible I can do something with Ext.Resizable as well although its resize bar is inconsistent with the SplitBar look.

Any help or suggestions would be appreciated. Thanks.

5 May 2009, 7:23 AM
Welcome to the forum.

The google search may help (see top right of this forum).

Here is a link:
http://www.google.com/cse?cx=001733999371871106761%3Ajgc8jk2xgwe&ie=UTF-8&q=splitbar&sa=Search

Condor
5 May 2009, 7:24 AM
No, HBox and VBox don't have splitter support, but this extension (http://www.extjs.com/forum/showthread.php?t=65982) does.

bryans99
5 May 2009, 8:06 AM
Perfect!

Exactly what I needed for Horizontal. I don't suppose you have the equivalent for a vertical container? :D