XSL-FO File Structure and Declaration Statements
Part:
1
2
(Continued from previous part...)
"page-sequence-master" Statements
page-sequence-master: An XSL-FO element serving as a declaration statement
to define a page sequence layout.
For example:
<fo:page-sequence-master master-name="my_sequence">
<fo:single-page-master-reference master-reference="name_1"/>
<fo:repeatable-page-master-reference master-reference="name_2"
maximum-repeats="5"/>
<fo:repeatable-page-master-alternatives maximum-repeats="no-limit">
<fo:conditional-page-master-reference master-reference="name_3"
odd-or-even="odd"/>
<fo:conditional-page-master-reference master-reference="name_4"
odd-or-even="even" page-position="rest"/>
<fo:conditional-page-master-reference master-reference="name_5"
odd-or-even="even" page-position="last"/>
</fo:repeatable-page-master-alternatives>
</fo:page-sequence-master>
Some basic rules about page-sequence-master statements:
- Each page layouts will be used in the same order as they appear in the
statement.
- "maximum-repeats" specifies the maximum number of times this layout can be repeated.
- Values for page-position are: first | last | rest | any.
So the above example defines a layout for a sequence of pages that:
- Layout "name_1" should be used for the first page.
- Layout "name_2" should be used for the next 5 pages.
- After that layout "name_3" should be used for all odd pages.
- Layout "name_4" should be used for all even pages, except for the last page.
- If the last page is a even page, layout "name_5" should be used.
"page-sequence" Statements
"page-sequence": An XSL-FO element serving as a declaration statement to
define a set of maps of flows of clock areas to speficic regions defined in layouts.
For example:
<fo:page-sequence master-reference="my_layout"
initial-page-number="11">
<fo:static-content flow-name="static_region_name_1"
font-family="sans-serif" font-size="8pt">
block area generation statements
</fo:static-content>
<fo:static-content flow-name="static_region_name_2">
block area generation statements
</fo:static-content>
<fo:flow flow-name="body_region_name"
font-family="serif" font-size="12pt">
block area generation statements
</fo:flow>
lt;/fo:page-sequence>
Some basic rules about page-sequence statements:
- "static-content": A declaration statement to define a map of a flow of block areas
to a static region in a layout. The same flow of block areas is used to repeatedly fill the
same region from page to page.
- "flow": A declaration statement to define a map of a flow of block areas
to a body region in a layout. The region will be filled by the flow of block areas
continuously.
Whenever the region on one page is full, a new page will be generated.
- "initial-page-number": An attribute used to control the page number on the first page
of the page sequence. If "auto" is specified, the page number will continue from the last
page number of the previous page sequence.
- Font related attributes can be specified in "flow" and "static-content" statements.
If specified, the font attributes will be applied to all block areas in this flow.
Part:
1
2
|