Microsoft Foundation Classes (mfc.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
CDC::RealizePalette
CDC                                         Up Contents Index Back
──Microsoft Foundation Classes──────────────────────────────────────────────
 
  UINT RealizePalette();
 
  Remarks
 
  Takes entries in the logical palette currently selected  into a device
  context and maps them to the system palette.
 
  A logical color palette acts as a buffer between color-intensive
  applications and the system, allowing an application to use as many
  colors as needed without interfering with its own color display, or with
  colors displayed by other windows.
 
  When a window has input focus and calls the function, Windows ensures
  that it will display all the colors it requests, up to the maximum
  number simultaneously available on the display, and displays colors not
  found in the window's palette by matching them to available colors.
 
  In addition, Windows matches the colors requested by inactive windows
  that call the function as closely as possible to the available colors.
  This significantly reduces undesirable changes in the colors displayed
  in inactive windows.
 
  Return Value
 
  Specifies how many entries in the logical palette were mapped to
  different entries in the system palette. This represents the number of
  entries that this function remapped to accommodate changes in the system
  palette since the logical palette was last realized.
 
  See Also
 
  CPalette, ::RealizePalette
 
 
                                     -♦-