Stylus Studio XML Editor

Table of contents

Appendices

7.19 Keeps and Breaks Properties

Keeps and Breaks Properties

Page breaks only apply to descendants of the fo:flow formatting object, and not within absolutely positioned areas, or out-of-line areas. In descendants of fo:flow formatting objects, column breaks apply, and a column break in the last (or only) column implies a page break; column breaks in static-content apply except for those in the last (or only) column, which are ignored.

The semantics of keeps and breaks are further described in [keepbreak] .

break-after[top]

"break-after"

XSL Definition:

0prop-summary lefttoplefttoplefttoplefttoplefttoplefttop
11lefttopValue: 11lefttopauto | column | page | even-page | odd-page | inherit
11lefttopInitial: 11lefttopauto
11lefttopApplies to: 11lefttopblock-level formatting objects, fo:list-item, and fo:table-row.
11lefttopInherited: 11lefttopno
11lefttopPercentages: 11lefttopN/A
11lefttopMedia: 11lefttopvisual

Values for these properties have the following meanings:

auto

No break shall be forced.

NOTE: 

Page breaks may occur as determined by the formatter's processing as affected by the "widow", "orphan", "keep-with-next", "keep-with-previous", and "keep-together" properties.

column

Imposes a break-after condition with a context consisting of column-areas.

page

Imposes a break-after condition with a context consisting of page-areas.

even-page

Imposes a break-after condition with a context consisting of even page-areas (a blank page may be generated if necessary).

odd-page

Imposes a break-after condition with a context consisting of odd page-areas (a blank page may be generated if necessary).

Specifies that the first normal area generated by formatting the next formatting object, if any, shall be the first one placed in a particular context (e.g. page-area, column-area)

This property has no effect when it appears on an fo:table-row formatting object in which there is any row spanning occurring that includes both the current fo:table-row and the subsequent one.

break-before[top]

"break-before"

XSL Definition:

0prop-summary lefttoplefttoplefttoplefttoplefttoplefttop
11lefttopValue: 11lefttopauto | column | page | even-page | odd-page | inherit
11lefttopInitial: 11lefttopauto
11lefttopApplies to: 11lefttopblock-level formatting objects, fo:list-item, and fo:table-row.
11lefttopInherited: 11lefttopno
11lefttopPercentages: 11lefttopN/A
11lefttopMedia: 11lefttopvisual

Values have the following meanings:

auto

No break shall be forced.

NOTE: 

Page breaks may occur as determined by the formatter's processing as affected by the "widow", "orphan", "keep-with-next", "keep-with-previous", and "keep-together" properties.

column

Imposes a break-before condition with a context consisting of column-areas.

page

Imposes a break-before condition with a context consisting of page-areas.

even-page

Imposes a break-before condition with a context consisting of even page-areas (a blank page may be generated if necessary).

odd-page

Imposes a break-before condition with a context consisting of odd page-areas (a blank page may be generated if necessary).

Specifies that the first area generated by formatting this formatting object shall be the first one placed in a particular context (e.g., page-area, column-area).

This property has no effect when it appears on an fo:table-row formatting object in which there is any row spanning occurring that includes both the current fo:table-row and the previous one.

keep-together[top]

"keep-together"

XSL Definition:

0prop-summary lefttoplefttoplefttoplefttoplefttoplefttop
11lefttopValue: 11lefttop<keep> | inherit
11lefttopInitial: 11lefttop.within-line=auto, .within-column=auto, .within-page=auto
11lefttopApplies to: 11lefttopblock-level formatting objects, inline formatting objects, fo:table-caption, fo:table-row, fo:list-item, fo:list-item-label, and fo:list-item-body
11lefttopInherited: 11lefttopyes
11lefttopPercentages: 11lefttopN/A
11lefttopMedia: 11lefttopvisual

This property imposes keep-together conditions on formatting objects.

The <keep> datatype is composed of three components: within-line, within-column, and within-page. Different components apply to different classes of formatting objects and provide keep conditions relative to different contexts. In the case of the within-line component, the keep context consists of line-areas; for the within-column component, the keep context consists of column-areas; for the within-page component, the keep context consists of page-areas. In the descriptions below, the term "appropriate context" should be interpreted in terms of the previous sentence.

Values of the components have the following meanings:

auto

There are no keep-together conditions imposed by this property.

always

Imposes a keep-together condition with strength "always" in the appropriate context.

