W3C home > Mailing lists > Public > www-xsl-fo@w3.org > June 2001

Re: page break

From: Arved Sandstrom <asandstrom@accesscable.net>
Date: Mon, 25 Jun 2001 23:42:58 -0300
Message-ID: <001d01c0fde9$b614d600$721a8a18@accesscable.net>
To: <www-xsl-fo@w3.org>
Karen Lease and I continue to plug away at FOP re-design; she is
concentrating on line construction and I am concentrating on page layout, so
this entire discussion is something I am following with great interest. Some
comments below.

----- Original Message -----
From: "G. Ken Holman" <gkholman@cranesoftwrights.com>
To: <www-xsl-fo@w3.org>
Sent: Monday, June 25, 2001 8:32 PM
Subject: Re: page break


> At 01/06/25 10:30 +0100, David Carlisle wrote:
>
> > > When would an fo:float float past the end of the flow?  Does it not
float
> > > to the top of the page in which the float is defined, a
> >
> >surely it's allowed on subsequent pages as well? (It would be of limited
> >use otherwise) isn't that what  the part you quoted implies?
> >
> >  (b) is descendant
> >    from the same page containing the anchor-area, or from a page
> >    following that page.
> >    ^^^^^^^^^^^^^^^^^^
>
> I'm not disputing what it says, David, I just don't understand when it
> applies.  That was why I quoted the above in my own post.
>
> And I don't dispute there are conditions where a page of floats are
> generated by the references to a float.
>
> But where in the rules does it specify when a float gets positioned on the
> page following that page?  Is that determined by the implementation and
> just blanketly allowed by the quote above?  I'm trying to document to the
> stylesheet writer what they can do to control (influence?) the positioning
> of floats.

Let's take a steady flow (to borrow a fluid dynamics term), by which I mean
normal blocks with no keeps or breaks. Halfway through page N we encounter a
float, and the stuff it encloses (for sake of argument, a single diagram)
will require 0.6 of the main-reference-area in the block progression
direction. In this situation I am not permitted to put the float on page N,
because the anchor will then end up about 10% of the way into page N+1, as
the flow will have been compactly displaced. So I would anticipate all text
(assuming no other floats) on page N, with the actual before-float reference
area on page N+1 accommodating the figure.

I think that I would put in some cutoffs also, LaTeX-style: for example if
the very first line of page N contained the anchor for a figure that will
occupy all _but_ one line of the page, I doubt very much that I would want
to see a before-float occupying 98% of the page with a single line of text
at the bottom. In this situation I would expect to move the float onto page
N+1 by itself, with the anchor remaining at the top of page N.

These would all be implementation decisions. I'm open to arguments, and to
suggestions for cutoff figures (as I stated I am inclined to go with LaTeX
guidelines unless they conflict with XSL).

> Since I am floating something to the "before-float" area, I anticipate the
> float to appear before the content surrounding the definition of the
> float.  I would have thought to use some text such as "see above", and
> lived with the fact if the "above" happened on the page before (which it
> cannot based on what David has highlighted).  Now, I see that the float
> could be rendered "above" or "below" the point where it is defined.

Seems to me that the "hard" options that are available to the stylesheet
author are either to monkey with float block-progression-dimension (resizing
the fo:float content), or to make judicious use of breaks.

> That leads us to the prior discussion of using the identifier of an empty
> block at the end of the flow for an indication of the last page ... if
> floats appear after the flow then the last page isn't at all guaranteed.
I
> cannot even float an identifier on an empty block at the end of the flow
> because of 6.10.1.3 "The before-float-reference-area is generated only if
> the page contains one or more areas with area-class "xsl-before-float"."
> because that technique would produce an empty area of class
> "xsl-before-float", thus triggering any static content assigned to
> xsl-before-float-separator when the last page could very well not have any
> before floats.

It seems to me that you will not come up with one single strategy that
always works. When it comes to floats (and 95% of my experience with floats
has been with LaTeX, including the original method of cutting and pasting
figures with scissors & Scotch tape :-)) I am inclined to believe that one
almost always is talking about at least a second formatting pass, and
probably many more if there are lots of floats. The whole process is akin to
squeezing out the air bubbles from beneath a laminating film.

If the situation involves trying to get the total page count, then once all
the floats are where they are going to be, definite, then you end up either
sticking that empty identified block at the end of the flow _or_ as the last
content in the last fo:float, whichever one is actually on the final page.
But I don't believe that there is a definite sure-fire method for this one.

Regards,
Arved
Received on Monday, 25 June 2001 22:44:10 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 3 October 2007 16:06:08 GMT