+ case wxNORMAL:
+ nItalic = 0;
+ break;
+ }
+ pFaceName->flOptions |= nItalic;
+ if(pFont->GetUnderlined())
+ pLogFont->fsSelection |= FATTR_SEL_UNDERSCORE;
+
+ //
+ // In PM a font's height is expressed in points. A point equals
+ // approximately 1/72 of an inch. We'll assume for now that,
+ // like Windows, that fonts are 96 dpi.
+ //
+ DEVOPENSTRUC vDop = {0L, "DISPLAY", NULL, 0L, 0L, 0L, 0L, 0L, 0L};
+ HDC hDC = ::DevOpenDC(vHabmain, OD_MEMORY, "*", 5L, (PDEVOPENDATA)&vDop, NULLHANDLE);
+ LONG lStart = CAPS_FAMILY;
+ LONG lCount = CAPS_VERTICAL_RESOLUTION;
+ LONG alArray[CAPS_VERTICAL_RESOLUTION];
+ LONG lRes;
+ int nPpInch;
+
+
+ ::DevQueryCaps(hDC, lStart, lCount, alArray);
+ lRes = alArray[CAPS_VERTICAL_RESOLUTION-1];
+ if (lRes > 0)
+ nPpInch = (int)(lRes/39.6); // lres is in pixels per meter
+ else
+ nPpInch = 96;
+
+ int nHeight = (pFont->GetPointSize() * nPpInch/72);
+ wxString sFacename = pFont->GetFaceName();
+
+ if (!!sFacename)