<integer>

Imposes a keep-together condition with strength of the given <integer> in the appropriate context.

The semantics of keeps and breaks are further described in [keepbreak] .

keep-with-next[top]

"keep-with-next"

XSL Definition:

0prop-summary lefttoplefttoplefttoplefttoplefttoplefttop
11lefttopValue: 11lefttop<keep> | inherit
11lefttopInitial: 11lefttop.within-line=auto, .within-column=auto, .within-page=auto
11lefttopApplies to: 11lefttopblock-level formatting objects, inline formatting objects, fo:list-item, and fo:table-row
11lefttopInherited: 11lefttopno
11lefttopPercentages: 11lefttopN/A
11lefttopMedia: 11lefttopvisual

This property imposes keep-with-next conditions on formatting objects.

The <keep> datatype is composed of three components: within-line, within-column, and within-page. Different components apply to different classes of formatting objects and provide keep conditions relative to different contexts. In the case of the within-line component, the keep context consists of line-areas; for the within-column component, the keep context consists of column-areas; for the within-page component, the keep context consists of page-areas. In the descriptions below, the term "appropriate context" should be interpreted in terms of the previous sentence.

Values of the components have the following meanings:

auto

There are no keep-with-next conditions imposed by this property.

always

Imposes a keep-with-next condition with strength "always" in the appropriate context.

<integer>

Imposes a keep-with-next condition with strength of the given <integer> in the appropriate context.

The semantics of keeps and breaks are further described in [keepbreak] .

keep-with-previous[top]

"keep-with-previous"

XSL Definition:

0prop-summary lefttoplefttoplefttoplefttoplefttoplefttop
11lefttopValue: 11lefttop<keep> | inherit
11lefttopInitial: 11lefttop.within-line=auto, .within-column=auto, .within-page=auto
11lefttopApplies to: 11lefttopblock-level formatting objects, inline-level formatting objects, fo:list-item, and fo:table-row
11lefttopInherited: 11lefttopno
11lefttopPercentages: 11lefttopN/A
11lefttopMedia: 11lefttopvisual

This property imposes keep-with-previous conditions on formatting objects.

The <keep> datatype is composed of three components: within-line, within-column, and within-page. Different components apply to different classes of formatting objects and provide keep conditions relative to different contexts. In the case of the within-line component, the keep context consists of line-areas; for the within-column component, the keep context consists of column-areas; for the within-page component, the keep context consists of page-areas. In the descriptions below, the term "appropriate context" should be interpreted in terms of the previous sentence.

Values of the components have the following meanings:

auto

There are no keep-with-previous conditions imposed by this property.

always

Imposes a keep-with-previous condition with strength "always" in the appropriate context.

<integer>

Imposes a keep-with-previous condition with strength of the given <integer> in the appropriate context.

The semantics of keeps and breaks are further described in [keepbreak] .

orphans[top]

"orphans"

CSS2 Definition:

0prop-summary lefttoplefttoplefttoplefttoplefttoplefttop
11lefttopValue: 11lefttop<integer> | inherit
11lefttopInitial: 11lefttop2
11lefttopApplies to: 11lefttopblock-level elements
11lefttopInherited: 11lefttopyes
11lefttopPercentages: 11lefttopN/A
11lefttopMedia: 11lefttopvisual

CSS2 Reference: [ "orphans" property ] http://www.w3.org/TR/REC-CSS2/page.html#propdef-orphans

See definition of property widows ( [widows] ).

widows[top]

"widows"

CSS2 Definition:

0prop-summary lefttoplefttoplefttoplefttoplefttoplefttop
11lefttopValue: 11lefttop<integer> | inherit
11lefttopInitial: 11lefttop2
11lefttopApplies to: 11lefttopblock-level elements
11lefttopInherited: 11lefttopyes
11lefttopPercentages: 11lefttopN/A
11lefttopMedia: 11lefttopvisual

CSS2 Reference: [ "widows" property ] http://www.w3.org/TR/REC-CSS2/page.html#propdef-widows

The "orphans" property specifies the minimum number of lines of a paragraph that must be left at the bottom of a page. The "widows" property specifies the minimum number of lines of a paragraph that must be left at the top of a page.

XSL modifications to the CSS definition:

In XSL the "orphans" property specifies the minimum number of line-areas in the first area generated by the formatting object. The "widows" property specifies the minimum number of line-areas in the last area generated by the formatting object.