You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Pascal Sancho <pa...@takoma.fr> on 2005/12/01 09:25:06 UTC
RE: Background image
Hi Arni,
I suppose you are running FOP 0.20.5.
1 solution is to put your image in a fo:block-container (as you are in footer, your left attribute should use a negative value to place it over the region-start in left pages, depending on your region-start extend attribute):
<fo:block-container position="absolute" left="-15mm" top="8mm" width="210mm" height="297mm">
<fo:block>
<!-- here go your background image, that can be either a fo:instream-foreign-object or a fo:external-graphic-->
</fo:block>
</fo:block-container>
<!-- your content must be after your background image -->
Hope that help you
Pascal
_____
De : Arni Maack [mailto:arnim@touchwood.net]
Envoyé : mercredi 30 novembre 2005 22:20
I'm trying to do a stylized page numbering on my document and having some trouble.
The goal is to put a black circle on the bottom-leftt side of the page with the page number in white centered in the circle. I tried using a table with a background image for this purpose but it only lets me use a 72dpi image but I need this to be 300dpi or a vector image. When I inserted a 300dpi image it just made the image bigger.
I tried inserting a svg image but fop wouldn't output it (just showed up blank).
I'd really appreciate any help you could provide, including different ways of achieving the same thing.
<fo:static-content flow-name="even-page-footer">
<fo:block>
<fo:table width="100%" table-layout="fixed" space-before.optimum="1pt" space-after.optimum="2pt">
<fo:table-column column-width="0.30in" />
<fo:table-column />
<fo:table-column />
<fo:table-body>
<fo:table-row>
<fo:table-cell padding-bottom="0pt" padding-left="0pt" padding-right="0pt" padding-top="0pt" border-style="solid" border-width="1pt" border-color="white" height="30pt" padding-start="3pt" padding-end="3pt" padding-before="3pt" padding-after="3pt" display-align="center" text-align="start">
<fo:block />
</fo:table-cell>
<fo:table-cell padding-bottom="0pt" padding-left="0pt" padding-right="0pt" padding-top="0pt" border-style="solid" border-width="1pt" border-color="white" height="30pt" number-columns-spanned="2" padding-start="3pt" padding-end="3pt" padding-before="3pt" padding-after="3pt" display-align="center" text-align="start">
<fo:block />
</fo:table-cell>
</fo:table-row>
<fo:table-row>
<fo:table-cell font-size="inherited-property-value('font-size') - 2pt" padding-bottom="0pt" padding-left="0pt" padding-right="0pt" padding-top="0pt" border-style="solid" border-width="1pt" border-color="white" text-align="left" width="0.30in" padding-start="3pt" padding-end="3pt" padding-before="3pt" padding-after="3pt" display-align="center">
<fo:block>
<fo:table width="0.3in" table-layout="fixed" space-before.optimum="1pt" space-after.optimum="2pt">
<fo:table-column column-width="0.3in" />
<fo:table-body>
<fo:table-row>
<fo:table-cell background-image="../graphics/pageNumCircle.jpg" background-repeat="no-repeat" border-bottom-style="none" border-left-style="none" border-right-style="none" border-top-style="none" padding-left="-0.75pt" border-style="solid" border-width="1pt" border-color="white" height="0.25in" text-align="center" width="0.3in" padding-start="3pt" padding-end="3pt" padding-before="3pt" padding-after="3pt" display-align="center">
<fo:block>
<fo:page-number color="#EEEEEE" font-family="MetaPlusMedium-Roman" font-size="10pt" />
</fo:block>
</fo:table-cell>
</fo:table-row>
</fo:table-body>
</fo:table>
</fo:block>
</fo:table-cell>
<fo:table-cell font-size="inherited-property-value('font-size') - 2pt" padding-bottom="0pt" padding-left="0pt" padding-right="0pt" padding-top="0pt" border-style="solid" border-width="1pt" border-color="white" text-align="left" padding-start="3pt" padding-end="3pt" padding-before="3pt" padding-after="3pt" display-align="center">
<fo:block>
<fo:inline font-family="MetaPlusBold-Caps">     2006 Ophthalmic Coding Coach</fo:inline>
</fo:block>
</fo:table-cell>
<fo:table-cell font-size="inherited-property-value('font-size') - 2pt" line-height="6pt" padding-bottom="0pt" padding-left="0pt" padding-right="0pt" padding-top="0pt" border-style="solid" border-width="1pt" border-color="white" text-align="right" padding-start="3pt" padding-end="3pt" padding-before="3pt" padding-after="3pt" display-align="center">
<fo:block>
<fo:inline font-family="MetaPlusBook-Roman" font-size="6pt">© Company Name</fo:inline>
<fo:block>
<fo:leader leader-pattern="space" />
</fo:block>
<fo:inline font-family="MetaPlusBook-Roman" font-size="6pt">All rights reserved.</fo:inline>
</fo:block>
</fo:table-cell>
</fo:table-row>
</fo:table-body>
</fo:table>
</fo:block>
</fo:static-content>