[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: xsl fo lists.
David Pawson wrote: ><fo:block > > <fo:list-block > > <xsl:for-each select="path wanted"> > <fo:list-item> > <fo:list-item-label> > <fo:block>•</fo:block> > </fo:list-item-label> > <fo:list-item-body> > <fo:block><xsl:value-of select="."/></fo:block> > </fo:list-item-body> > </fo:list-item> > </xsl:for-each> ></fo:list-block> ><fo:block> > >Does that make sense please? Yes, it does - in FOP and in our FO2PDF; but not in the XSL WD. Both processors expect you to express lists this way; you can control bullet position by provisional-distance-between-starts and provisional-label-separation attributes in <fo:list-block>. However, if our processors were conformant, your list would be wrong. The problem is that: 1) start-indent and end-indent for both fo:list-item-label and fo:list-item-body are calculated relative to the surrounding reference-area (i.e. page in most cases); 2) start-indent and end-indent are inheritable. Therefore, fo:list-item-label in your list should overlap with fo:list-item-body, and at this point, the formatter is obliged to issue an error message. Instead, you should write: <fo:list-item> <fo:list-item-label end-indent="label-end()"> <fo:block>•</fo:block> </fo:list-item-label> <fo:list-item-body end-indent="body-start()"> <fo:block><xsl:value-of select="."/></fo:block> </fo:list-item-body> </fo:list-item> (This is a thing I dislike most in the whole WD. I argued against it for a long time, but in vain. This way of building lists, already present in WD 1999-04-21, has been reconfirmed and backed up with examples in the recent draft.) Conclusion. You face a dilemma: - if you want to render something with the present-day tools - you are on the right way; - if you want to compose a conformant FO - you are wrong. One more comment: <fo:list-block> is a block-level object itself. You need not wrap it into a <fo:block>: every block-level property can be specified directly on the <fo:list-block>, and every place where <fo:block> can go will accept <fo:list-block> as well. Regards, Nikolai RenderX XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|