List Info

Thread: toc.margin.properties, end-indent, no affect




toc.margin.properties, end-indent, no affect
user name
2006-07-24 06:24:28
Hi Steve,
The toc.margin.properties let you set the end-indent for the
container 
fo:block for the whole toc, but it is being overridden by
the end-indents 
set by the toc.line template, which was added later.  I
think you need to 
customize toc.line from fo/autoidx.xsl.  It has:

  <fo:block text-align-last="justify"
            end-indent="{$toc.indent.width}pt"
           
last-line-end-indent="-{$toc.indent.width}pt">
;

The end-indent value adds a right margin for all lines, and
the 
last-line-end-indent adds a negative value to cancel it out
for the last 
line.  That way if a toc line is long and wraps, the first
line does not 
intrude into the space reserved for the page numbers.  You
would need:

  <fo:block text-align-last="justify"
            end-indent="2.5in +
{$toc.indent.width}pt"
           
last-line-end-indent="-{$toc.indent.width}pt">
;


I'll fix that example in my book that suggests that
toc.margin.properties 
would work for end-indent.

Bob Stayton
Sagehill Enterprises
DocBook Consulting
bobssagehill.net


----- Original Message ----- 
From: "Steve Whitlatch" <swhitlatgetnet.net>
To: <docbook-appslists.oasis-open.org>
Sent: Sunday, July 23, 2006 3:29 PM
Subject: [docbook-apps] toc.margin.properties, end-indent,
no affect


> Using the 1.70-1 FO stylesheets, I'm attempting to
indent right-hand TOC
> margins with the following:
>
>  <xsl:attribute-set
name="toc.margin.properties">
>    <xsl:attribute
name="end-indent">2.5in</xsl:attribute>
>  </xsl:attribute-set>
>
> I couldn't get it to produce any affect whatsoever,
regardless of the
> end-indent value.
>
> As a test, and so that I would eliminate any
interference produced from 
> some
> other part of my customization layer, I tried the same
inside a very 
> simple
> customization layer:
>
> ********
> <?xml version="1.0"
encoding="utf-8"?>
> <xsl:stylesheet
>    xmlnssl=&
quot;http://www.w3.or
g/1999/XSL/Transform"
>    xmlns:fo="http://www.w3.org/1
999/XSL/Format"
>    version="1.0">
>  <xsl:import
> 
>
href="/usr/share/xml/docbook/xsl-stylesheets-1.70-1/fo
/docbook.xsl"/>
>  <xsl:param name="use.svg"
select="1"></xsl:param>
>  <xsl:param name="xep.extensions"
select="1"></xsl:param>
>  <xsl:param name="draft.watermark.image"
>   
select="'file:///usr/share/xml/docbook/images/draft.p
ng'"/>
>  <xsl:attribute-set
name="toc.margin.properties">
>    <xsl:attribute
name="end-indent">2.5in</xsl:attribute>
>  </xsl:attribute-set>
> </xsl:stylesheet>
> ********
>
> Nothing, same thing with FOP 0.20.5 or XEP Version 4.6
build 20060623.
>
> My fault? Help? Shall I learn to file a bug report?
>
> Thanks,
>
> Steve Whitlatch
>
>
>
------------------------------------------------------------
---------
> To unsubscribe, e-mail: docbook-apps-unsubscribelists.oasis-open.org
> For additional commands, e-mail: docbook-apps-helplists.oasis-open.org
>
>
> 



------------------------------------------------------------
---------
To unsubscribe, e-mail: docbook-apps-unsubscribelists.oasis-open.org
For additional commands, e-mail: docbook-apps-helplists.oasis-open.org

[1]

about | contact  Other archives ( Real Estate discussion Medical topics )