UCWare IconTools for the Java™ platformReading Windows ICO files in JavaIf you need to read a Windows ICO file from Java, UCWare IconTools for the Java platform may come in handy. UCWare IconTools lets you read an icon into memory with just one line of code:
As the result, you get an array of objects that implement the javax.swing.Icon interface. javax.swing.Icon allows for using icons throughout Swing (for instance, you can set icons on JButtons), and also in Java2D for obtaining BufferedImages, and so on. UCWare IconTools supports multi-resolution icons with varying color depths, and also supports alpha channel transparency.
The following code snippet
will display all icons from a single file as buttons:
Javadoc documentation for UCWare IconTools is available here. See also
Download UCWare IconTools
System Requirements
|