- From: ubi_nunes <ubi.nunes@topazsolutions.co.nz>
- Date: Wed, 15 Jul 2009 18:59:13 -0700 (PDT)
- To: www-xsl-fo@w3.org
Tony Graham-3 wrote: > > On Mon, Jul 13 2009 05:01:27 +0100, ubi.nunes@topazsolutions.co.nz wrote: >> I have to draw cross-line box that will start from the last row of a >> table >> and will cover all the white space until the end of the page. >> >> I'm using fo:instream-foreign-object and svg to create the cross-line >> box. >> >> My problem is that I don't know the size to the box till the xml elements >> populates the table and it will be different from xml to xml file that I >> process. >> >> Can anyone help with a code sample? > > You would want to: > > - Keep the table and the following fo:block together within the page > > - Allow non-uniform scaling on the fo:instream-foreign-object > > - Set the content-height to 'scale-to-fit' (probably also for > content-width). > > Regards, > > > Tony Graham Tony.Graham@MenteithConsulting.com > Director W3C XSL FO SG Invited Expert > Menteith Consulting Ltd XML Guild member > XML, XSL and XSLT consulting, programming and training > Registered Office: 13 Kelly's Bay Beach, Skerries, Co. Dublin, Ireland > Registered in Ireland - No. 428599 http://www.menteithconsulting.com > -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- > xmlroff XSL Formatter http://xmlroff.org > xslide Emacs mode http://www.menteith.com/wiki/xslide > Unicode: A Primer urn:isbn:0-7645-4625-2 > > > Hi Tony, Thanks for the suggestion, but unfortunately it didn't work. I have paste the code I'm trying to get to work. If you can review it and maybe give another suggestion would be great. <fo:flow flow-name="xsl-region-body" font-family="Times" font-size="12pt"> <fo:block keep-together="always" wrap-option="no-wrap" keep-together.within-page="always"> <fo:table table-layout="fixed" width="100%" height="10%" border-collapse="collapse"> <fo:table-column column-width="100.000%" column-number="1"/> <fo:table-column column-width="100.000%" column-number="2"/> <fo:table-column column-width="100.000%" column-number="3"/> <fo:table-column column-width="100.000%" column-number="4"/> <fo:table-body> <xfd:table-row-repeat xpath="/certificates/certificate/product/processing"> <fo:table-cell border="1pt solid black" padding="2pt"> <fo:block> <xfd:field xpath="processing_type/@code"/> </fo:block> </fo:table-cell><fo:table-cell border="1pt solid black" padding="2pt"> <fo:block><xfd:field xpath="processing_type"/> </fo:block> </fo:table-cell><fo:table-cell border="1pt solid black" padding="2pt"> <fo:block><xfd:field xpath="premises/@id"/> </fo:block> </fo:table-cell><fo:table-cell border="1pt solid black" padding="2pt"> <fo:block> <fo:inline wrap-option="wrap"> <xfd:field xpath="premises/name"/> </fo:inline> </fo:block> </fo:table-cell> </xfd:table-row-repeat> </fo:table-body> </fo:table> <fo:block> <fo:instream-foreign-object content-width="scale-to-fit" content-height="scale-to-fit" scaling="non-uniform"> <svg:svg xmlns:svg="http://www.w3.org/2000/svg" width="6.8in" height="10.1in"> <svg:g transform="scale(1, 1)"> <svg:line x1="0" y1="0" x2="6.8in" y2="10.1in" style="stroke:blue;"/> <svg:line x1="0" y1="10.1in" x2="6.8in" y2="0" style="stroke:blue;"/> </svg:g> </svg:svg> </fo:instream-foreign-object> </fo:block> </fo:block> </fo:flow> Thanks Ubi -- View this message in context: http://www.nabble.com/XSL-FO-to-generate-a-PDF-document-tp24455920p24508864.html Sent from the w3.org - www-xsl-fo mailing list archive at Nabble.com.
Received on Thursday, 16 July 2009 01:59:52 UTC