-
Java Action
Hello
I started to play with and use the Java Action, which is supposeldy a nice way of sharing attributes between Buttons and Menus and the like, they take there text and images from the action, and the neat thing is you disable the action, and it disables the component that the action is sat in.
Marvellous i thought.....
except, and i might be missing something.. I add my action to a JMenuItem and a JButton
the JButton is on a toolbar the menu ina menu, how do i supress the Text on the Jbutton and or toggle between no text showing and the action provided text showing? seems like a sebsible request i think?!
Any ideas?
Cheers in advance
Andy
-
This is strange. I have an XML-based UI system which generates the actions, menu items and buttons for me. The buttons don't show the text, they just show the image.
I use JToolBar.add(Action) though.
-
ah hah!
in thats case its my fault!, i thought you had to make buttons and then add them to the toolbar, i never even considered adding the action to the toolbar instead!
D'OH!!!!
marvellous, thanks you