+ SIZEL vSize = {0, 0};
+ DEVOPENSTRUC vDop = {0L, "DISPLAY", NULL, 0L, 0L, 0L, 0L, 0L, 0L};
+ HDC hDC = ::DevOpenDC( vHabmain
+ ,OD_MEMORY
+ ,"*"
+ ,5L
+ ,(PDEVOPENDATA)&vDop
+ ,NULLHANDLE
+ );
+ M_BRUSHDATA->m_hBrush = (WXHPEN)::GpiCreatePS( vHabmain
+ ,hDC
+ ,&vSize
+ ,PU_PELS | GPIT_MICRO | GPIA_ASSOC
+ );
+ }
+ if (M_BRUSHDATA)
+ {
+ //
+ // Set the color table to RGB mode
+ //
+ if (!::GpiCreateLogColorTable( (HPS)M_BRUSHDATA->m_hBrush
+ ,0L
+ ,LCOLF_RGB
+ ,0L
+ ,0L
+ ,NULL
+ ))
+ {
+ vError = ::WinGetLastError(vHabmain);
+ sError = wxPMErrorToStr(vError);
+ wxLogError("Unable to set current color table to RGB mode. Error: %s\n", sError.c_str());
+ return FALSE;
+ }
+
+ if (M_BRUSHDATA->m_nStyle==wxTRANSPARENT)