Left side picture in the installer

Left side picture in the installer

You can specify a picture to be displayed on the left side of your installer frames, like on the following screenshot:

This picture is specified by a resource whose id shall be Installer.image, such as:

<res id="Installer.image" src="nice-image.png" />

The image must be in a format that Java/Swing can read, such as the common PNG, GIF and JPEG formats. We recommend PNG as this format compresses well without any loss in quality.

A nice feature is that this picture can change depending on the displayed panel. This can be done by suffixing the resource id as follows:

  • Installer.image.n where n is a 0-based index of the displayed panel within the installation, or
  • Installer.image.id where id is the id of the matching panel.

The index-based solution is less flexible than using identifiers, but that is really up to you. You may also combine both styles, although this may cause some maintenance headaches on your side. If you use conditions with panels, you should always use the Installer.image.id version, or panels may not display the intended image.

As an example, here is how we do for IzPack own installer:

<resources>
(...)
    <res src="info-border.png" id="Installer.image.0"/>
    <res src="info-border.png" id="Installer.image.hellopanel"/>
    <res src="info-border.png" id="Installer.image.infopanel"/>
    <res src="info-border.png" id="Installer.image.licencepanel"/>
    <res src="info-border.png" id="Installer.image.targetpanel"/>
    <res src="pack-border.png" id="Installer.image.packspanel"/>
    <res src="pack-border.png" id="Installer.image.summarypanel"/>
    <res src="installing-border.png" id="Installer.image.installpanel"/>
    <res src="installing-border.png" id="Installer.image.shortcutpanel"/>
    <res src="finished-border.png" id="Installer.image.finishpanel"/>
(...)
</resources>

Always specify *Installer.image.0*!

If you opt to change the picture depending on the displayed panel, then you must specify the Installer.image.0 resource.
You will encounter exceptions otherwise.