Hi. I want the cover page of my book PDF to have a full-bleed color
background so I added a fo:block-container that's the same size as the
page and gave it the background-color attribute. This works well and
the cover page looks great, but it also introduces a blank page
between the recto title page and the verso title page.
It seems that there's something about the recto title page that is
spilling over into a new page but doesn't appear there at all.
Has anyone else tried to do something like this? I found that I had to
set negative margins of the block-container above and to the left of
the page in order to center the colored background over the first
page.
I feel like I'm grasping at straws and really should understand what's
going on much more clearly.
Here's my customization for the book title page:
<xsl:template name="book.titlepage.recto">
<xsl:element name="fo:block-container">
<xsl:attribute name="width">8.5in</xsl:attribute>
<xsl:attribute name="height">11in</xsl:attribute>
<xsl:attribute name="margin-left">-1.25in</xsl:attribute>
<xsl:attribute name="margin-top">-0.75in</xsl:attribute>
<xsl:attribute name="background-color">#ff4c00</xsl:attribute>
<xsl:element name="fo:block">
<xsl:attribute name="margin-top">6in</xsl:attribute>
<xsl:attribute name="margin-left">2in</xsl:attribute>
<xsl:element name ="fo:external-graphic">
<xsl:attribute name="content-width">2in</xsl:attribute>
<xsl:attribute name="src">
<xsl:text>url(mylogo.svg)</xsl:text>
</xsl:attribute>
</xsl:element>
</xsl:element>
<xsl:element name="fo:block-container">
<xsl:attribute name="margin-top">.2in</xsl:attribute>
<xsl:attribute name="margin-left">.35in</xsl:attribute>
<xsl:element name="fo:block">
<xsl:attribute name="color">#ffffff</xsl:attribute>
<xsl:attribute name="text-align">left</xsl:attribute>
<xsl:attribute name="font-size">22pt</xsl:attribute>
<xsl:attribute name="font-family">sans-serif</xsl:attribute>
<xsl:attribute name="font-weight">400</xsl:attribute>
<xsl:value-of select="//d:book/d:info/d:title" />
</xsl:element>
</xsl:element>
</xsl:element>
</xsl:template>
Thanks!
Peter
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]