W3C home > Mailing lists > Public > www-xsl-fo@w3.org > July 2002

Re: Centering text in a table cell with number-rows-spanned

From: Brindl Ronald <rbrindl@gmx.at>
Date: Sat, 6 Jul 2002 17:49:49 -0400 (EDT)
Message-ID: <001601c22537$081e7d00$3264a8c0@ronmobil>
To: <www-xsl-fo@w3.org>




This doesnt work for me when I try do make a table with one single cell to
position some text in the center of a page:

I tried the following:

<fo:table height="200px">
  <fo:table-column column-width="200px"/>
  <fo:table-body>
     <fo:table-row>
          <fo:table-cell height="50px" display-align="center">
               <fo:block text-align="center">test3</fo:block>
          </fo:table-cell>
     </fo:table-row>
   </fo:table-body>
</fo:table>

the result looks like:
                     test3

(test3 on top of the page)
if i make a table with 2 columns and in one cell i have multiline text and
in the cell beside that i have one line of text and i do
"display-align="center"", then it works.
it seems, the height gets collapsed for the calculation of the vertical
position, alltough the height of the cell is correct (i tried that by
placing a second row below that).

is there any other possibility to place a block vertically centered on a
page?
Received on Monday, 8 July 2002 03:48:54 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 3 October 2007 16:06:09 GMT