• Post Reply Bookmark Topic Watch Topic
  • New Topic

Get the standards icons

 
Jean-Yves Tinevez
Greenhorn
Posts: 22
Eclipse IDE Mac Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Halo!

I would like to get the icons displayed by JOptionPane when it prompts a warning message, a question message, etc...

I can't find a method that would return these icons. I looked at the source of JOptionPane, but i couldn't find any trace of my icons there.

How can i extract these default icons from the jdk in my classes?

Thank you
jy
 
Michael Dunn
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
UIManager.getIcon("OptionPane.errorIcon");
UIManager.getIcon("OptionPane.informationIcon");
UIManager.getIcon("OptionPane.warningIcon");
UIManager.getIcon("OptionPane.questionIcon");
 
Jean-Yves Tinevez
Greenhorn
Posts: 22
Eclipse IDE Mac Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you!

Do you know where a documentation on these default keys can be found? Even in the source i've found nothing.

See you
jy
 
Michael Dunn
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
don't know about any docs, I just use rob camick's ShowUIDefaults program

http://www.discoverteenergy.com/files/ShowUIDefaults.java
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!