List Info

Thread: RE: Selective pagebreaks




RE: Selective pagebreaks
user name
2007-07-23 17:41:56

El Martes, 24 de Julio de 2007 00:03, Nelson, Dean
escribió:

> Then, what you want is that all TEST must start on a
new page, right?
>
> ---- Yes
>
> Do you have sections others than TEST that must not
start on their own 
> new page?
>
> ---- Yes -   this is why I chose the PI method

Then, in the TEST sections you could place

<section condition="newpage">

or any other attribute="value" pair, remove
the PIs, and use a variation of 
the previouly send template.

+++++++ It appears that this is the only way to go. The PI
will create its own empty block, which is the contributor to
the extra page. Since I don't use XSL every day, how would I
add the "break-after='page'" to the templates so
that this FO attribute gets included in the block containing
the section?




> ----- Do I need to place this PI before the
<section> or inside it?

I tested it before the section, i.e.:

</section>

<?hard-pagebreak?>

<section>



-- 
Manuel Canales Esparcia
Usuario de LFS nº2886:       http://www.linuxfroms
cratch.org
LFS en castellano: http://www.escomp
oslinux.org/lfs-es http://www.lfs-es.info
TLDP-ES:                           http://es.tldp.org

------------------------------------------------------------
---------
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


Re: Selective pagebreaks
user name
2007-07-24 13:39:34
El Martes, 24 de Julio de 2007 00:41, Nelson, Dean
escribió:

> +++++++ It appears that this is the only way to go. The
PI will create its
> own empty block, which is the contributor to the extra
page. Since I don't
> use XSL every day, how would I add the
"break-after='page'" to the
> templates so that this FO attribute gets included in
the block containing
> the section?

On each section you want be placed on a new page, use

<section condition="newpage">

Then, to your customization layout add:

<xsl:attribute-set
name="section.properties">
  <xsl:attribute name="break-before">
    <xsl:choose>
       <xsl:when 
           
test="preceding-sibling::section[position()=1]/condition='newpage'
            or
preceding-sibling::section[position()=1]/*/condition='newpage'
            or self::section/condition='newpage'">page</xsl:when>
      <xsl:otherwise>auto</xsl:otherwise>
    </xsl:choose>
  </xsl:attribute>
</xsl:attribute-set>

I have not tested it, but theoreticaly it should work.


-- 
Manuel Canales Esparcia
Usuario de LFS nº2886:       http://www.linuxfroms
cratch.org
LFS en castellano: http://www.escomp
oslinux.org/lfs-es http://www.lfs-es.info
TLDP-ES:                           http://es.tldp.org

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


Re: Selective pagebreaks
user name
2007-07-24 13:46:47
El Martes, 24 de Julio de 2007 20:39, M.Canales.es
escribió:

I'm not very sure about the second test. Maybe this one
could be better:

<xsl:attribute-set
name="section.properties">
  <xsl:attribute name="break-before">
    <xsl:choose>
       <xsl:when 
           
test="preceding-sibling::section[position()=1]/condition='newpage'
            or 
preceding-sibling::section[position()=1]/*/section[position(
)=last()]/condition='newpage'
            or self::section/condition='newpage'">page</xsl:when>
      <xsl:otherwise>auto</xsl:otherwise>
    </xsl:choose>
  </xsl:attribute>
</xsl:attribute-set> 

-- 
Manuel Canales Esparcia
Usuario de LFS nº2886:       http://www.linuxfroms
cratch.org
LFS en castellano: http://www.escomp
oslinux.org/lfs-es http://www.lfs-es.info
TLDP-ES:                           http://es.tldp.org

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


[1-3]

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