Re: [xsl] Inline Formating: Line Height & Align

Subject: Re: [xsl] Inline Formating: Line Height & Align
From: "G. Ken Holman" <gkholman@xxxxxxxxxxxxxxxxxxxx>
Date: Mon, 16 Feb 2004 07:51:18 -0500
At 2004-02-16 13:12 +0100, Knut Meinke wrote:
I have a Problem with the line height.

I'm thinking you instead have a problem with font metrics.


I want to render a Price Field
with some Add-On Informations,
but I don't found _a way to align the Price (9.999,-) on the top of the
green box_. So the lower part overlaps
the Ad-On Box.

There are some attributes that seems to do what i want (alignment-adjust
& alignment-baseline & baseline-shift & dominant-baseline) but i don't
understand the standard and i don't find a way by my onwn :|

==> Here is the sample: http://tpmt.mytp.de/Uploads/test.pdf

==> code snipp <==

I copied your snippet locally, simplified it (I don't think you need the block containers, unless the height of the area is important to you) and continually had problems until I changed the font. The moment I changed the font to something available on my machine, everything fell into place.


My code is below.

Do you have some tipps or can explain this attributes?

Could you please try using a font like "Arial" just to see if another font does what you wish? I think there is a disconnect between the font description, the software knowledge of the metrics and the rendering of the font.


sorry for my ugly english!

I'm envious because it is better than my non-existent German!


I hope this helps.

..................... Ken

p.s. please pass around XML circles in your area that I'll be teaching (in English!) XSLT and XSL-FO in Bremen Germany in May.

<!--Product Price -->
        <fo:block-container  space-after = "2mm"
                height="20mm" background-color="green"
                font-family="Helvetica Neue LT Std Cn"
font-weight="bold" font-size="77pt">

                <fo:block line-height="1">9.999,-</fo:block>
        </fo:block-container>

<!--Price AddOn-->
        <fo:block-container  space-after = "2.5mm"
                height="11mm"
                font-family="Helvetica Neue LT Std" font-size="6pt">

                <fo:block>Price Price Price Price Price Price Price
Price Price Price Price Price Price Price AddOn</fo:block>
                <fo:block>Price Price Price Price Price Price Price
Price Price Price Price Price Price Price AddOn</fo:block>
        </fo:block-container>


<!--Product Price --> <fo:block background-color="green" line-height="1" space-after="2mm" font-family="Arial" font-weight="bold" font-size="77pt"> 9.999,- </fo:block>

<!--Price AddOn-->
        <fo:block space-after = "2.5mm"
                font-family="Arial" font-size="6pt">
                <fo:block>Price Price Price Price Price Price Price
Price Price Price Price Price Price Price AddOn</fo:block>
                <fo:block>Price Price Price Price Price Price Price
Price Price Price Price Price Price Price AddOn</fo:block>
        </fo:block>


-- Public courses: upcoming world tour of hands-on XSL training events Each week: Monday-Wednesday: XSLT/XPath; Thursday-Friday: XSL-FO Washington, DC: 2004-03-15 San Francisco, CA: 2004-03-22 Hong Kong: 2004-05-17 Germany: 2004-05-24 England: 2004-06-07 World-wide on-site corporate, government & user group XML training!

G. Ken Holman                  mailto:gkholman@xxxxxxxxxxxxxxxxxxxx
Crane Softwrights Ltd.           http://www.CraneSoftwrights.com/s/
Box 266, Kars, Ontario CANADA K0A-2E0     +1(613)489-0999 (F:-0995)
Male Breast Cancer Awareness   http://www.CraneSoftwrights.com/s/bc


XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list



Current Thread