aboutsummaryrefslogtreecommitdiffstats
path: root/src/java
diff options
context:
space:
mode:
authorJeremias Maerki <jeremias@apache.org>2005-07-28 10:08:20 +0000
committerJeremias Maerki <jeremias@apache.org>2005-07-28 10:08:20 +0000
commit45f21578efd0cfd5ad5ad19bf5b441fcfb944c7a (patch)
treecc83d3a927f2611d009c0f7aa0ab925ab40d6ef6 /src/java
parent59f043d46df9f1d49f056eed73274f4d9fc56572 (diff)
downloadxmlgraphics-fop-45f21578efd0cfd5ad5ad19bf5b441fcfb944c7a.tar.gz
xmlgraphics-fop-45f21578efd0cfd5ad5ad19bf5b441fcfb944c7a.zip
Ported an important page setup instruction from the branch. GhostScript, for example, doesn't recognize the page size correctly, otherwise.
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@225739 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java')
-rw-r--r--src/java/org/apache/fop/render/ps/PSRenderer.java8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/java/org/apache/fop/render/ps/PSRenderer.java b/src/java/org/apache/fop/render/ps/PSRenderer.java
index 59a880fe8..4b549cf0c 100644
--- a/src/java/org/apache/fop/render/ps/PSRenderer.java
+++ b/src/java/org/apache/fop/render/ps/PSRenderer.java
@@ -313,7 +313,7 @@ public class PSRenderer extends PrintRenderer {
//PostScript Header
writeln(DSCConstants.PS_ADOBE_30);
- gen.writeDSCComment(DSCConstants.CREATOR, new String[] { userAgent.getProducer() });
+ gen.writeDSCComment(DSCConstants.CREATOR, new String[] {userAgent.getProducer()});
gen.writeDSCComment(DSCConstants.CREATION_DATE, new Object[] {new java.util.Date()});
gen.writeDSCComment(DSCConstants.LANGUAGE_LEVEL, new Integer(gen.getPSLevel()));
gen.writeDSCComment(DSCConstants.PAGES, new Object[] {PSGenerator.ATEND});
@@ -396,6 +396,12 @@ public class PSRenderer extends PrintRenderer {
gen.writeln(Math.round(pspageheight) + " 0 translate");
gen.writeln("90 rotate");
}
+ gen.writeln("<<");
+ gen.writeln("/PageSize ["
+ + Math.round(pspagewidth) + " "
+ + Math.round(pspageheight) + "]");
+ gen.writeln("/ImagingBBox null");
+ gen.writeln(">> setpagedevice");
gen.writeln("0.001 0.001 scale");
concatMatrix(1, 0, 0, -1, 0, pageheight);