views:

43

answers:

1

I want to display a JToolbar within right side of a split pane, which is also going to contain a JTabbedPane, how can we do that ? wrap TabbedPane and toolbar in some component? ps: user should not be able to minimize, etc in right side pane...

+3  A: 

Put a JPanel on the right side of the split pane.

Give the JPanel a BorderLayout.

Add the JToolbar to the NORTH of the JPanel, and the JTabbedPane to the CENTER.

Carl Smotricz
What Mr. Smotricz said. There's basically no penalty in Swing for wrapping components within components within components, and often you can do everything you need just by nesting an arbitrary number of `BorderLayout` `JPanels`.
David Moles