This example changes the border color to blue.

#define INCL_WINSYS
#define INCL_GPIBITMAPS  /* for RGB2 structure definition. */
#include <OS2.H>

HWND hwnd;
RGB2 rgb2;   /* Red, green, and blue color index. */
rgb2.bBlue = 200;
rgb2.bGreen = 10;
rgb2.bRed = 5;
rgb2.fcOptions = 0;

WinSetPresParam(hwnd,
                PP_BORDERCOLOR,
                (ULONG)sizeof(RGB2),
                (PVOID)&rgb2);

This example changes the font to 18-point Courier. Note that the length parameter includes 10 characters for the font name and 1 for a null terminator.

#define INCL_WINSYS
#define INCL_GPIBITMAPS /* for RGB structure definition
#include <OS2.H>

HWND hwnd;

WinSetPresParam(hwnd,
                PP_FONTNAMESIZE,
                11,
                (PVOID)"18.Courier");


[Back] [Next]