This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: XSL-FO discarding space before


Sandy McArthur wrote:
I'm customizing the DocBook to xsl-fo stylesheets to look more like existing documentation that has existed for many years. I'm having trouble with too much white space being before a fo:block. It would simplify my customizations a lot if there is someway to nullify a space-before attribute in a child fo:block. I'm looking for something that is effectively this:

<fo:block space-inside="discard">
<fo:block space-before="1em">
FOO.
</fo:block>
</fo:block>

I'm aware of space-before.conditionality="discard" but don't fully understand it. Any help would be appreciated.
The relevant part of the spec is
 http://www.w3.org/TR/xsl/slice4.html#spacecond
It is not exactly easy to read, not to mention to understand.

The space-before.conditionality property has already
a value of "discard".
It then comes down to precedences and stacking constraints.
Just after a short glance, I'd say that if you have
 <fo:block space-before="1pt">
   <fo:block space-before="3pt">
The 3pt space-before is discarded and the space-before the
actual content is 1pt. This may be wrong, read and interpret
the spec yourself.
The other point is whether does FOP implement it. A short
peek into the code revealed no attempts at implementing
anything looking like the stuff mentioned in the spec, so
if you are using FOP, you probably have to solve the problem
at the XSLT level.
Perhaps one of the code writers can comment on the state
of the current implementation and how this will be handled
in the new design?

J.Pietschmann


XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]