Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

How to set Icon on MenuItem

 
Salim Tol
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator


How to Set an Icon on MenuItem.

Here, I am talking about MenuItem not JMenuItem!!!.
 
Rob Spoor
Sheriff
Posts: 20822
68
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can't through the regular methods. AWT simply isn't that advanced. And since MenuItem does not extend Component directly or indirectly you also can't override paint to do this - because there is no paint method for MenuItem.

I take it you want to use TrayIcon and SystemTray? Otherwise I would see no reason to use MenuItem.
 
Salim Tol
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator


Yes, I want to use TrayIcon and SystemTray.
I want to use MenuItem with icon in PopupMenu?How?
 
Darryl Burke
Bartender
Posts: 5155
11
Java Netbeans IDE Opera
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Cross posted
http://forums.sun.com/thread.jspa?threadID=5449451
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!