Results 1 to 2 of 2
Thread: resize tabs in jtabbedpane
- 08-01-2007, 02:42 PM #1
Member
- Join Date
- Jul 2007
- Posts
- 26
- Rep Power
- 0
- 08-02-2007, 03:02 AM #2
I assume you are adding JLabels to the tabbedPane, each label with an ImageIcon.
Call pack on the top–level container to "fit" the tabbedPane. It will have the size of the largest label/image. Or you can add the tabbedPane to a container whose layout respects the tabbedPanes preferredSize, such as a GridBagLayout.
If an image is too big put the label in a JScrollPane.
Similar Threads
-
Problems with gridBaglayout when I resize the window
By Iyengar in forum AWT / SwingReplies: 1Last Post: 02-16-2008, 11:43 PM -
Adding Tabs to JTabbedPane
By blackstone in forum AWT / SwingReplies: 2Last Post: 11-14-2007, 03:15 PM -
Help with JTabbedPane
By lenny in forum SWT / JFaceReplies: 1Last Post: 08-07-2007, 06:18 AM -
Resize frame
By lenny in forum AWT / SwingReplies: 1Last Post: 07-29-2007, 11:18 PM -
Help with JTextArea, resize windows
By paul in forum AWT / SwingReplies: 1Last Post: 07-16-2007, 04:11 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks