Subject: Re: [xsl] Balancing Columns From: "G. Ken Holman" <gkholman@xxxxxxxxxxxxxxxxxxxx> Date: Thu, 24 Jan 2002 10:24:21 -0500 |
"G. Ken Holman" wrote: > > At 2002-01-23 11:42 -0600, W. Eliot Kimber wrote: > >Is there a way to get balanced columns in a multi-column page layout? > > Columns in a page are always balanced, in that the simple page geometry > only provides for a column count and a column gap ... thus, the column > widths are always equal.
I think you've misunderstood what I mean by "balanced columns".
I don't mean columns of equal width, but columns in which the composed text is of equal depth across the columns, e.g.:
xxxxxxxxxxx xxxxxxxxxx xxxxxxxxxx xxxxxxxxxxx xxxxxxxxxx
Not:
xxxxxxxxxxx xxxxxxxxxx xxxxxxxxxxx xxxxxxxxxxx xxxxxxxxxxx
<xsl:variable name="items" select="...whatever..."/> <table> <table-row> <table-cell> <xsl:for-each select="$items"> <xsl:if test="position() <= ( last() / 2 )"> <!--format item in left-hand column--> </xsl:if> </xsl:for-each> </table-cell> <table-cell> <xsl:for-each select="$items"> <xsl:if test="position() > ( last() / 2 )"> <!--format item in right-hand column--> </xsl:if> </xsl:for-each> </table-cell> </table-row> </table>
-- Upcoming: 3-days XSLT/XPath and/or 2-days XSLFO - Feb 18-22, 2002
G. Ken Holman mailto:gkholman@xxxxxxxxxxxxxxxxxxxx Crane Softwrights Ltd. http://www.CraneSoftwrights.com/s/ Box 266, Kars, Ontario CANADA K0A-2E0 +1(613)489-0999 (Fax:-0995) ISBN 0-13-065196-6 Definitive XSLT & XPath ISBN 1-894049-08-X Practical Transformation Using XSLT and XPath ISBN 1-894049-07-1 Practical Formatting Using XSLFO XSL/XML/DSSSL/SGML/OmniMark services, books(electronic, printed), articles, training(instructor-live,Internet-live,web/CD,licensed) Next public training: 02-02-11,12,14,15,18,21,03-04,05,06,08,11, - 04-08,09,10,12,05-14,15,06-04,07
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Balancing Columns, W. Eliot Kimber | Thread | Re: [xsl] Balancing Columns, W. Eliot Kimber |
Re: [xsl] Balancing Columns, W. Eliot Kimber | Date | Re: [xsl] Balancing Columns, MURAKAMI Shinyu |
Month |