Important: The information in this document is obsolete and should not be used for new development.
CopyPalette
Copies entries from one palette to another.
pascal void CopyPalette( PaletteHandle srcPalette, PaletteHandle dstPalette, short srcEntry, short dstEntry, short dstLength);
srcPalette
- A handle to the palette from which colors are copied.
dstPalette
- A handle to the palette to which colors are copied.
srcEntry
- The source palette entry at which copying starts.
dstEntry
- The destination palette entry at which copying starts.
dstLength
- The number of destination palette entries to change.
DISCUSSION
TheCopyPalette
function copies entries from the source palette into the destination palette. The copy operation begins at the values specified by thesrcEntry
anddstEntry
parameters, copying into as many entries as are specified by thedstLength
parameter.CopyPalette
resizes the destination palette when the number of entries after the copy operation is greater than it was before the copy operation.
CopyPalette
does not callActivatePalette
, so your application is free to change the palette a number of times without causing a series of intermediate changes to the color environment. Your application should callActivatePalette
after completing all palette changes.If either of the palette handles is
nil
,CopyPalette
does nothing.