#ifndef _WX_PRIVATE_H_
#define _WX_PRIVATE_H_
-#define INCL_DOS
+#define INCL_BASE
#define INCL_PM
+#define INCL_GPI
+#define INCL_WINSYS
+#define INCL_SHLERRORS
#include <os2.h>
class WXDLLEXPORT wxFont;
#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 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
// ---------------------------------------------------------------------------
WXDLLEXPORT wxWindow* wxFindWinFromHandle(WXHWND hWnd);
-WXDLLEXPORT void wxGetCharSize(WXHWND wnd, int *x, int *y,wxFont *the_font);
-WXDLLEXPORT void wxFillLogFont(LOGFONT *logFont, wxFont *font);
-WXDLLEXPORT wxFont wxCreateFontFromLogFont(LOGFONT *logFont);
+WXDLLEXPORT void wxGetCharSize(WXHWND wnd, int *x, int *y,wxFont *the_font);
+WXDLLEXPORT void wxFillLogFont( LOGFONT* pLogFont
+ ,PFACENAMEDESC pFaceName
+ ,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);
// 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)
{