You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pdfbox.apache.org by ti...@apache.org on 2016/08/03 16:05:16 UTC

svn commit: r1755093 - /pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/printing/PDFPrintable.java

Author: tilman
Date: Wed Aug  3 16:05:16 2016
New Revision: 1755093

URL: http://svn.apache.org/viewvc?rev=1755093&view=rev
Log:
PDFBOX-3306: only stretch to fit when enabled

Modified:
    pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/printing/PDFPrintable.java

Modified: pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/printing/PDFPrintable.java
URL: http://svn.apache.org/viewvc/pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/printing/PDFPrintable.java?rev=1755093&r1=1755092&r2=1755093&view=diff
==============================================================================
--- pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/printing/PDFPrintable.java (original)
+++ pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/printing/PDFPrintable.java Wed Aug  3 16:05:16 2016
@@ -148,6 +148,12 @@ public final class PDFPrintable implemen
                 {
                     scale = 1;
                 }
+                
+                // only stretch to fit when enabled
+                if (scale < 1 && scaling == Scaling.STRETCH_TO_FIT)
+                {
+                    scale = 1;
+                }
             }
 
             // set the graphics origin to the origin of the imageable area (i.e the margins)