diff options
author | Jeremias Maerki <jeremias@apache.org> | 2005-01-20 20:42:53 +0000 |
---|---|---|
committer | Jeremias Maerki <jeremias@apache.org> | 2005-01-20 20:42:53 +0000 |
commit | 9ec34fc861ac7b8892c439454f68bc5c493f69dd (patch) | |
tree | 7b8bbfa1625f6a735e2aa71b536fbbc3eb86c233 /src | |
parent | b0c752ee046d0a4b9e8458ec5cbff27e1b3468be (diff) | |
download | xmlgraphics-fop-9ec34fc861ac7b8892c439454f68bc5c493f69dd.tar.gz xmlgraphics-fop-9ec34fc861ac7b8892c439454f68bc5c493f69dd.zip |
Forgot this one when extending FopImage
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@198297 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src')
-rw-r--r-- | src/java/org/apache/fop/render/ps/PSGraphics2D.java | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/src/java/org/apache/fop/render/ps/PSGraphics2D.java b/src/java/org/apache/fop/render/ps/PSGraphics2D.java index eea3c47cf..7959ce43f 100644 --- a/src/java/org/apache/fop/render/ps/PSGraphics2D.java +++ b/src/java/org/apache/fop/render/ps/PSGraphics2D.java @@ -1,5 +1,5 @@ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Copyright 1999-2005 The Apache Software Foundation. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -394,6 +394,26 @@ public class PSGraphics2D extends AbstractGraphics2D { return 0; } + /** @see org.apache.fop.image.FopImage#getIntrinsicWidth() */ + public int getIntrinsicWidth() { + return (int)(getWidth() * 72000 / getHorizontalResolution()); + } + + /** @see org.apache.fop.image.FopImage#getIntrinsicHeight() */ + public int getIntrinsicHeight() { + return (int)(getHeight() * 72000 / getVerticalResolution()); + } + + /** @see org.apache.fop.image.FopImage#getHorizontalResolution() */ + public double getHorizontalResolution() { + return 72; + } + + /** @see org.apache.fop.image.FopImage#getVerticalResolution() */ + public double getVerticalResolution() { + return 72; + } + } |