Sun Microsystems, Inc.
spacerspacer
spacer www.sun.com docs.sun.com |
spacer
black dot
 
 
15.  Using Icon Editor Basic Drawing Tasks Drawing Tools  Previous   Contents   Next 
   
 

To Undo a Drawing Operation

  • Choose Undo from the Edit menu.

Only the single, most recent change can be undone.

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 15-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 15-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.

Color Usage

Icons in the desktop use a palette of 22 colors:

  • Eight static grays

  • Eight static colors: red, blue, green, cyan, magenta, yellow, black, and white

  • Five dynamic colors: Foreground, Background, TopShadow, BottomShadow, and Select

  • A transparent "color" that allows the background to show through

These colors are the default colors in Icon Editor. This set of colors provides a reasonable palette with which to create icons. This limited palette was chosen to maximize the attractiveness and readability of icons without using an unnecessary number of colors.

The dynamic colors represent the colors used to display the application on which your icon will appear. If your icon appears in File Manager, File Manager determines what the background color is. Dynamic colors are useful for icons that you want to change color as different color palettes are selected in Style Manager. Dynamic colors are also useful if the icon will be used in more than one place and you want it to use the colors of the application where it appears.

TopShadow and BottomShadow can be used for drawing a shadow under your icon. You can use these colors to make the icon appear to be etched into the surface. This is only recommended for Front Panel style icons.

The transparent color is useful for creating icons that have the illusion of being nonrectangular, since it allows the color behind the icon to show through. If your icon does not fill the entire bounding box, you should fill the unused area with the transparent color.

Advanced Drawing Tasks

After you become familiar with the basic drawing facilities in Icon Editor, you may want to try some more advanced operations. Many of these operations require you to first select an area of the icon. This is done using the Selection tool (next to the eraser).

When an area of the icon is selected, you can:

  • Cut, copy or move it

  • Resize (scale) it

  • Flip it (horizontally or vertically)

  • Rotate it (right or left)

 
 
 
  Previous   Contents   Next