diff options
author | Simon Pepping <spepping@apache.org> | 2008-05-11 18:05:51 +0000 |
---|---|---|
committer | Simon Pepping <spepping@apache.org> | 2008-05-11 18:05:51 +0000 |
commit | 4f78b6a919a39cdfa5635d38dc23355b99818e02 (patch) | |
tree | f03125793cca34c7e744d9f82665ca1636be953e /src/java/org/apache | |
parent | 7085b0c9a97cca2eb7fa1fa4d7a1aa83e9de918c (diff) | |
download | xmlgraphics-fop-4f78b6a919a39cdfa5635d38dc23355b99818e02.tar.gz xmlgraphics-fop-4f78b6a919a39cdfa5635d38dc23355b99818e02.zip |
The spec requires rounding, not truncating
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@655349 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java/org/apache')
-rw-r--r-- | src/java/org/apache/fop/fo/properties/NumberProperty.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/java/org/apache/fop/fo/properties/NumberProperty.java b/src/java/org/apache/fop/fo/properties/NumberProperty.java index 0ba5300ae..aa4791889 100644 --- a/src/java/org/apache/fop/fo/properties/NumberProperty.java +++ b/src/java/org/apache/fop/fo/properties/NumberProperty.java @@ -91,7 +91,7 @@ public final class NumberProperty extends Property implements Numeric { } Number val = p.getNumber(); if (val != null) { - int i = val.intValue(); + int i = Math.round(val.floatValue()); if (i <= 0) { i = 1; } |