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 robert frapples <oy...@gmail.com> on 2004/11/24 18:17:09 UTC

Re: Table Cell with height=100%...

NOTE: I realize this post is from over a year ago. Its a good starting
point for my question though.

The issue here is that a <fo:table:cell> takes up the full height of
the containing <fo:table-row>, but the <fo:block> in the
<fo:table-cell> takes up only the height it needs to display the
content.  What is needed is a way to make the <fo:block> take up the
full height of the <fo:table-cell> when the height of the cell (and
row) is determined by the content of another block.

height="from-parent(height)" does not work.
from-table-column() is not implemented.
height="100%" does not work
display="absolute" bottom="0in" does not work

Has anybody come up with a way to make a <fo:block> take up the full
height of the containing <fo:table-cell>?

> I have a table-cell that has�one word in it; "Notes:".
> The coloumn next to it has a dynamic amount of text in
> it.�What I'd like to�have is the border around the
> single word to�be the same height as the text colomn
> next to it.
>
> Below is�some�xsl-fo that demonstrates what I'm
> talking about... I want the border around the Notes:
> to be the same height as the border around the text.
>
> I tried setting the height of the block and the cell
> to be 100%, but that didn't work. FOP complained about
> having no conversion for %
>
> Thanks in advance...
> JasonV
>
><?xml version="1.0" encoding="UTF-8"?>
><fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
><!-- defines the layout master -->
><fo:layout-master-set>
>
><fo:simple-page-master master-name="product_page"
>page-height="8.5in" page-width="11.0in"
>margin-top="0.5in" margin-bottom="0.5in"
>margin-left="0.5in" margin-right="0.5in">
>
><fo:region-body margin-top="32pt"
>margin-bottom="22pt"/>
><fo:region-before extent="31pt"/>
><fo:region-after extent="21pt"/>
></fo:simple-page-master>
><!--The page sequence master defines the outline and
>order of page definitions that the PDF will follow.-->
><fo:page-sequence-master master-name="outline">
><fo:repeatable-page-master-reference
>master-reference="product_page"/>
></fo:page-sequence-master>
></fo:layout-master-set>
><fo:page-sequence master-reference="product_page">
><fo:flow flow-name="xsl-region-body">
><fo:table border="0.5pt solid black" width="100%"
>table-layout="fixed" keep-together="always">
><fo:table-column column-width="3.0in"/>
><fo:table-column column-width="1.0in"/>
><fo:table-column/>
><fo:table-body>
><fo:table-row keep-together="always">
><fo:table-cell padding="0.125in">
><fo:block padding-left="0.5pt">
>@MYIMAGE@
></fo:block>
></fo:table-cell>
><fo:table-cell padding-top="0.125in"
>padding-bottom="0.125in" border="0.5pt solid red">
><fo:block font-size="12pt" border="0.5pt solid black">
>Notes:
></fo:block>
></fo:table-cell>
><fo:table-cell padding="0.125in">
><fo:block font-size="12pt" border="0.5pt solid black">
><fo:block>THIS IS TEXT</fo:block>
><fo:block>THIS IS TEXT</fo:block>
><fo:block>THIS IS TEXT</fo:block>
><fo:block>THIS IS TEXT</fo:block>
><fo:block>THIS IS TEXT</fo:block>
><fo:block>THIS IS TEXT</fo:block>
><fo:block>THIS IS TEXT</fo:block>
></fo:block>
></fo:table-cell>
></fo:table-row>
></fo:table-body>
></fo:table>
></fo:flow>
></fo:page-sequence>
></fo:root>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-user-help@xml.apache.org


RE: Table Cell with height=100%...

Posted by Roland Neilands <rn...@pulsemining.com.au>.
Robert,

Try making the 'small margin' with thin table rows & columns.

Regards,
Roland 

> -----Original Message-----
> From: robert frapples [mailto:oyenstikker@gmail.com]
> Sent: Monday, 29 November 2004 1:52 AM
> To: fop-user@xml.apache.org
> Subject: Re: Table Cell with height=100%...
> 
> 
> That is exactly what I am trying to do.  The reason is that I want the
> borders for each cell to be seperated by a small margin.  I am able to
> do this with padding and indents on the table-cell and an fo:block
> with a border.
> 
> 
> On Wed, 24 Nov 2004 22:59:54 +0100, Andreas L. Delmelle
> <a_...@pandora.be> wrote:
> > > -----Original Message-----
> > > From: robert frapples [mailto:oyenstikker@gmail.com]
> > >
> > 
> > Hi,
> > 
> > > I want several cells in a single column with set widths, non-uniform
> > > amounts of text, identical borders, and vertically aligned text. I
> > > have done everything except for the borders.  I don't see how to make
> > > uniform borders using padding and background colors. If you can show
> > > me an example of that, I would be appreciative.
> > 
> > I'm a bit puzzled... It sounds like you want to use borders on the fo:block
> > and make them look like they are specified on the fo:table-cell? Why not
> > specify borders on the cells then?
> > 
> > Greetz,
> > 
> > Andreas
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-user-help@xml.apache.org


