]> source.dussan.org Git - xmlgraphics-fop.git/commitdiff
Bugzilla #50899:
authorJeremias Maerki <jeremias@apache.org>
Thu, 5 May 2011 15:38:17 +0000 (15:38 +0000)
committerJeremias Maerki <jeremias@apache.org>
Thu, 5 May 2011 15:38:17 +0000 (15:38 +0000)
Fixed mapping of font weights between CSS values and TextAttribute.WEIGHT_*.
Submitted by: Glenn Adams <glenn.at.skynav.com>

git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@1099845 13f79535-47bb-0310-9956-ffa450edef68

src/java/org/apache/fop/svg/ACIUtils.java
status.xml

index 99590811609523964bff0df002d6a4e96b1c4d35..92dd3f16ffcf683b4c7f92736c3e6aa22140b7ac 100644 (file)
@@ -152,12 +152,14 @@ public final class ACIUtils {
             return 400;
         } else if (weight <= TextAttribute.WEIGHT_SEMIBOLD.floatValue()) {
             return 500;
-        } else if (weight <= TextAttribute.WEIGHT_BOLD.floatValue()) {
+        } else if (weight <  TextAttribute.WEIGHT_BOLD.floatValue()) {
             return 600;
-        } else if (weight <= TextAttribute.WEIGHT_HEAVY.floatValue()) {
+        } else if (weight == TextAttribute.WEIGHT_BOLD.floatValue()) {
             return 700;
-        } else if (weight <= TextAttribute.WEIGHT_EXTRABOLD.floatValue()) {
+        } else if (weight <= TextAttribute.WEIGHT_HEAVY.floatValue()) {
             return 800;
+        } else if (weight <= TextAttribute.WEIGHT_EXTRABOLD.floatValue()) {
+            return 900;
         } else {
             return 900;
         }
index 4e671c6a0fa91bd0aa809995cb62497edd29883a..ea011a16470f28e111605d614320be065864691b 100644 (file)
@@ -59,6 +59,9 @@
       documents. Example: the fix of marks layering will be such a case when it's done.
     -->
     <release version="FOP Trunk" date="TBD">
+      <action context="Renderers" dev="JM" type="fix" fixes-bug="50899" due-to="Glenn Adams">
+        Fixed mapping of font weights between CSS values and TextAttribute.WEIGHT_*. 
+      </action>
       <action context="Renderers" dev="JM" type="fix">
         AFP GOCA: fonts were not embedded from within AFPGraphics2D.
       </action>