summaryrefslogtreecommitdiff
path: root/src/gdiplus/cdwinp.cpp
diff options
context:
space:
mode:
authorscuri <scuri>2010-06-16 21:09:54 +0000
committerscuri <scuri>2010-06-16 21:09:54 +0000
commit483f59d3a55720c8c140aef863f4d34a0d90cca8 (patch)
tree914494291b1870c2b50e7c252c156c91133e9a62 /src/gdiplus/cdwinp.cpp
parent72857b1207600b10bd73e9b1fee479438aae3ac9 (diff)
*** empty log message ***
Diffstat (limited to 'src/gdiplus/cdwinp.cpp')
-rw-r--r--src/gdiplus/cdwinp.cpp15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/gdiplus/cdwinp.cpp b/src/gdiplus/cdwinp.cpp
index 6827f53..013cc9a 100644
--- a/src/gdiplus/cdwinp.cpp
+++ b/src/gdiplus/cdwinp.cpp
@@ -2560,19 +2560,22 @@ static cdAttribute img_points_attrib =
get_img_points_attrib
};
-static BOOL Is_WinXP_or_Later(void)
+static BOOL Is_WinXP_or_WinSrv03(void)
{
OSVERSIONINFO osvi;
ZeroMemory(&osvi, sizeof(OSVERSIONINFO));
osvi.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
GetVersionEx (&osvi);
- BOOL bIsWindowsXPorLater =
+ BOOL bIsWindowsXP =
(osvi.dwPlatformId == VER_PLATFORM_WIN32_NT) &&
- ( (osvi.dwMajorVersion > 5) || ( (osvi.dwMajorVersion == 5) &&
- (osvi.dwMinorVersion >= 1)));
+ ((osvi.dwMajorVersion == 5) && (osvi.dwMinorVersion == 1));
- return bIsWindowsXPorLater;
+ BOOL bIsWindowsServer2003 =
+ (osvi.dwPlatformId == VER_PLATFORM_WIN32_NT) &&
+ ((osvi.dwMajorVersion == 5) && (osvi.dwMinorVersion == 2));
+
+ return bIsWindowsXP || bIsWindowsServer2003;
}
static void set_aa_attrib(cdCtxCanvas* ctxcanvas, char* data)
@@ -2588,7 +2591,7 @@ static void set_aa_attrib(cdCtxCanvas* ctxcanvas, char* data)
{
ctxcanvas->graphics->SetInterpolationMode(InterpolationModeBilinear);
ctxcanvas->graphics->SetSmoothingMode(SmoothingModeAntiAlias);
- if (Is_WinXP_or_Later())
+ if (Is_WinXP_or_WinSrv03())
ctxcanvas->graphics->SetTextRenderingHint(TextRenderingHintClearTypeGridFit);
else
ctxcanvas->graphics->SetTextRenderingHint(TextRenderingHintAntiAliasGridFit);