]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/font.cpp
include jconfig.vc under OS/2 too
[wxWidgets.git] / src / msw / font.cpp
index 8023ed0e3de4400c09b3176408eab011f50e8c46..024e43d3aef7ac2cdbc636bdc4dd1453fe652665 100644 (file)
@@ -476,13 +476,14 @@ int wxNativeFontInfo::GetPointSize() const
     //        for printing!
     const int ppInch = ::GetDeviceCaps(ScreenHDC(), LOGPIXELSY);
 
-    return (int) (((72.0*(double)abs(lf.lfHeight)) / (double) ppInch) + 0.5);
+    // BC++ 2007 doesn't provide abs(long) overload, hence the cast
+    return (int) (((72.0*abs((int)lf.lfHeight)) / (double) ppInch) + 0.5);
 }
 
 wxSize wxNativeFontInfo::GetPixelSize() const
 {
     wxSize ret;
-    ret.SetHeight(lf.lfHeight);
+    ret.SetHeight(abs((int)lf.lfHeight));
     ret.SetWidth(lf.lfWidth);
     return ret;
 }