xsl-list
[Top] [All Lists]

[xsl] xsl-fo? center external-graphic and align start side of caption with start side of external-graphic

2009-12-08 14:13:39
I want some XSL-FO external-graphics to appear centered on the page,
with captions underneath

If the external-graphic is wider than the caption, then I want the left
or start side of the caption to be aligned with the left or start side
of the external-graphic

If the caption is wider than the external-graphic, then I want the
caption to appear centered on the page (I want the external-graphic also
centered on the page, as before)

To achieve this I wrapped both the external-graphic and the caption in
blocks, then wrapped both those blocks in one block, and set
text-align="center" on that block's container. Then I set
text-align="start" on the caption's block. I hoped this would have the
effect of centering the block containing both external-graphic and
caption, and aligning the caption against the start side of that block.
I guess it does, except the start side of the block containing both
isn't aligned with the start side of the external-graphic : (

http://www.sfu.ca/~jdbates/tmp/xsl/200912080/block.fo
http://www.sfu.ca/~jdbates/tmp/xsl/200912080/block.pdf

I also tried wrapping both blocks in a block-container, with the same
result,

http://www.sfu.ca/~jdbates/tmp/xsl/200912080/block-container.fo
http://www.sfu.ca/~jdbates/tmp/xsl/200912080/block-container.pdf

Can I achieve the layout I want with XSL-FO?

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

<Prev in Thread] Current Thread [Next in Thread>