|
| 1 | +<?xml version="1.0" encoding="UTF-8"?> |
| 2 | +<!-- |
| 3 | + Licensed to the Apache Software Foundation (ASF) under one or more |
| 4 | + contributor license agreements. See the NOTICE file distributed with |
| 5 | + this work for additional information regarding copyright ownership. |
| 6 | + The ASF licenses this file to You under the Apache License, Version 2.0 |
| 7 | + (the "License"); you may not use this file except in compliance with |
| 8 | + the License. You may obtain a copy of the License at |
| 9 | +
|
| 10 | + http://www.apache.org/licenses/LICENSE-2.0 |
| 11 | +
|
| 12 | + Unless required by applicable law or agreed to in writing, software |
| 13 | + distributed under the License is distributed on an "AS IS" BASIS, |
| 14 | + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 15 | + See the License for the specific language governing permissions and |
| 16 | + limitations under the License. |
| 17 | +--> |
| 18 | +<!-- $Id$ --> |
| 19 | +<testcase> |
| 20 | + <info> |
| 21 | + <p> |
| 22 | + This test checks the page-position only is not used as there is more than 1 page |
| 23 | + </p> |
| 24 | + </info> |
| 25 | + <cfg> |
| 26 | + <legacy-skip-page-position-only>true</legacy-skip-page-position-only> |
| 27 | + </cfg> |
| 28 | + <fo> |
| 29 | + <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:fox="http://xmlgraphics.apache.org/fop/extensions"> |
| 30 | + <fo:layout-master-set> |
| 31 | + <fo:simple-page-master master-name="PageFrontSingle" page-width="8.5in" page-height="11in" margin-bottom="0.32in" margin-right="1in" margin-top="0.2in" margin-left="0.9in"> |
| 32 | + <fo:region-body margin-bottom="1.35in" margin-top="0.5in" column-count="2" column-gap=".5in" region-name="letterPageBody"/> |
| 33 | + </fo:simple-page-master> |
| 34 | + <fo:simple-page-master master-name="PageFront" page-width="8.5in" page-height="11in" margin-bottom="0.32in" margin-right="1in" margin-top="0.2in" margin-left="0.9in"> |
| 35 | + <fo:region-body margin-bottom="0.7in" margin-top="0.5in" column-gap=".5in" column-count="2" region-name="letterPageBody"/> |
| 36 | + </fo:simple-page-master> |
| 37 | + <fo:simple-page-master master-name="PageRest" page-width="8.5in" page-height="11in" margin-bottom="0.32in" margin-right="1in" margin-top="0.7in" margin-left="0.9in"> |
| 38 | + <fo:region-body margin-bottom="0.7in" column-gap=".5in" column-count="2" region-name="letterPageBody"/> |
| 39 | + </fo:simple-page-master> |
| 40 | + <fo:simple-page-master master-name="PageLast" page-width="8.5in" page-height="11in" margin-bottom="0.32in" margin-right="1in" margin-top="0.7in" margin-left="0.9in"> |
| 41 | + <fo:region-body margin-bottom="1.35in" region-name="letterPageBody"/> |
| 42 | + </fo:simple-page-master> |
| 43 | + <fo:page-sequence-master master-name="LetterPages"> |
| 44 | + <fo:repeatable-page-master-alternatives> |
| 45 | + <fo:conditional-page-master-reference page-position="only" master-reference="PageFrontSingle"/> |
| 46 | + <fo:conditional-page-master-reference page-position="first" master-reference="PageFront"/> |
| 47 | + <fo:conditional-page-master-reference page-position="rest" master-reference="PageRest"/> |
| 48 | + <fo:conditional-page-master-reference page-position="last" master-reference="PageLast"/> |
| 49 | + </fo:repeatable-page-master-alternatives> |
| 50 | + </fo:page-sequence-master> |
| 51 | + </fo:layout-master-set> |
| 52 | + <fo:page-sequence format="1" id="th_default_sequence1" initial-page-number="auto" force-page-count="auto" master-reference="LetterPages"> |
| 53 | + <fo:flow flow-name="letterPageBody"> |
| 54 | + <fo:block span="all"> |
| 55 | + <fo:block>test</fo:block> |
| 56 | + <fo:block break-after="column"> |
| 57 | + <fo:leader/> |
| 58 | + </fo:block> |
| 59 | + <fo:block>test</fo:block> |
| 60 | + </fo:block> |
| 61 | + <fo:block>test</fo:block> |
| 62 | + </fo:flow> |
| 63 | + </fo:page-sequence> |
| 64 | + </fo:root> |
| 65 | + </fo> |
| 66 | + <checks> |
| 67 | + <eval expected="3" xpath="count(//word)"/> |
| 68 | + <eval expected="2" xpath="count(//page)"/> |
| 69 | + <eval expected="PageFront" xpath="//pageViewport/@simple-page-master-name"/> |
| 70 | + </checks> |
| 71 | +</testcase> |
0 commit comments