O'Reilly logo

Eclipse 4 Plug-in Development by Example Beginner's Guide by Dr. Alex Blewitt

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Time for action – using Images in JFace

The TimeZoneLabelProvider can return an Image, which is a standard SWT widget. Although the Image can be loaded (as in the previous chapter), in JFace there are resource registries, which can be used to manage a set of resources for the application. These include the ImageRegistry , FontRegistry , and ColorRegistry classes. The purpose of a resource registry is to maintain a list of Resource instances and ensure that they are correctly disposed, but only when they are no longer needed.

JFace has a set of these global registries; but there are specific ones, such as the ones used by the IDE to maintain a folder and file type icons, for example. These use descriptors to hold a meaning for the resource, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required