aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorAndreas L. Delmelle <adelmelle@apache.org>2008-02-10 13:42:39 +0000
committerAndreas L. Delmelle <adelmelle@apache.org>2008-02-10 13:42:39 +0000
commitc29d8e5488fa1b749647f2e5f35129271b2dae48 (patch)
tree1b16fa21bef93b4964c9290311974ba49d32e160 /test
parent4b584311505ac639952ec29d9983161b5682b80a (diff)
downloadxmlgraphics-fop-c29d8e5488fa1b749647f2e5f35129271b2dae48.tar.gz
xmlgraphics-fop-c29d8e5488fa1b749647f2e5f35129271b2dae48.zip
Bugzilla 41631: Percentage resolution for arguments to proportional-column-width()
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@620285 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'test')
-rw-r--r--test/layoutengine/standard-testcases/table-column_column-width_proportional-column-width.xml31
1 files changed, 31 insertions, 0 deletions
diff --git a/test/layoutengine/standard-testcases/table-column_column-width_proportional-column-width.xml b/test/layoutengine/standard-testcases/table-column_column-width_proportional-column-width.xml
index d35d7c45f..e5f2f4f93 100644
--- a/test/layoutengine/standard-testcases/table-column_column-width_proportional-column-width.xml
+++ b/test/layoutengine/standard-testcases/table-column_column-width_proportional-column-width.xml
@@ -67,6 +67,24 @@
</fo:table-row>
</fo:table-body>
</fo:table>
+ <fo:table table-layout="fixed">
+ <fo:table-column column-width="proportional-column-width(25%)"/>
+ <fo:table-column column-width="proportional-column-width(25%)"/>
+ <fo:table-column column-width="proportional-column-width(50%)"/>
+ <fo:table-body>
+ <fo:table-row>
+ <fo:table-cell>
+ <fo:block>cell1%</fo:block>
+ </fo:table-cell>
+ <fo:table-cell background-color="yellow">
+ <fo:block>cell2%</fo:block>
+ </fo:table-cell>
+ <fo:table-cell background-color="orange">
+ <fo:block>cell3%</fo:block>
+ </fo:table-cell>
+ </fo:table-row>
+ </fo:table-body>
+ </fo:table>
</fo:flow>
</fo:page-sequence>
</fo:root>
@@ -95,5 +113,18 @@
<!-- cell 6 -->
<eval expected="cell6" xpath="//flow/block[2]/block[3]/block[1]/lineArea"/>
<eval expected="180000" xpath="//flow/block[2]/block[3]/@ipd"/>
+
+ <!-- Percentages should yield the same result as numbers -->
+ <!-- cell 1% -->
+ <eval expected="cell1%" xpath="//flow/block[3]/block[1]/block[1]/lineArea"/>
+ <eval expected="90000" xpath="//flow/block[3]/block[1]/@ipd"/>
+
+ <!-- cell 2% -->
+ <eval expected="cell2%" xpath="//flow/block[3]/block[2]/block[1]/lineArea"/>
+ <eval expected="90000" xpath="//flow/block[3]/block[2]/@ipd"/>
+
+ <!-- cell 3% -->
+ <eval expected="cell3%" xpath="//flow/block[3]/block[3]/block[1]/lineArea"/>
+ <eval expected="180000" xpath="//flow/block[3]/block[3]/@ipd"/>
</checks>
</testcase>