aspose file tools*
The moose likes Swing / AWT / SWT and the fly likes howto increase row height in JList look and feel Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "howto increase row height in JList look and feel " Watch "howto increase row height in JList look and feel " New topic
Author

howto increase row height in JList look and feel

Rodrigo Alvarez
Ranch Hand

Joined: Apr 10, 2006
Posts: 75
I am trying to create on a custom Swing look and feel for JList with an increased row height, but obviously I'm not doing things correctly : the modification is not correctly taken into account when displaying a JComboBox (the JComboBox uses a JList to display things in its Popup).

Could anybody tell me how to correctly increase the size of a row in a JList Look and Feel


Here is the snipet of my ListUi that increases the row height :



This works perfectly for all the JList I put in my application. In the JComboBox's, the JList correctly uses the increased row height but the size of the Popup containing it is computed using the default row height. For example, if the default row height was 35 and mine was 50 and I had 2 elements in the JCombobox popup, the JList would have 2 rows of height 50 but be displayed in a Popup of total height 70 (and a scroll bar).


Thanks in advance


It is a mistake to think you can solve any major problems just with potatoes.<br />--Douglas Adams
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: howto increase row height in JList look and feel
 
Similar Threads
A better way with the if statement?
cant i change LAF at runtime?
Setting color in a JComboBox
UI Defaults keys
JComboBox Height