#define RGB_SMOKY_BLUE   MAKERGB (0, 96, 144)
#define COLOR_TABLE_SIZE 256

...

RECT Rectangle = {0}; HPS Presentation_space = WinBeginPaint (Window, 0, &Rectangle);

if (Presentation_space)
{
  COLOR Color_table[COLOR_TABLE_SIZE];
  GpiQueryLogColorTable (Presentation_space, 0, 0, COLOR_TABLE_SIZE, Color_table);

  ULONG Smoky_blue = COLOR_TABLE_SIZE - 1; Color_table[Smoky_blue] = RGB_SMOKY_BLUE;
  GpiCreateLogColorTable (Presentation_space, 0, LCOLF_CONSECRGB, 0, COLOR_TABLE_SIZE, Color_table);

  WinFillRect (Presentation_space, &Rectangle, Smoky_blue);
}

WinEndPaint (Presentation_space);
