From b2e8809004ddddede91ed88fe152a93a28a55e93 Mon Sep 17 00:00:00 2001 From: Nathan Crawford Date: Thu, 14 Apr 2016 19:17:49 -0400 Subject: [PATCH] Added comment about printer resolution, incremented installer version to 2.2.2 --- Installer/EmbroideryReader.wxs | 4 ++-- embroideryReader/frmMain.cs | 9 ++++++++- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/Installer/EmbroideryReader.wxs b/Installer/EmbroideryReader.wxs index 6aa3eff..ba8085c 100644 --- a/Installer/EmbroideryReader.wxs +++ b/Installer/EmbroideryReader.wxs @@ -1,8 +1,8 @@ - - + + diff --git a/embroideryReader/frmMain.cs b/embroideryReader/frmMain.cs index c96390e..60d48a2 100644 --- a/embroideryReader/frmMain.cs +++ b/embroideryReader/frmMain.cs @@ -534,7 +534,14 @@ namespace embroideryReader { if (design != null) { - // Calculate scale values for print graphics object (100 dpi seems to be the default for the printer graphics object) + // Note: scaling based on reported printer DPI may produce terrible results in some + // cases. The reported DPI can even be a negative number, which indicates a general print + // quality. So, future self, for the sake of your sanity... just don't do it. :-) + // See https://msdn.microsoft.com/en-us/library/system.drawing.printing.printerresolution.x(v=vs.110).aspx + // for more detail. + + // Calculate scale values for print graphics object (100 dpi seems to be the default + // for the printer graphics object) double graphicsXScaleFactor = (100.0 / design.NativeDPI); double graphicsYScaleFactor = (100.0 / design.NativeDPI);