Send comments on this topic. | Back to Introduction - All Topics | Help Version 15.03.27
File Formats: Icons and Cursors (ICO and CUR)
    

LEADTOOLS for WPF reads and writes Windows Icon and Cursor files. LEADTOOLS is not designed as an icon editor, but this file support lets you create a bitmap from an icon or cursor, or create an icon or cursor from a bitmap. The library (DLL) to support these formats is the same as for BMP files.

Windows Icon (ICO). This is a multi-page file format for storing one or more Windows icons. The background color when you read these images is always black. The size when you write these images can be no larger than 255-by-255 pixels. (Neither the width nor height can be greater than 255.) You can read and write single-page or multi-page files. You can read and write 16-bit as well.

Vista PNG Icon (ICO). This is a multi-page file format with PNG compression scheme, which reduces the size and maintains the quality of an image. It is a new icon format that comes with Microsoft Windows Vista. You can use size up to 256x256 pixels. It also supports 32 bits with alpha channel.

Windows Cursor (CUR). This is a file format for storing Windows cursors (mouse pointers). The size when you write these images should be exactly 32-by-32 pixels. LEADTOOLS for WPF supports loading and saving multi-page files in this format.

The file constants associated with these file formats are:

WIC Codec CLSID

WIC Codec Subformat RasterImageViewer.Save
File Constant
Read Support Write Support Description
CLSID_WICLeadIcoEncoder WICLeadSubFormatWinIco WinIco 1, 4, 8, 24 BPP 1, 4, 8, 24 BPP Windows Icon.
CLSID_WICLeadIcoEncoder WICLeadSubFormatPngIco PngIco 1, 4, 8, 24, 32 BPP 1, 4, 8, 24, 32 BPP Vista PNG Icon.
CLSID_WICLeadIcoEncoder WICLeadSubFormatWinCur WinCur 1, 4, 8, 24 BPP 1, 4, 8, 24 BPP Windows Cursor.
Required DLL: Leadtools.Codecs.Bmp.Dll. For a listing of the exact DLLs needed, based on the toolkit version, refer to Files To Be Included With Your Application.

Related Formats: ANI - Windows Animated Cursor, CLP - Microsoft Windows Clipboard Format.