Share via


Gdi::SetPaletteEntries_I (Windows CE 5.0)

Send Feedback

This method sets RGB (red, green and blue) color values and flags in a range of entries in a logical palette.

static WINGDIAPI unsigned int WINAPI SetPaletteEntries_I(HPALETTEhpal,unsigned intiStart,unsigned intcEntries,CONST PALETTEENTRY* lppe);

Parameters

  • hpal
    [in] Handle to the logical palette.

  • iStart
    [in] Unsigned integer that specifies the first logical-palette entry to be set.

    This method fails if iStart is greater than the number of palette entries.

  • cEntries
    [in] Unsigned integer that specifies the number of logical-palette entries to be set.

  • lppe
    [in] Long pointer to the first member of an array of PALETTEENTRY structures containing the RGB values and flags.

Return Values

The number of entries that were set in the logical palette indicates success.

Zero indicates failure.

To get extended error information, call GetLastError.

Remarks

This method is an internal version of the SetPaletteEntries function.

An application can determine whether a device supports palette operations by calling the Gdi::GetDeviceCaps_I method and specifying the RASTERCAPS constant.

Even if a logical palette has been selected and realized, changes to the palette do not affect the physical palette in the surface.

Gdi::RealizePalette_I must be called again to set the new logical palette into the surface.

Requirements

OS Versions: Windows CE .NET 4.0 and later.
Header: Gdi.hpp.

See Also

Gdi | SetPaletteEntries | Gdi::GetDeviceCaps_I | Gdi::GetPaletteEntries_I | Gdi::RealizePalette_I | PALETTEENTRY

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.