I am adding JButtons to a JToolBar to create the toolbar. For the L&Fs I expected the buttons to be "flat" and highlight their content area when moving the mouse over then have a deeper highlight when the mouse button is pressed. I only get a highlight when I press a button though and then it looks like the highlight sticks to the button.
Thoughts?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hmm, I've never heard of this behavior before. Could you provide a small, standalone test case showing this behavior and post it here? In the meantime I can try to write a small program with a toolbar with both buttons and text components, but there may be something "special" about the way you're creating the toolbar.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I think I figured it out. I was adding the buttons okay (and turning off the border etc. as needed). But the right way to activate the highlighting behavior correctly was to JToolBar.setRollover(true) which I had not set. That made the highlighting work correctly.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
JDK 1.5 update 7.
I am adding JButtons to a JToolBar to create the toolbar. For the L&Fs I expected the buttons to be "flat" and highlight their content area when moving the mouse over then have a deeper highlight when the mouse button is pressed. I only get a highlight when I press a button though and then it looks like the highlight sticks to the button.
Thoughts?
Just a followup note. The standard menus perform highlighting and dehighlighting fine. My toolbar has icons as well as text components in it.
Hmm, I've never heard of this behavior before. Could you provide a small, standalone test case showing this behavior and post it here? In the meantime I can try to write a small program with a toolbar with both buttons and text components, but there may be something "special" about the way you're creating the toolbar.
I think I figured it out. I was adding the buttons okay (and turning off the border etc. as needed). But the right way to activate the highlighting behavior correctly was to JToolBar.setRollover(true) which I had not set. That made the highlighting work correctly.