You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-commits@xmlgraphics.apache.org by je...@apache.org on 2006/04/12 10:58:48 UTC

svn commit: r393420 - in /xmlgraphics/fop/trunk/test/layoutengine: disabled-testcases.xml standard-testcases/page-number-citation_forward-ref.xml

Author: jeremias
Date: Wed Apr 12 01:58:46 2006
New Revision: 393420

URL: http://svn.apache.org/viewcvs?rev=393420&view=rev
Log:
Adding a test case that demonstrates a problem with forward references and page-number-citation. The reference's width is adjusted, but not the whole line. Some code in the area tree tries to adjust word- and letter-spacing but it does not seem to be working properly.

Added:
    xmlgraphics/fop/trunk/test/layoutengine/standard-testcases/page-number-citation_forward-ref.xml   (with props)
Modified:
    xmlgraphics/fop/trunk/test/layoutengine/disabled-testcases.xml

Modified: xmlgraphics/fop/trunk/test/layoutengine/disabled-testcases.xml
URL: http://svn.apache.org/viewcvs/xmlgraphics/fop/trunk/test/layoutengine/disabled-testcases.xml?rev=393420&r1=393419&r2=393420&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/test/layoutengine/disabled-testcases.xml (original)
+++ xmlgraphics/fop/trunk/test/layoutengine/disabled-testcases.xml Wed Apr 12 01:58:46 2006
@@ -226,6 +226,11 @@
     placed correctly.</description>
   </testcase>
   <testcase>
+    <name>page-number-citation: Forward references not adjusted properly</name>
+    <file>page-number-citation_forward-ref.xml</file>
+    <description>Forward references are not properly adjusted when they are resolved.</description>
+  </testcase>
+  <testcase>
     <name>IDs are not working on all FO elements</name>
     <file>page-number-citation_complex_1.xml</file>
     <description>The "id" attributes are not properly handled for all block-level FO elements.</description>

Added: xmlgraphics/fop/trunk/test/layoutengine/standard-testcases/page-number-citation_forward-ref.xml
URL: http://svn.apache.org/viewcvs/xmlgraphics/fop/trunk/test/layoutengine/standard-testcases/page-number-citation_forward-ref.xml?rev=393420&view=auto
==============================================================================
--- xmlgraphics/fop/trunk/test/layoutengine/standard-testcases/page-number-citation_forward-ref.xml (added)
+++ xmlgraphics/fop/trunk/test/layoutengine/standard-testcases/page-number-citation_forward-ref.xml Wed Apr 12 01:58:46 2006
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 2006 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id$ -->
+<testcase>
+  <info>
+    <p>
+      This test checks fo:page-number-citation, especially the width adjustment after a forward reference is resolved.
+    </p>
+  </info>
+  <fo>
+    <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:svg="http://www.w3.org/2000/svg">
+      <fo:layout-master-set>
+        <fo:simple-page-master master-name="master1" page-width="5in" page-height="1in">
+          <fo:region-body/>
+        </fo:simple-page-master>
+      </fo:layout-master-set>
+      <fo:page-sequence master-reference="master1" white-space-collapse="true">
+        <fo:flow flow-name="xsl-region-body">
+          <fo:block id="first">This block has id="first".</fo:block>
+          <fo:block font-style="italic" font-size="smaller" break-after="page">Note: The interesting part is on the second page!</fo:block>
+          <fo:block text-align="justify" text-align-last="justify" id="refbl1">Backward reference "first"<fo:leader leader-pattern="dots" leader-pattern-width="8pt"/><fo:page-number-citation id="first-ref" ref-id="first"/></fo:block>
+          <fo:block text-align="justify" text-align-last="justify" id="refbl2">Forward reference "second"<fo:leader leader-pattern="dots" leader-pattern-width="8pt"/><fo:page-number-citation id="second-ref" ref-id="second"/></fo:block>
+          <fo:block break-before="page" id="second">This block has id="second".</fo:block>
+        </fo:flow>
+      </fo:page-sequence>
+    </fo:root>
+  </fo>
+  <checks>
+    <true xpath="(//block[@prod-id='refbl1']/@ipd - sum(//block[@prod-id='refbl1']/lineArea/child::*/@ipd)) &lt; 3"/>
+    <true xpath="(//block[@prod-id='refbl2']/@ipd - sum(//block[@prod-id='refbl2']/lineArea/child::*/@ipd)) &lt; 3"/>
+  </checks>
+</testcase>

Propchange: xmlgraphics/fop/trunk/test/layoutengine/standard-testcases/page-number-citation_forward-ref.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: xmlgraphics/fop/trunk/test/layoutengine/standard-testcases/page-number-citation_forward-ref.xml
------------------------------------------------------------------------------
    svn:keywords = Id



---------------------------------------------------------------------
To unsubscribe, e-mail: fop-commits-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-commits-help@xmlgraphics.apache.org