aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorManuel Mall <manuel@apache.org>2005-10-10 10:22:05 +0000
committerManuel Mall <manuel@apache.org>2005-10-10 10:22:05 +0000
commit179d10f032a58cd67f188ec63698273a18173176 (patch)
treef3d4ad1fa9c1d7a4b2e143025b07386383485f07 /test
parent19ac0323da85dc9b1c8e4be8e8cf2f7a89d45563 (diff)
downloadxmlgraphics-fop-179d10f032a58cd67f188ec63698273a18173176.tar.gz
xmlgraphics-fop-179d10f032a58cd67f188ec63698273a18173176.zip
Added support for leader with pattern "use-content" and recovered a previously lost 1mpt due to rounding
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@312604 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'test')
-rw-r--r--test/layoutengine/disabled-testcases.txt1
-rw-r--r--test/layoutengine/testcases/block_line-height.xml20
-rw-r--r--test/layoutengine/testcases/leader_leader-pattern_use-content.xml83
3 files changed, 93 insertions, 11 deletions
diff --git a/test/layoutengine/disabled-testcases.txt b/test/layoutengine/disabled-testcases.txt
index dfb38521e..c0df6b35a 100644
--- a/test/layoutengine/disabled-testcases.txt
+++ b/test/layoutengine/disabled-testcases.txt
@@ -16,7 +16,6 @@ inline_letter-spacing.xml
inline_word-spacing.xml
inline_word-spacing_text-align_justify.xml
leader-alignment.xml
-leader_leader-pattern_use-content.xml
list-block_keep-with-previous.xml
list-item_block_keep-with-previous.xml
list-item_space-before_space-after_2.xml
diff --git a/test/layoutengine/testcases/block_line-height.xml b/test/layoutengine/testcases/block_line-height.xml
index 03bec53cc..65a27ed61 100644
--- a/test/layoutengine/testcases/block_line-height.xml
+++ b/test/layoutengine/testcases/block_line-height.xml
@@ -60,9 +60,9 @@
<eval expected="1650" xpath="//flow/block[1]/lineArea/@space-before"/>
<eval expected="1650" xpath="//flow/block[1]/lineArea/@space-after"/>
<eval expected="13319" xpath="//flow/block[1]/block[1]/lineArea/@bpd"/>
- <eval expected="17279" xpath="//flow/block[1]/block[1]/lineArea/@bpda"/>
+ <eval expected="17280" xpath="//flow/block[1]/block[1]/lineArea/@bpda"/>
<eval expected="1980" xpath="//flow/block[1]/block[1]/lineArea/@space-before"/>
- <eval expected="1980" xpath="//flow/block[1]/block[1]/lineArea/@space-after"/>
+ <eval expected="1981" xpath="//flow/block[1]/block[1]/lineArea/@space-after"/>
<eval expected="9250" xpath="//flow/block[1]/block[2]/lineArea/@bpd"/>
<eval expected="12000" xpath="//flow/block[1]/block[2]/lineArea/@bpda"/>
<eval expected="1375" xpath="//flow/block[1]/block[2]/lineArea/@space-before"/>
@@ -73,9 +73,9 @@
<eval expected="3450" xpath="//flow/block[2]/lineArea/@space-before"/>
<eval expected="3450" xpath="//flow/block[2]/lineArea/@space-after"/>
<eval expected="13319" xpath="//flow/block[2]/block[1]/lineArea/@bpd"/>
- <eval expected="17999" xpath="//flow/block[2]/block[1]/lineArea/@bpda"/>
+ <eval expected="18000" xpath="//flow/block[2]/block[1]/lineArea/@bpda"/>
<eval expected="2340" xpath="//flow/block[2]/block[1]/lineArea/@space-before"/>
- <eval expected="2340" xpath="//flow/block[2]/block[1]/lineArea/@space-after"/>
+ <eval expected="2341" xpath="//flow/block[2]/block[1]/lineArea/@space-after"/>
<eval expected="9250" xpath="//flow/block[2]/block[2]/lineArea/@bpd"/>
<eval expected="18000" xpath="//flow/block[2]/block[2]/lineArea/@bpda"/>
<eval expected="4375" xpath="//flow/block[2]/block[2]/lineArea/@space-before"/>
@@ -86,9 +86,9 @@
<eval expected="4450" xpath="//flow/block[3]/lineArea/@space-before"/>
<eval expected="4450" xpath="//flow/block[3]/lineArea/@space-after"/>
<eval expected="13319" xpath="//flow/block[3]/block[1]/lineArea/@bpd"/>
- <eval expected="19999" xpath="//flow/block[3]/block[1]/lineArea/@bpda"/>
+ <eval expected="20000" xpath="//flow/block[3]/block[1]/lineArea/@bpda"/>
<eval expected="3340" xpath="//flow/block[3]/block[1]/lineArea/@space-before"/>
- <eval expected="3340" xpath="//flow/block[3]/block[1]/lineArea/@space-after"/>
+ <eval expected="3341" xpath="//flow/block[3]/block[1]/lineArea/@space-after"/>
<eval expected="9250" xpath="//flow/block[3]/block[2]/lineArea/@bpd"/>
<eval expected="20000" xpath="//flow/block[3]/block[2]/lineArea/@bpda"/>
<eval expected="5375" xpath="//flow/block[3]/block[2]/lineArea/@space-before"/>
@@ -99,9 +99,9 @@
<eval expected="3450" xpath="//flow/block[4]/lineArea/@space-before"/>
<eval expected="3450" xpath="//flow/block[4]/lineArea/@space-after"/>
<eval expected="13319" xpath="//flow/block[4]/block[1]/lineArea/@bpd"/>
- <eval expected="21599" xpath="//flow/block[4]/block[1]/lineArea/@bpda"/>
+ <eval expected="21600" xpath="//flow/block[4]/block[1]/lineArea/@bpda"/>
<eval expected="4140" xpath="//flow/block[4]/block[1]/lineArea/@space-before"/>
- <eval expected="4140" xpath="//flow/block[4]/block[1]/lineArea/@space-after"/>
+ <eval expected="4141" xpath="//flow/block[4]/block[1]/lineArea/@space-after"/>
<eval expected="9250" xpath="//flow/block[4]/block[2]/lineArea/@bpd"/>
<eval expected="15000" xpath="//flow/block[4]/block[2]/lineArea/@bpda"/>
<eval expected="2875" xpath="//flow/block[4]/block[2]/lineArea/@space-before"/>
@@ -112,9 +112,9 @@
<eval expected="950" xpath="//flow/block[5]/lineArea/@space-before"/>
<eval expected="950" xpath="//flow/block[5]/lineArea/@space-after"/>
<eval expected="13319" xpath="//flow/block[5]/block[1]/lineArea/@bpd"/>
- <eval expected="13001" xpath="//flow/block[5]/block[1]/lineArea/@bpda"/>
+ <eval expected="13000" xpath="//flow/block[5]/block[1]/lineArea/@bpda"/>
<eval expected="-159" xpath="//flow/block[5]/block[1]/lineArea/@space-before"/>
- <eval expected="-159" xpath="//flow/block[5]/block[1]/lineArea/@space-after"/>
+ <eval expected="-160" xpath="//flow/block[5]/block[1]/lineArea/@space-after"/>
<eval expected="9250" xpath="//flow/block[5]/block[2]/lineArea/@bpd"/>
<eval expected="13000" xpath="//flow/block[5]/block[2]/lineArea/@bpda"/>
<eval expected="1875" xpath="//flow/block[5]/block[2]/lineArea/@space-before"/>
diff --git a/test/layoutengine/testcases/leader_leader-pattern_use-content.xml b/test/layoutengine/testcases/leader_leader-pattern_use-content.xml
index 0a297ee3a..11287f058 100644
--- a/test/layoutengine/testcases/leader_leader-pattern_use-content.xml
+++ b/test/layoutengine/testcases/leader_leader-pattern_use-content.xml
@@ -38,10 +38,93 @@
<fo:leader leader-length="36pt" leader-pattern="use-content"><fo:inline background-color="yellow">=></fo:inline></fo:leader>
Content is "=>" with background
</fo:block>
+ <fo:block>
+ <fo:leader leader-length="36pt" leader-pattern="use-content" leader-pattern-width="12pt"><fo:inline background-color="orange">~</fo:inline></fo:leader>
+ Content is "~" with leader-pattern-width="12pt"
+ </fo:block>
+ <fo:block>
+ <fo:leader leader-length="36pt" leader-pattern="use-content" leader-pattern-width="12pt"><fo:inline border="solid 1pt red" background-color="yellow">*</fo:inline></fo:leader>
+ Content is "*" with leader-pattern-width="12pt" and border
+ </fo:block>
+ <fo:block>
+ <fo:leader leader-length="36pt" leader-pattern="use-content" leader-pattern-width="12pt"><fo:inline border="solid 1pt red" font-size="6pt" alignment-baseline="middle" background-color="yellow">++</fo:inline></fo:leader>
+ Content is "++" with l-p-w="12pt" and border small font
+ </fo:block>
</fo:flow>
</fo:page-sequence>
</fo:root>
</fo>
<checks>
+ <eval expected="11100" xpath="//flow/block[1]/lineArea/@bpd"/>
+ <eval expected="36000" xpath="//flow/block[1]/lineArea/inlineparent/@ipd"/>
+ <eval expected="0" xpath="//flow/block[1]/lineArea/inlineparent/@offset"/>
+ <eval expected="6000" xpath="//flow/block[1]/lineArea/inlineparent/inlineparent[1]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[1]/lineArea/inlineparent/inlineparent[1]/@offset"/>
+ <eval expected="6000" xpath="//flow/block[1]/lineArea/inlineparent/inlineparent[2]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[1]/lineArea/inlineparent/inlineparent[2]/@offset"/>
+ <eval expected="6000" xpath="//flow/block[1]/lineArea/inlineparent/inlineparent[3]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[1]/lineArea/inlineparent/inlineparent[3]/@offset"/>
+ <eval expected="6000" xpath="//flow/block[1]/lineArea/inlineparent/inlineparent[4]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[1]/lineArea/inlineparent/inlineparent[4]/@offset"/>
+ <eval expected="6000" xpath="//flow/block[1]/lineArea/inlineparent/inlineparent[5]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[1]/lineArea/inlineparent/inlineparent[5]/@offset"/>
+ <eval expected="6000" xpath="//flow/block[1]/lineArea/inlineparent/inlineparent[6]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[1]/lineArea/inlineparent/inlineparent[6]/@offset"/>
+
+ <eval expected="11100" xpath="//flow/block[2]/lineArea/@bpd"/>
+ <eval expected="36000" xpath="//flow/block[2]/lineArea/inlineparent/@ipd"/>
+ <eval expected="0" xpath="//flow/block[2]/lineArea/inlineparent/@offset"/>
+ <eval expected="14016" xpath="//flow/block[2]/lineArea/inlineparent/inlineparent[1]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[2]/lineArea/inlineparent/inlineparent[1]/@offset"/>
+ <eval expected="14016" xpath="//flow/block[2]/lineArea/inlineparent/inlineparent[2]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[2]/lineArea/inlineparent/inlineparent[2]/@offset"/>
+
+ <eval expected="11100" xpath="//flow/block[3]/lineArea/@bpd"/>
+ <eval expected="36000" xpath="//flow/block[3]/lineArea/inlineparent/@ipd"/>
+ <eval expected="0" xpath="//flow/block[3]/lineArea/inlineparent/@offset"/>
+ <eval expected="4992" xpath="//flow/block[3]/lineArea/inlineparent/space/@ipd"/>
+ <eval expected="7008" xpath="//flow/block[3]/lineArea/inlineparent/inlineparent[1]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[3]/lineArea/inlineparent/inlineparent[1]/@offset"/>
+ <eval expected="4992" xpath="//flow/block[3]/lineArea/inlineparent/space/@ipd"/>
+ <eval expected="7008" xpath="//flow/block[3]/lineArea/inlineparent/inlineparent[2]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[3]/lineArea/inlineparent/inlineparent[2]/@offset"/>
+ <eval expected="4992" xpath="//flow/block[3]/lineArea/inlineparent/space/@ipd"/>
+ <eval expected="7008" xpath="//flow/block[3]/lineArea/inlineparent/inlineparent[3]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[3]/lineArea/inlineparent/inlineparent[3]/@offset"/>
+
+ <eval expected="11100" xpath="//flow/block[4]/lineArea/@bpd"/>
+ <eval expected="36000" xpath="//flow/block[4]/lineArea/inlineparent/@ipd"/>
+ <eval expected="0" xpath="//flow/block[4]/lineArea/inlineparent/@offset"/>
+ <eval expected="5332" xpath="//flow/block[4]/lineArea/inlineparent/space/@ipd"/>
+ <eval expected="6668" xpath="//flow/block[4]/lineArea/inlineparent/inlineparent[1]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[4]/lineArea/inlineparent/inlineparent[1]/@offset"/>
+ <eval expected="1000 1000 1000 1000" xpath="//flow/block[4]/lineArea/inlineparent/inlineparent[1]/inlineparent/@bap"/>
+ <eval expected="5332" xpath="//flow/block[4]/lineArea/inlineparent/space/@ipd"/>
+ <eval expected="6668" xpath="//flow/block[4]/lineArea/inlineparent/inlineparent[2]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[4]/lineArea/inlineparent/inlineparent[2]/@offset"/>
+ <eval expected="1000 1000 1000 1000" xpath="//flow/block[4]/lineArea/inlineparent/inlineparent[2]/inlineparent/@bap"/>
+ <eval expected="5332" xpath="//flow/block[4]/lineArea/inlineparent/space/@ipd"/>
+ <eval expected="6668" xpath="//flow/block[4]/lineArea/inlineparent/inlineparent[3]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[4]/lineArea/inlineparent/inlineparent[3]/@offset"/>
+ <eval expected="1000 1000 1000 1000" xpath="//flow/block[4]/lineArea/inlineparent/inlineparent[3]/inlineparent/@bap"/>
+
+ <eval expected="11100" xpath="//flow/block[5]/lineArea/@bpd"/>
+ <eval expected="36000" xpath="//flow/block[5]/lineArea/inlineparent/@ipd"/>
+ <eval expected="0" xpath="//flow/block[5]/lineArea/inlineparent/@offset"/>
+ <eval expected="2992" xpath="//flow/block[5]/lineArea/inlineparent/space/@ipd"/>
+ <eval expected="9008" xpath="//flow/block[5]/lineArea/inlineparent/inlineparent[1]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[5]/lineArea/inlineparent/inlineparent[1]/@offset"/>
+ <eval expected="2739" xpath="//flow/block[5]/lineArea/inlineparent/inlineparent[1]/inlineparent/@offset"/>
+ <eval expected="1000 1000 1000 1000" xpath="//flow/block[5]/lineArea/inlineparent/inlineparent[1]/inlineparent/@bap"/>
+ <eval expected="2992" xpath="//flow/block[5]/lineArea/inlineparent/space/@ipd"/>
+ <eval expected="9008" xpath="//flow/block[5]/lineArea/inlineparent/inlineparent[2]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[5]/lineArea/inlineparent/inlineparent[2]/@offset"/>
+ <eval expected="2739" xpath="//flow/block[5]/lineArea/inlineparent/inlineparent[2]/inlineparent/@offset"/>
+ <eval expected="1000 1000 1000 1000" xpath="//flow/block[5]/lineArea/inlineparent/inlineparent[2]/inlineparent/@bap"/>
+ <eval expected="2992" xpath="//flow/block[5]/lineArea/inlineparent/space/@ipd"/>
+ <eval expected="9008" xpath="//flow/block[5]/lineArea/inlineparent/inlineparent[3]/@ipd"/>
+ <eval expected="0" xpath="//flow/block[5]/lineArea/inlineparent/inlineparent[3]/@offset"/>
+ <eval expected="2739" xpath="//flow/block[5]/lineArea/inlineparent/inlineparent[3]/inlineparent/@offset"/>
+ <eval expected="1000 1000 1000 1000" xpath="//flow/block[5]/lineArea/inlineparent/inlineparent[3]/inlineparent/@bap"/>
</checks>
</testcase>