Solaris Common Desktop Environment: User's Guide

Saving Icon Files

When saving icon files, you must use the appropriate file-name suffix. There are two suffixes appended to the base name of the icon, one for size and one for format. Many icon names are in these general forms:

basename.size.format
 basename.format

The basename is the image name used to reference the image.

size is a single letter indicating the standard size of the icon: l for large (48x48 pixels), m for medium (32x32), s for small (24x24), or t for tiny (16x16). ("Icon Size Conventions") If your icon is not a standard size, you can omit this letter.

format is pm for X pixmaps (the color icon format) or bm for X bitmaps (the monochrome icon format).

If you save an icon in XBM format that has transparent color in it, an icon mask file is also saved. The icon mask file is named basename.size_m.format. If you move the icon you saved to another folder, you must also move the mask file.

For example, suppose you specify an icon named mail for a file type you've written. If you have a color display and have set the File Manager preferences to use tiny icons, the assumed icon name is mail.t.pm. If it had transparent color and you saved it in XBM format, two files would be created: mail.t.bm and mail.t_m.bm.

Icon Size Conventions

Table 13-3 lists the recommended sizes--in pixels, width x height--for creating new icons for use in CDE. Icons can be up to 256x256.

Table 13-3 Icon Size Recommendations

Usage 

High 

Medium 

Low 

File Manager (Large) 

32x32 

32x32 

32x32 

File Manager (Small) 

16x16 

16x16 

16x16 

Application Manager (Large) 

32x32 

32x32 

32x32 

Application Manager (Small) 

16x16 

16x16 

16x16 

Front Panel 

48x48 

48x48 

32x32 

Front Panel subpanels 

32x32 

32x32 

16x16 

Minimized windows 

48x48 

48x48 

32x32 

Workspace 

32x32 

32x32 

32x32 

To Save the Icon

  1. Choose an output format from the Options menu:

    • XBM for two-color X bitmap format

    • XPM for multicolor X pixmap format (the default)

  2. Choose Save from the File menu.

    If the icon is unnamed or you choose Save As, Icon Editor prompts you for a file name. Type the name and then click Save.


    Note -

    If you save an icon in XBM format that has transparent color in it, an icon mask file is also saved. The icon mask file is named basename.size_m.format. If you move the icon you saved to another folder, you must also move the mask file.


To Save the Icon with a New Name

  1. Choose Save As from the File menu.

  2. Type (or select) the file name under which you want to save the icon file.

  3. Click Save.

    If the file already exists, you will need to click OK in the warning dialog box to overwrite the existing file.