Easy Tutorial
❮ Xslfo Pages Xslfo Areas ❯

XSL-FO region-start Object


Definition and Usage

The <fo:region-start> object defines the left-hand region (sidebar) of the page.

XSL-FO uses the following elements to define page regions:

Note: region-before, region-after, region-start, and region-end are all part of region-body. To prevent text within region-body from overlapping text in other regions, the margins of region-body must be at least as large as the dimensions of the four sub-regions.

Note: According to the XSL-FO 1.0 recommendation, padding and border-width properties must be 0.


Syntax

Attributes

Attribute [A-B] Attribute [C-Z]
background-attachment clip
background-color display-align
background-image extent
background-repeat overflow
background-position-horizontal padding-after
background-position-vertical padding-before
border-after-color padding-bottom
border-after-style padding-end
border-after-width padding-left
border-before-color padding-right
border-before-style padding-start
border-before-width padding-top
border-bottom-color region-name
border-bottom-style reference-orientation
border-bottom-width writing-mode
border-end-color
border-end-style
border-end-width
border-left-color
border-left-style
border-left-width
border-right-color
border-right-style
border-right-width
border-start-color
border-start-style
border-start-width
border-top-color
border-top-style
border-top-width

Example 1

XSL-FO uses page templates called "Page Masters" to define page layouts. Each template must have a unique name:

In the above example, three <fo:simple-page-master> elements define three different templates. Each template (page-master) has a different name.

The first template is named "intro". It can be used as a template for introduction pages.

The second and third templates are named "left" and "right". They can be used as templates for even and odd page numbers.

Example 2

This is an excerpt from an XSL-FO document:

The above code defines a "Simple Page Master Template" named "A4".

The page width is 297 millimeters, and the height is 210 millimeters.

The page margins (top, bottom, left, right) are all 1 centimeter.

The body margin is 3 centimeters (all four sides).

The body's before, after, start, and end regions are all 2 centimeters.

The width of the body in the above example can be calculated by subtracting the left and right margins and the region-body margins from the page width:

297mm - (2 x 1cm) - (2 x 3cm) = 297mm - 20mm - 60mm = 217mm Please note that the region (region-start and region-end) has not been included in the calculation. As previously explained, these regions are integral parts of the subject.

❮ Xslfo Pages Xslfo Areas ❯