I am trying to fix a problem with my application that has been bugging me for a while. The icon is extremely ugly. So I have been doing a lot of research on best practices, and have come to this solution after a lot of research:
public class myApp extends JFrame {
List<Image> icons = new ArrayList<Image>();
Toolkit toolkit = Toolkit.getDefaultToolkit();
public myApp() {
icons.add(toolkit.getImage("/images/16x16.png"));
icons.add(toolkit.getImage("/images/32x32.png"));
icons.add(toolkit.getImage("/images/64x64.png"));
icons.add(toolkit.getImage("/images/128x128.png"));
setIconImages(icons);
}
}
I get the default coffee cup with this. Does anyone know why this isn't working? Search engines keep on autocorrecting setIconImages to setIconImage... not finding a lot.
Edit: Changing the sizes did not help.