]> git.saurik.com Git - wxWidgets.git/commitdiff
always return positive pixel size, even for negative LOGFONT height values
authorVadim Zeitlin <vadim@wxwidgets.org>
Sat, 15 Sep 2007 00:17:58 +0000 (00:17 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Sat, 15 Sep 2007 00:17:58 +0000 (00:17 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@48700 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/msw/font.cpp

index eec88f8c060c4cd94b05e10dfe2759b4c80f1433..024e43d3aef7ac2cdbc636bdc4dd1453fe652665 100644 (file)
@@ -483,7 +483,7 @@ int wxNativeFontInfo::GetPointSize() const
 wxSize wxNativeFontInfo::GetPixelSize() const
 {
     wxSize ret;
-    ret.SetHeight(lf.lfHeight);
+    ret.SetHeight(abs((int)lf.lfHeight));
     ret.SetWidth(lf.lfWidth);
     return ret;
 }