aboutsummaryrefslogtreecommitdiffstats
path: root/src/org/apache
diff options
context:
space:
mode:
authorKeiron Liddle <keiron@apache.org>2001-08-30 08:50:00 +0000
committerKeiron Liddle <keiron@apache.org>2001-08-30 08:50:00 +0000
commite0f188c784787183e904380600233cb46b8277ff (patch)
tree3329f9c1068c83c4123c56aec0035ea5a0b747e6 /src/org/apache
parentaac8e805444cdd424263675520385813f6290240 (diff)
downloadxmlgraphics-fop-e0f188c784787183e904380600233cb46b8277ff.tar.gz
xmlgraphics-fop-e0f188c784787183e904380600233cb46b8277ff.zip
fixed dasharray units for small values that round to 0
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@194445 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/org/apache')
-rw-r--r--src/org/apache/fop/svg/PDFGraphics2D.java8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/org/apache/fop/svg/PDFGraphics2D.java b/src/org/apache/fop/svg/PDFGraphics2D.java
index f38575d22..e8b3c4a0e 100644
--- a/src/org/apache/fop/svg/PDFGraphics2D.java
+++ b/src/org/apache/fop/svg/PDFGraphics2D.java
@@ -659,7 +659,13 @@ public class PDFGraphics2D extends AbstractGraphics2D {
if (da != null) {
currentStream.write("[");
for (int count = 0; count < da.length; count++) {
- currentStream.write("" + ((int)da[count]));
+ if(((int)da[count]) == 0) {
+ // the dasharray units in pdf are (whole) numbers
+ // in user space units, cannot be 0
+ currentStream.write("1");
+ } else {
+ currentStream.write("" + ((int)da[count]));
+ }
if (count < da.length - 1) {
currentStream.write(" ");
}