Search code examples
javaswinginstallationiconswindow-managers

Java: Replacing the coffee cup icon in the top-left corner of the Window


Java Swing applications by default have the Java coffee cup icon appear in the top left corner of the application.

I would like to replace this with my own image - what API is used?

Can this be done at run time, or must something be done at install time?

Thanks!


Solution

  • JFrame.setIconImage(Image image) does exactly that.