Re: Table Cell with height=100%...

Posted by robert frapples <oy...@gmail.com>.
That is exactly what I am trying to do.  The reason is that I want the
borders for each cell to be seperated by a small margin.  I am able to
do this with padding and indents on the table-cell and an fo:block
with a border.


On Wed, 24 Nov 2004 22:59:54 +0100, Andreas L. Delmelle
<a_...@pandora.be> wrote:
> > -----Original Message-----
> > From: robert frapples [mailto:oyenstikker@gmail.com]
> >
> 
> Hi,
> 
> > I want several cells in a single column with set widths, non-uniform
> > amounts of text, identical borders, and vertically aligned text. I
> > have done everything except for the borders.  I don't see how to make
> > uniform borders using padding and background colors. If you can show
> > me an example of that, I would be appreciative.
> 
> I'm a bit puzzled... It sounds like you want to use borders on the fo:block
> and make them look like they are specified on the fo:table-cell? Why not
> specify borders on the cells then?
> 
> Greetz,
> 
> Andreas

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-user-help@xml.apache.org


RE: Table Cell with height=100%...

Posted by "Andreas L. Delmelle" <a_...@pandora.be>.
> -----Original Message-----
> From: robert frapples [mailto:oyenstikker@gmail.com]
>

Hi,

> I want several cells in a single column with set widths, non-uniform
> amounts of text, identical borders, and vertically aligned text. I
> have done everything except for the borders.  I don't see how to make
> uniform borders using padding and background colors. If you can show
> me an example of that, I would be appreciative.

I'm a bit puzzled... It sounds like you want to use borders on the fo:block
and make them look like they are specified on the fo:table-cell? Why not
specify borders on the cells then?

Greetz,

Andreas


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-user-help@xml.apache.org


Re: Table Cell with height=100%...

Posted by robert frapples <oy...@gmail.com>.
I want several cells in a single column with set widths, non-uniform
amounts of text, identical borders, and vertically aligned text. I
have done everything except for the borders.  I don't see how to make
uniform borders using padding and background colors. If you can show
me an example of that, I would be appreciative.

On Wed, 24 Nov 2004 20:44:42 +0100, J.Pietschmann <j3...@yahoo.de> wrote:
> robert frapples wrote:
> 
> 
> > The issue here is that a <fo:table:cell> takes up the full height of
> > the containing <fo:table-row>, but the <fo:block> in the
> > <fo:table-cell> takes up only the height it needs to display the
> > content.  What is needed is a way to make the <fo:block> take up the
> > full height of the <fo:table-cell> when the height of the cell (and
> > row) is determined by the content of another block.
> >
> > height="from-parent(height)" does not work.
> > from-table-column() is not implemented.
> > height="100%" does not work
> > display="absolute" bottom="0in" does not work
> >
> > Has anybody come up with a way to make a <fo:block> take up the full
> > height of the containing <fo:table-cell>?
> 
> No way, the implementation of the height property for blocks is
> rather incomplete. However, why do you think you need this? You
> can set a background color or use a padding in the table cell
> directly (unless you want to link to content of the cell).
> 
> J.Pietschmann
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
> For additional commands, e-mail: fop-user-help@xml.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-user-help@xml.apache.org


Re: Table Cell with height=100%...

Posted by "J.Pietschmann" <j3...@yahoo.de>.
robert frapples wrote:
> The issue here is that a <fo:table:cell> takes up the full height of
> the containing <fo:table-row>, but the <fo:block> in the
> <fo:table-cell> takes up only the height it needs to display the
> content.  What is needed is a way to make the <fo:block> take up the
> full height of the <fo:table-cell> when the height of the cell (and
> row) is determined by the content of another block.
> 
> height="from-parent(height)" does not work.
> from-table-column() is not implemented.
> height="100%" does not work
> display="absolute" bottom="0in" does not work
> 
> Has anybody come up with a way to make a <fo:block> take up the full
> height of the containing <fo:table-cell>?

No way, the implementation of the height property for blocks is
rather incomplete. However, why do you think you need this? You
can set a background color or use a padding in the table cell
directly (unless you want to link to content of the cell).

J.Pietschmann

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-user-help@xml.apache.org