Page 1 of 1

Problem Background Image with block

Posted: Thu Apr 17, 2014 10:17 am
by Le Basque
Hi,
I have page consisting of a logo, a text and edging of an image.
The edging is background and must fill the page.

Code: Select all


    <fo:flow flow-name="xsl-region-body">
<fo:block background-image="line.jpg" text-align="left">
<fo:block space-before="7mm" space-before.conditionality="retain">
<fo:table>
<fo:table-column column-width="200mm" />
<fo:table-column column-width="10mm" />
<fo:table-body>
<fo:table-row>
<fo:table-cell text-align="right">
<fo:block>
<fo:external-graphic src="logo.tif" />
</fo:block>
</fo:table-cell>
<fo:table-cell>
<fo:block />
</fo:table-cell>
</fo:table-row>
</fo:table-body>
</fo:table>
</fo:block>
<fo:block color="#33ccff" font-size="22pt" font-weight="bold" line-height="140%" margin-left="20mm" space-before="12mm" space-before.conditionality="retain" line-height-shift-adjustment="disregard-shifts" font-family="Helvetica, Arial Unicode MS">IT Tools<fo:block color="#003399" font-size="22pt" font-weight="bold" line-height="140%" line-height-shift-adjustment="disregard-shifts" font-family="Helvetica, Arial Unicode MS">User Guide</fo:block>
<fo:block margin-right="12mm" space-before="40mm" space-before.conditionality="retain" text-align="end" >
<fo:external-graphic src="image.jpg"/>
</fo:block>
</fo:block>
line.tif : 4970x7019 pixels
image.jpg : 570 x 598 pixels
My problem : line in the background is not going to bottom of page

thank you

Re: Problem Background Image with block

Posted: Thu Apr 17, 2014 11:05 am
by Le Basque
For simplicity, I want to define a block size of the page, for example A4

thank you

Re: Problem Background Image with block

Posted: Thu Apr 17, 2014 11:20 am
by sorin_ristache
Hi,

The exact position of all images from that fo:block element depends of the whole content of the parent fo:flow and fo:page-sequence. What does the fo:flow contain? Does it start at the beginning of the page? Can you post a screenshot of the page as it look now in the PDF output, to understand better how you need to adjust the image location?


Regards,
Sorin

Re: Problem Background Image with block

Posted: Thu Apr 17, 2014 11:26 am
by sorin_ristache
Le Basque wrote:

Code: Select all


    <fo:flow flow-name="xsl-region-body">
<fo:block background-image="line.jpg" text-align="left">
. . .
line.tif : 4970x7019 pixels
My problem : line in the background is not going to bottom of page
Do you mean line.jpg (not line.tif) is a background image and it does not extend to the bottom of the page? Does the lower area of the page remain white? This is why a screenshot (or a set of sample files - FO file and image files - sent to us) is necessary.


Regards,
Sorin

Re: Problem Background Image with block

Posted: Thu Apr 17, 2014 11:45 am
by Le Basque

Code: Select all


<fo:page-sequence force-page-count="auto" master-reference="PageMaster">
<fo:static-content flow-name="xsl-footnote-separator">
<fo:block>
<fo:leader color="black" leader-length="25%" leader-pattern="rule" rule-style="solid" rule-thickness="0.5pt" />
</fo:block>
</fo:static-content>
<fo:static-content flow-name="odd-frontmatter-footer">
<fo:block end-indent="10pt" space-after="10pt" space-after.conditionality="retain" text-align="end" />
</fo:static-content>
<fo:static-content flow-name="even-frontmatter-footer">
<fo:block space-after="10pt" space-after.conditionality="retain" start-indent="10pt" />
</fo:static-content>
<fo:static-content flow-name="odd-frontmatter-header">
<fo:block end-indent="10pt" space-before="10pt" space-before.conditionality="retain" text-align="left">xxxxx | yyyyyy | <fo:inline font-weight="bold"><fo:page-number /></fo:inline></fo:block>
</fo:static-content>
<fo:static-content flow-name="even-frontmatter-header">
<fo:block space-before="10pt" space-before.conditionality="retain" start-indent="10pt">
</fo:block>
</fo:static-content>
<fo:flow flow-name="xsl-region-body">
fo:block background-image="line.jpg" text-align="left" border-after-color="green" border-after-style="solid">
...
how include file in message ?
Thank you

Re: Problem Background Image with block

Posted: Thu Apr 17, 2014 3:53 pm
by sorin_ristache
If you want to set line.jpg as background image on the PDF front page and the image has 4970x7019 pixels, I think it is too large for one page. Is the image cut in the PDF output because it does not fit in one page? What do you mean when you say that a line in the background is not going to bottom of page?

Can you post a screenshot with the PDF output page (you can upload your screenshot to any image server, for example imageshack and link that in your reply on this forum) ? Can you post also a link to the image file line.jpg where it can be downloaded/viewed?


Regards,
Sorin

Re: Problem Background Image with block

Posted: Thu Apr 17, 2014 4:08 pm
by Le Basque
i use block-container whith height and it is OK

thank you for help