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 Apache Wiki <wi...@apache.org> on 2005/09/15 10:09:26 UTC

[Xmlgraphics-fop Wiki] Update of "BreakPossibilityBuilding" by JeremiasMaerki

Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Xmlgraphics-fop Wiki" for change notification.

The following page has been changed by JeremiasMaerki:
http://wiki.apache.org/xmlgraphics-fop/BreakPossibilityBuilding

The comment on the change is:
Notes on building break possibilities with the Knuth approach

New page:
This page looks at issues around the generation of Knuth element for break possibilities.

= Borders and Padding =

Borders and paddings are generally replicated on each page when block-level FO spans more than a page. Nesting FOs can cause multiple such marks to appear at the beginning and at the end of a page. For each break possibility inside an FO and for breaks between FOs that are nested under a parent breaking such marks these border and padding widths may have to be taken into account when building the element list for the break possibility, depending on their order. The first non-conditional length (counted from the edge of the reference area) will cause subsequent conditional lengths to appear in every case.

== The general pattern for only border and padding ==

The general pattern for a break possibility with only borders and padding inside an FO is:

{{{
penalty w="<pb-after>" p="0"
aux glue w="-<pb-before>" //get's discarded if a break happens on the penalty above
box w="0" //represents the first valid element after a break
penalty w="0" p="INF" //make the following glue unbreakable
aux glue w="<pb-before>"
}}}

Legend:
 * pb-after = the sum of border and padding length after all trailing conditional lengths have been omitted
 * pb-before = the sum of border and padding length after all leading conditional lengths have been omitted

In case there are no borders and padding to replicate in a break condition, the pattern can be simplified to:

{{{
penalty w="0" p="0"
}}}

As can be seen here, all the participating conditional lengths have to be summed up because the penalty has to take the sum of the lengths as its width. The area tree generating stage will have to make sure it can itself determine whether the mark for the border and/or padding has to be generated or not.

= Spaces =

Spaces between FOs will further complicate the break possibility building in that they may contribute additional elements to the list of elements that are needed to find the right element list for a break possibility. 4.3.1 Space-resolution Rules explains the interaction between all the three elements: spaces, border and padding.

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