[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: 'space-after' combined with 'break-after="page"'

Subject: Re: 'space-after' combined with 'break-after="page"'
From: "Kevin Brown" <kevin@xxxxxxxxxxx>
Date: Sat, 29 Jun 2013 10:57:19 -0700
Re:  'space-after' combined with 'break-after="page"'
Nancy:

Without looking at depth into the exact case you have, I read Ken's response
and I believe he is correct.
A couple other things I will point out from experience and a deep knowledge
of RenderX. 

I would always try to avoid this:

> <fo:block break-after="page"/>

Certainly this could be a break-before="page" on the following block.

> <fo:block xmlns:rx="http://www.renderx.com/XSL/Extensions" span="all"
> start-indent="0pt">

Even if there is some logic within an XSL that outputs the empty block with
a page-break, this logic could likely be moved to placing the attribute on
the following block. Side effects can lead to a slightly slower performance
inside the engine. Consider the case where content on the page just before
that block ended right at the end. Inside the formatter a new page would be
created and then this block placed down with the rule to break right after
it, causing a new page again. And then the block would be collapsed as it
has no content and the formatting engine has to delete the page it created
and go backwards (essentially ... the formatter does do things a bit
different but the explanation is close). This can be compounded by the
existence of keeps and footnotes. Using break-before is handled differently
as the page is already created and this is tested immediately, if this is
being placed at the top of a new page, the break-before is basically
"skipped".

I also try to (again if possible) avoid this:

> <fo:block/>

This is really no different than the above and can in certain instances
break keeps at higher levels in the engine. Empty blocks that do nothing at
all are necessarily collapsed, they do not end up in the area tree and there
are cases where they can break a keep condition.

I do not even use that structure when filling an empty table-cell, I always
use <fo:block><fo:inline/></fo:block>, while it is the same it is just a
habit from experience in hitting some issues.

When looking at XSL FO, I try to find structures that really do nothing or
could be done differently (like moving the break to the following block) and
attempt to architect them out of the solution. After all, if they do nothing
it would not harm you to remove them.

In 80% of the cases of behavior that is not possibly what you expect, it
will usually comes from such a structure.

Kevin Brown
RenderX

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.