Skip to main content

JTabbed Pane - top placement in Nimbus - appearance differs from bottom?

3 replies [Last post]
pauldb
Offline
Joined: 2003-08-30
Points: 0

Hi,
If I place the tabs at the bottom of a JTabbedPane there is a nice blue line across the pane. However, if I place the tabs at the top, the line is missing. I notice in the Java Control Panel, the line does appear even with the tabs placed at the top. Any idea what I'm doing wrong? I am using the tabbed pane in exactly the same way as I do with other look and feels - and with them, the application works fine.

In addition, on Nimbus, the tabbed pane does not seem to calculate the correct preferred size, based on its components, - so when I place it in the north or south of a panel with a border layout, it is too small and the components it contains are sliced rather than shown complete. Again, on other look and feels, the layout works perfectly well; all the components are shown as I would expect them.

I have previously found that JToolBar uses a different layout manager on Nimbus than the default BoxLayout - this means adding glue does not work (there are outstanding bug reports and RFEs related to this).

All of this means that switching to Nimbus entails writing extra code to fix these layout problems. IMHO that breaks the Java idea of "write once, run anywhere". It's a great pity because I really do like the Nimbus look and feel - I would certainly like to offer it as an option for users of my application and, if the above issues could be removed, I would adopt it as the default appearance.

Thanks for your time,
-Paul

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
rogyeu
Offline
Joined: 2006-07-30
Points: 0

Hi Paul,

Thanks for reporting the issue. Could you please submit a bug here:
http://bugreport.sun.com

You may post the incident ID, and I will post back the Bug ID once I've verified the issue.

Thanks,
Roger Y.

pauldb
Offline
Joined: 2003-08-30
Points: 0

Hi Roger,
The incident ID is 1344850.

Before submitting the bug, I did further investigation and found that the problem only occurs if I use SCROLL_TAB_LAYOUT and not WRAP_TAB_LAYOUT.

So, it's a pretty minor bug but, nonetheless, a bug is a bug.

Thanks,
-Paul

rogyeu
Offline
Joined: 2006-07-30
Points: 0

Thanks for reporting the issue. I've confirmed the issue. The Bug ID is 6747580. It may take a day or 2 for the bug to show up in the public bug database.

You can monitor the bug here:
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6747580

Thanks,
Roger Y.