Mae Tan

Greenhorn
+ Follow
since Sep 03, 2010
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Mae Tan

Thanks for the replies. I just wanted to make sure it was not some NetBeans settings that I have to apply and haven't figured out yet.
13 years ago
Hi.

I have a JPanel that I've customized with components, i.e. buttons laid out with gridbag, using Matisse. When I use this custom panel in another panel still using Matisse, I find that none of the buttons on my custom panel appear. When I look into the Matisse code, I see that my custom panel has been applied with GroupLayout. Is there a way to stop Matisse from doing this? Is it possible to use a custom panel that has already been laid out with components in Matisse?

Thanks,
Mae
13 years ago
Thanks Sean! I think I will go with your solution. It does save me from making an overhaul in an application that has already come to expect null when the first selection item is selected. Much appreciated.

As a side note, I wonder why null is not considered a valid selection item. This is more a bug than a feature.

My issue now is how to get the null item selected with a return and not a mouse action. When selecting "test1" or a non-null item, you can press return. For the null item, you have to do an Esc.
13 years ago
Ok, thanks for looking into this. Will modify as you suggest.
13 years ago

What is the point of this? Why do you need an empty or null object?



The null object is to allow the user to not set a value to the field that the combobox represents. Is it possible to browse the items on a combobox and not make a selection? Or am I using the wrong UI component?
13 years ago
Sorry, first addItem should read:

cb.addItem(null);

13 years ago
Hi Pete!

Below is program demonstrating my problem. When the combobox receives focus, the arrow navigation does not work. I would like to maintain the null first element rather than have an empty string as the code is already widely used.



Thanks,
Mae
13 years ago
Hi!

Is there a way to get arrow navigation to work on a JComboBox with a null first item?

Thanks,
Mae
13 years ago