Hi, what I am trying to do, is to get a black background
for the TIFF-image I am creating (by the template used
below). And I thought there are 2 ways to achieve this :

1.Set the background to black directly ( by using some
fo:region/fo:container tag)
2.If 1 doesn't work, insert a black-rectangle covering the hole image, so I
achieve
the same result as I would have done if 1 work.

But I just can't find which code to include and to include it at
the right place.This is what i need help with :=)

For the moment my XSL-FO looks like this :

<?xml version="1.0" encoding="ISO-8859-1" ?>

<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format";
xmlns:fox="http://xml.apache.org/fop/extensions";>

        <fo:layout-master-set>

                <fo:simple-page-master margin-right="1.0cm" margin-left="1.0cm"
margin-bottom="1.0cm" margin-top="1.0cm" page-width="20cm"
page-height="29.7cm" master-name="first">

                        <fo:region-before extent="1.0cm"/>

                        <fo:region-body margin-bottom="1.0cm" 
margin-top="1.0cm"/>

                        <fo:region-after extent="1.0cm"/>

                </fo:simple-page-master>

        </fo:layout-master-set>

        <fo:page-sequence master-reference="first" language="en" 
hyphenate="true">

        <fo:block-container position="absolute" width="1024pt" height="1024pt"
background-color="black"></fo:block-container>

<fo:static-content flow-name="xsl-region-before">

<fo:block line-height="12pt" font-size="10pt" space-before.optimum="1.5pt"
space-after.optimum="1.5pt"
keep-together="always">Template</fo:block></fo:static-content>

<fo:static-content flow-name="xsl-region-after">

<fo:block line-height="12pt" font-size="10pt" space-before.optimum="1.5pt"
space-after.optimum="1.5pt" keep-together="always">

        Testing Header

</fo:block></fo:static-content>

<fo:flow flow-name="xsl-region-body">

<fo:table table-layout="fixed" text-align="start">
<fo:table-column column-width="8.15cm"/>
<fo:table-column column-width="8.15cm"/>
<fo:table-body>

<fo:table-row>
        <fo:table-cell><fo:block line-height="12pt" font-size="10pt"
space-before.optimum="1.5pt" space-after.optimum="1.5pt"
keep-together="always" text-align="end">Test Cell
1</fo:block></fo:table-cell>
        <fo:table-cell><fo:block line-height="12pt" font-size="10pt"
space-before.optimum="1.5pt" space-after.optimum="1.5pt"
keep-together="always" text-align="start">Test Cell
2</fo:block></fo:table-cell>
</fo:table-row>

</fo:table-body></fo:table>

 <fo:block space-before.optimum="1.5pt" space-after.optimum="1.5pt"
keep-together="always" id="LastPage" line-height="1pt"
font-size="1pt"></fo:block></fo:flow>
</fo:page-sequence></fo:root>

So I would like to have black background to this template when creating the
TIFF.

Regards
/Gergely


-----Original Message-----
From: J.Pietschmann [mailto:[EMAIL PROTECTED]
Sent: Thursday, December 11, 2003 2:15 PM
To: [EMAIL PROTECTED]
Subject: Re: How to create a black rectangle


Gergely Hajdu wrote:

> Could someone PLEASE help me how to write code,
> to obtain black background ( maybe this can be set directly, or
> maybe by inserting a black rectangle that covers the hole page)
> for an image to be rendered ? And where should this code be
> inserted ?
>
> For the moment I have something like this :
>
> <fo:block-container position="absolute" width="100%" height="100%"
> fillColor="black"></fo:block-container>
>
> I know this is not right, but maybe you get an idea of what I am trying to
> do.

Adding another clue or two on what you are trying to achieve wouldn't
have hurt.
You can set background color for regions, or use a background image.
check here:
http://www.w3.org/TR/xsl/slice6.html#fo_region-body
http://www.w3.org/TR/xsl/slice7.html#common-border-padding-and-background-pr
operties

J.Pietschmann



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to