diff options
Diffstat (limited to 'win32')
| -rw-r--r-- | win32/PlatWin.cxx | 4 | 
1 files changed, 3 insertions, 1 deletions
diff --git a/win32/PlatWin.cxx b/win32/PlatWin.cxx index 42b1dae53..11dc5d3ed 100644 --- a/win32/PlatWin.cxx +++ b/win32/PlatWin.cxx @@ -616,7 +616,9 @@ void SurfaceGDI::Init(SurfaceID sid, WindowID wid) {  	Release();  	hdc = static_cast<HDC>(sid);  	::SetTextAlign(hdc, TA_BASELINE); -	logPixelsY = DpiForWindow(wid); +	// Windows on screen are scaled but printers are not. +	const bool printing = ::GetDeviceCaps(hdc, TECHNOLOGY) != DT_RASDISPLAY; +	logPixelsY = printing ? ::GetDeviceCaps(hdc, LOGPIXELSY) : DpiForWindow(wid);  }  void SurfaceGDI::InitPixMap(int width, int height, Surface *surface_, WindowID wid) {  | 
