Carbon


CIcon

Header: Icons.h

struct CIcon {
    PixMap iconPMap; 
    BitMap iconMask; 
    BitMap iconBMap; 
    Handle iconData; 
    SInt16 iconMaskData[1];
};
typedef CIcon CIconPtr;

Field descriptions

iconPMap

The pixel map describing the icon. Note that this is a pixel map record, not a handle to a pixel map record.

iconMask

A bitmap of the icon’s mask.

iconBMap

A bitmap of the icon.

iconData

A handle to the icon’s pixel image.

iconMaskData

An array containing the icon’s mask data followed by the icon’s bitmap data. This is used only when the icon is stored as a resource.

The PlotCIcon, PlotCIconHandle, GetCIcon, and DisposeCIcon functions all use the CIconHandle data type to refer to a color icon structure. A color icon structure contains information about a color icon. The CIcon data type defines a color icon structure.

All color icon resources should be marked purgeable. You can use icons of resource type 'cicn' in menus the same way that you use resources of type 'ICON'. If a menu item specifies an icon number, the menu definition function first tries to load in a 'cicn' resource with the specified resource ID. If it doesn’t find one, the menu definition function tries to load in an 'ICON' resource with the same ID. The Dialog Manager also uses a 'cicn' resource instead of an 'ICON' resource if it finds one with the same resource ID.


© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)