Hello, I am using fop-0.20.3 to generate some PDF documents. Now I wish to get a gray background for the document's hole pages, independent from the size of their content. According to the XSL-FO specification the tag <fo:region-body> supports an attribute "background-color", so what I tried is the following:
<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"> <fo:layout-master-set> <fo:simple-page-master page-height="841.9pt" page-width="595.3pt" master-name="spm_1"> <fo:region-body background-color="#d9d9d9" region-name="region-body"/> </fo:simple-page-master> </fo:layout-master-set> <fo:page-sequence master-reference="spm_1"> <fo:flow flow-name="region-body"> <fo:block>Test</fo:block> </fo:flow> </fo:page-sequence> </fo:root> But in the resulting PDF none gray area does appear. It would not help to use a tag <fo:block-container background-color="#d9d9d9">, because the document's content may take several pages, so the containers height would be unknown. I also tried to place a gray block-container as <fo:static-content>, but then it is in the foreground and overwrites the pages' content. Could anybody please give me a hint how to solve my problem? Kind regards and thanks in advance, Bjoern Luetkemeier