How do I put a icon on java applications?

独自空忆成欢 提交于 2020-01-16 12:02:15

问题


I have a question. I have a really cool game that I have made in eclipse. In order for people to execute it I want to convert it to a executable jar. Although I want the jar to have a icon like most .exe programs, although I don't know how to do that. What is the way that most people put icons on their java programs? I have converted it to a .exe with a icon before but I want to know if there is another way


回答1:


The jar is not really an executable from the OS point of view - it is just an archive of compiled classes and resources. But there is a way to accomplish what you wish for. You have to use executable wrapper.

Here are few of them:

JSmooth: http://jsmooth.sourceforge.net/

Launch4j: http://launch4j.sourceforge.net/

JWrapper: http://www.jwrapper.com/java-to-exe-free.html




回答2:


Java Web Start will allow you to do this. It offers many advantages, including handling automatic updates and even integration with the desktop's application menu (which is the Start menu in Windows). One of its biggest advantages, in my opinion, is that it comes with every Java installation, so no third-party libraries are required.



来源:https://stackoverflow.com/questions/18289511/how-do-i-put-a-icon-on-java-applications

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!