From d9aaf8603b6f29c1ad5e273d801ce8202d5b5134 Mon Sep 17 00:00:00 2001 From: Manuel Mall Date: Wed, 9 Nov 2005 11:49:43 +0000 Subject: [PATCH] Fix for Bug 36928 - refresh cached property value if explicitly set twice which can happen for font-size git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@332024 13f79535-47bb-0310-9956-ffa450edef68 --- .../org/apache/fop/fo/StaticPropertyList.java | 3 +++ .../testcases/block_font-size_relative.xml | 19 +++++++++++++++++++ 2 files changed, 22 insertions(+) diff --git a/src/java/org/apache/fop/fo/StaticPropertyList.java b/src/java/org/apache/fop/fo/StaticPropertyList.java index 37699847a..a8455ee9e 100755 --- a/src/java/org/apache/fop/fo/StaticPropertyList.java +++ b/src/java/org/apache/fop/fo/StaticPropertyList.java @@ -53,6 +53,9 @@ public class StaticPropertyList extends PropertyList { */ public void putExplicit(int propId, Property value) { explicit[propId] = value; + if (values[propId] != null) { // if the cached value is set overwrite it + values[propId] = value; + } } /** diff --git a/test/layoutengine/testcases/block_font-size_relative.xml b/test/layoutengine/testcases/block_font-size_relative.xml index 8dc3dbf8c..d12ebfe07 100644 --- a/test/layoutengine/testcases/block_font-size_relative.xml +++ b/test/layoutengine/testcases/block_font-size_relative.xml @@ -118,6 +118,16 @@ + font-size="36pt" + font-size="0.5em" + font-size="0.5em" + font-size="2em" + font-size="2em" + + + + + @@ -163,5 +173,14 @@ + + + + + + + + + -- 2.39.5