Page 1 of 1

output maging with external code insertion

Posted: Fri Nov 30, 2007 3:09 pm
by arnaudmrs13
Hello Sorin and thank you for your help yesterday,

When i use external code, the text included in my file as you can see :

Code: Select all


<para>
<programlisting><textobject><textdata
fileref="file:///N:/hyzowa1/20071122/tree/etc/fstab"/></textobject>
</programlisting>
</para>
The result is great because i do not have to copy and paste the file.. well
in my xsl had input this to obtain a good result :

Code: Select all

    
<xsl:template match="para">
<fo:block font-size="10pt" space-before.optimum="12pt" text-align="justify"><xsl:apply-templates/></fo:block>
</xsl:template>

<xsl:template match="textobject">
<fo:block font-size="8pt" space-before.optimum="10pt" text-align="left"><xsl:apply-templates/></fo:block>
</xsl:template>

<xsl:attribute-set name="shade.verbatim.style">
<xsl:attribute name="background-color">#E0E0E0</xsl:attribute>
<xsl:attribute name="font-size">8pt</xsl:attribute>
<xsl:attribute-set>
this is my final result

Image

and as you can see with the number "1" circle, the text is outside the marge
and with the number 2 i would like to make the left marge for my paragraph less important.

Could you give me a few information to make it working please ?

Thanks

Arnaud :D

Posted: Fri Nov 30, 2007 7:02 pm
by sorin_ristache
Hello,

For the first problem you should either edit the tree/etc/fstab file to reduce the line length of the text that goes outside the page margin or hyphenate the long lines by setting the Docbook parameter hyphenate.verbatim.characters to a set of characters appropriate for your documents.

For the second problem you have to customize the Docbook stylesheet and modify the templates for the section titles and section content that you use for Fichier fstab de hyzowa2.


Regards,
Sorin