+#define STATIC_CLASS _T("STATIC")
+#define STATIC_FLAGS (SS_TEXT|DT_LEFT|SS_LEFT|WS_VISIBLE)
+#define CHECK_CLASS _T("BUTTON")
+#define CHECK_FLAGS (BS_AUTOCHECKBOX|WS_TABSTOP)
+#define CHECK_IS_FAFA FALSE
+#define RADIO_CLASS _T("BUTTON" )
+#define RADIO_FLAGS (BS_AUTORADIOBUTTON|WS_VISIBLE)
+#define RADIO_SIZE 20
+#define RADIO_IS_FAFA FALSE
+#define PURE_WINDOWS
+/* PM has no group box button style
+#define GROUP_CLASS "BUTTON"
+#define GROUP_FLAGS (BS_GROUPBOX|WS_CHILD|WS_VISIBLE)
+*/
+
+/*
+#define BITCHECK_FLAGS (FB_BITMAP|FC_BUTTONDRAW|FC_DEFAULT|WS_VISIBLE)
+#define BITRADIO_FLAGS (FC_BUTTONDRAW|FB_BITMAP|FC_RADIO|WS_CHILD|WS_VISIBLE)
+*/
+
+// ---------------------------------------------------------------------------
+// misc macros
+// ---------------------------------------------------------------------------
+
+#define MEANING_CHARACTER '0'
+#define DEFAULT_ITEM_WIDTH 200
+#define DEFAULT_ITEM_HEIGHT 80
+
+// Scale font to get edit control height
+#define EDIT_HEIGHT_FROM_CHAR_HEIGHT(cy) (3*(cy)/2)
+
+// Generic subclass proc, for panel item moving/sizing and intercept
+// EDIT control VK_RETURN messages
+extern LONG APIENTRY wxSubclassedGenericControlProc(WXHWND hWnd, WXDWORD message, WXWPARAM wParam, WXLPARAM lParam);
+
+// ---------------------------------------------------------------------------
+// constants which might miss from some compilers' headers
+// ---------------------------------------------------------------------------
+
+#if !defined(WS_EX_CLIENTEDGE)
+ #define WS_EX_CLIENTEDGE 0x00000200L
+#endif
+
+#ifndef ENDSESSION_LOGOFF
+ #define ENDSESSION_LOGOFF 0x80000000
+#endif
+
+// ---------------------------------------------------------------------------
+// debug messages -- OS/2 has no native debug output system
+// ---------------------------------------------------------------------------
+
+// ---------------------------------------------------------------------------
+// macros to make casting between WXFOO and FOO a bit easier: the GetFoo()
+// returns Foo cast to the Windows type for oruselves, while GetFooOf() takes
+// an argument which should be a pointer or reference to the object of the
+// corresponding class (this depends on the macro)
+// ---------------------------------------------------------------------------
+
+#define GetHwnd() ((HWND)GetHWND())
+#define GetHwndOf(win) ((HWND)((win)->GetHWND()))
+// old name
+#define GetWinHwnd GetHwndOf
+
+#define GetHdc() ((HDC)GetHDC())
+#define GetHdcOf(dc) ((HDC)(dc).GetHDC())
+
+#define GetHbitmap() ((HBITMAP)GetHBITMAP())
+#define GetHbitmapOf(bmp) ((HBITMAP)(bmp).GetHBITMAP())
+
+#define GetHicon() ((HICON)GetHICON())
+#define GetHiconOf(icon) ((HICON)(icon).GetHICON())
+
+#define GetHaccel() ((HACCEL)GetHACCEL())
+#define GetHaccelOf(table) ((HACCEL)((table).GetHACCEL()))
+
+#define GetHmenu() ((HMENU)GetHMenu())
+#define GetHmenuOf(menu) ((HMENU)menu->GetHMenu())
+
+#define GetHcursor() ((HCURSOR)GetHCURSOR())
+#define GetHcursorOf(cursor) ((HCURSOR)(cursor).GetHCURSOR())
+
+#define GetHfont() ((HFONT)GetHFONT())
+#define GetHfontOf(font) ((HFONT)(font).GetHFONT())
+
+// OS/2 convention of the mask is opposed to the wxWindows one, so we need
+// to invert the mask each time we pass one/get one to/from Windows
+extern HBITMAP wxInvertMask(HBITMAP hbmpMask, int w = 0, int h = 0);
+
+// ---------------------------------------------------------------------------
+// global data
+// ---------------------------------------------------------------------------
+
+// The MakeProcInstance version of the function wxSubclassedGenericControlProc
+WXDLLEXPORT_DATA(extern) wxGenericControlSubClassProc;
+WXDLLEXPORT_DATA(extern wxChar*) wxBuffer;
+WXDLLEXPORT_DATA(extern HINSTANCE) wxhInstance;
+
+// ---------------------------------------------------------------------------
+// global functions
+// ---------------------------------------------------------------------------
+
+extern "C"
+{
+WXDLLEXPORT HINSTANCE wxGetInstance();
+}
+
+WXDLLEXPORT void wxDrawBorder( HPS hPS
+ ,RECTL& rRect
+ ,WXDWORD dwStyle
+ );
+
+WXDLLEXPORT void wxSetInstance(HINSTANCE hInst);
+
+WXDLLEXPORT wxWindow* wxFindWinFromHandle(WXHWND hWnd);
+
+WXDLLEXPORT void wxGetCharSize(WXHWND wnd, int *x, int *y,wxFont *the_font);
+WXDLLEXPORT void wxFillLogFont( LOGFONT* pLogFont
+ ,PFACENAMEDESC pFaceName
+ ,HPS* phPS
+ ,bool* pbInternalPS
+ ,long* pflId
+ ,wxString& sFaceName
+ ,wxFont* pFont
+ );
+WXDLLEXPORT wxFontEncoding wxGetFontEncFromCharSet(int nCharSet);
+WXDLLEXPORT void wxOS2SelectMatchingFontByName( PFATTRS vFattrs
+ ,PFACENAMEDESC pFaceName
+ ,PFONTMETRICS pFM
+ ,int nNumFonts
+ ,const wxFont* pFont
+ );
+WXDLLEXPORT wxFont wxCreateFontFromLogFont( LOGFONT* pLogFont
+ ,PFONTMETRICS pFM
+ ,PFACENAMEDESC pFace
+ );
+WXDLLEXPORT int wxGpiStrcmp(char* s0, char* s1);
+
+WXDLLEXPORT void wxSliderEvent(WXHWND control, WXWORD wParam, WXWORD pos);
+WXDLLEXPORT void wxScrollBarEvent(WXHWND hbar, WXWORD wParam, WXWORD pos);
+
+// Find maximum size of window/rectangle
+WXDLLEXPORT extern void wxFindMaxSize(WXHWND hwnd, RECT *rect);
+
+WXDLLEXPORT wxWindow* wxFindControlFromHandle(WXHWND hWnd);
+WXDLLEXPORT void wxAddControlHandle(WXHWND hWnd, wxWindow *item);
+
+// Safely get the window text (i.e. without using fixed size buffer)
+WXDLLEXPORT extern wxString wxGetWindowText(WXHWND hWnd);
+
+// get the window class name
+WXDLLEXPORT extern wxString wxGetWindowClass(WXHWND hWnd);
+
+// get the window id (should be unsigned, hence this is not wxWindowID which
+// is, for mainly historical reasons, signed)
+WXDLLEXPORT extern WXWORD wxGetWindowId(WXHWND hWnd);
+
+// Convert a PM Error code to a string
+WXDLLEXPORT extern wxString wxPMErrorToStr(ERRORID vError);
+
+// Does this window style specify any border?
+inline bool wxStyleHasBorder(long style)
+{
+ return (style & (wxSIMPLE_BORDER | wxRAISED_BORDER |
+ wxSUNKEN_BORDER | wxDOUBLE_BORDER)) != 0;
+}
+
+inline RECTL wxGetWindowRect(HWND hWnd)
+{
+ RECTL vRect;
+
+ ::WinQueryWindowRect(hWnd, &vRect);
+ return vRect;
+} // end of wxGetWindowRect
+
+WXDLLEXPORT extern void wxOS2SetFont( HWND hWnd
+ ,const wxFont& rFont
+ );
+
+
+WXDLLEXPORT extern bool wxCheckWindowWndProc( WXHWND hWnd
+ ,WXFARPROC fnWndProc
+ );
+