kindaian wrote:
> Vincent Hennebert escreveu:
<snip/>
>> But I think that Vangelis’ requirement was to make visible the amount of
>> whitespace left at the bottom of a column by the layout algorithm, when
>> no elastic space is available. In which case I’m afraid I can’t think of
>> any FO construction to achieve that. But maybe you will find the above
>> hint useful, after all.
>>
>>
> There is a simple trick...
>
> |------------------|
> ||----------------||
> ||  block 1       ||
> ||----------------||
> ||----------------||
> ||  block 2       ||
> ||----------------||
> ||----------------||
> ||  block 3       ||
> ||----------------||
> |                  |
> |  unused space    |
> |------------------|
>
> Just add a colored background in the table column.
> And add the "indented-normal" colour in background of each block. Some
> actual tests may be needed to check if this trick would do the expected
> result.

Neat idea! More generally, setting a background-color on the region-body
element, and surrounding the content of fo:flow by a block that resets
the background should do the job:
    <fo:layout-master-set>
      <fo:simple-page-master master-name="page" page-width="21"
        page-height="29.7" margin="2cm">
        <fo:region-body background-color="yellow"/>
      </fo:simple-page-master>
    </fo:layout-master-set>
    <fo:page-sequence master-reference="page">
      <fo:flow flow-name="xsl-region-body">
        <fo:block background-color="white">
          <!-- here the real content... -->
          ...


> The result will be that the unused space will appear coloured.
>
> Is this what you need Vangelis?
>
> Cheers
> ;)
>
> p.s.- this could be used to pre-render and ascertain  block dimensions
> in a pdf engine, naturally, different output targets would generate
> different results (I've to think about this, because this gives me some
> interesting ideas).
>
> p.s.- and thank you for the tip on the "elastic" spacing...

You’re welcome :-)

<snip/>

Vincent


-- 
Vincent Hennebert                            Anyware Technologies
http://people.apache.org/~vhennebert         http://www.anyware-tech.com
Apache FOP Committer                         FOP Development/Consulting

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

Reply via email to