about summary refs log tree commit diff
path: root/converter/other/pngtopam.c
diff options
context:
space:
mode:
authorgiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2014-12-25 20:40:38 +0000
committergiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2014-12-25 20:40:38 +0000
commitca4e5d91a96387bc270692f520b5a30c09856c16 (patch)
tree3b90d98f59c6d2e48c68aa07c4768d5a3642b0b1 /converter/other/pngtopam.c
parente8724e9798d00fac3326f03ff9fdd616bdc8fce6 (diff)
downloadnetpbm-mirror-ca4e5d91a96387bc270692f520b5a30c09856c16.tar.gz
netpbm-mirror-ca4e5d91a96387bc270692f520b5a30c09856c16.tar.xz
netpbm-mirror-ca4e5d91a96387bc270692f520b5a30c09856c16.zip
Update Advanced series to 10.69
git-svn-id: http://svn.code.sf.net/p/netpbm/code/advanced@2351 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'converter/other/pngtopam.c')
-rw-r--r--converter/other/pngtopam.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/converter/other/pngtopam.c b/converter/other/pngtopam.c
index e6e68587..59b29f5f 100644
--- a/converter/other/pngtopam.c
+++ b/converter/other/pngtopam.c
@@ -1243,10 +1243,16 @@ warnNonsquarePixels(struct pngx * const pngxP,
             (float)pngx_xPixelsPerMeter(pngxP) / pngx_yPixelsPerMeter(pngxP);
 
         if (r != 1.0) {
-            pm_message ("warning - non-square pixels; "
-                        "to fix do a 'pamscale -%cscale %g'",
-                        r < 1.0 ? 'x' : 'y',
-                        r < 1.0 ? 1.0 / r : r );
+            const char * const baseMsg = "warning - non-square pixels";
+
+            if (pm_have_float_format())
+                pm_message("%s; to fix do a 'pamscale -%cscale %g'",
+                           baseMsg,
+                           r < 1.0 ? 'x' : 'y',
+                           r < 1.0 ? 1.0 / r : r);
+            else
+                pm_message("%s", baseMsg);
+
             *errorLevelP = PNMTOPNG_WARNING_LEVEL;
         }
     }