I am not quite sure what you are after but I do believe the current FOP behavior is correct with respect to the specification. And yes, you won't see any difference in glyph placing in your scenario and nor should you. In the default case line-height is determined by the 'em' box defined by the font (which is a fixed size box (at least in height) for a given font) plus a small margin for line spacing (the half-leading). The fonts 'em' box also defines the position of the default alignment baseline. This guarantees that in a paragraph written in the same font all lines are equally spaced independent of which sets of glyphs from the font appear on each line. It also guarantees if you have two paragraphs in adjacent cells in a table both using the same font that all lines are properly aligned across the cells (assuming identical settings). Both of these effects are highly desirable in common typesetting scenarios.
You can manipulate this behavior by adjusting various properties, like line-height, line-stacking-strategy, alignment-baseline, .... > -----Original Message----- > From: j1997 [mailto:[EMAIL PROTECTED] > Sent: Monday, 6 October 2008 5:51 PM > To: [email protected] > Subject: Re: Upgrade 0.20.5 to 0.95: all texts are shifted to top! > > > > Vincent Hennebert-2 wrote: > > > > I guess FOP 0.20.5 was taking the height of the biggest letter for the > > line height, which is wrong; what's supposed to happen if you put a word > > like 'jaguar' in one cell, and 'ToDo' in the next cell? Should the > > baselines be aligned or not? > > > > Details can be found in section 4.5 of the XSL-FO specification [1] (who > > said this section was scary?). In short, the line height is the sum of > > text-altitude and text-depth [2]. Those are taken from the font metrics > > and are general (i.e., apply to every glyph, even those that don't hang > > below the baseline). So the effect is what you noticed: if a word > > doesn't have any letter with a descender, it will look like it's > > shifted, whereas technically speaking it's not. > > > > [1] http://www.w3.org/TR/xsl11/#area-line > > [2] http://www.w3.org/TR/xsl11/#text-depth > > > > I did some more testing and the result is, that the new FOP 0.95 always > has > the same result: > > <fo:block text-align="start" font-family="{$Font}" > font-size="20pt" color="{$TitleFontColor}"> > <xsl:text>geeeeeeeeeeeeeeeeee</xsl:text> > </fo:block> > > No matter if I only set capital letters or only small caps, only "gjy" or > with/without paranthesis, all examples have the same result, i.e. a letter > is always placed at the same horizontal position - no matter if/what other > letters are in the same line/block. In my example font, the text is always > displayed that an "e" is exactly horizontal centered. > > As you might argue, that it's more "correct" to center the small letters > like "e", it looks really awkward if a line/block only has a number, > because > the digits are also "shifted upwards". > > > In addition, with the fo:inline "workaround", the whole line/block gets a > bigger height. :-( > -- > View this message in context: http://www.nabble.com/Upgrade-0.20.5-to- > 0.95%3A-all-texts-are-shifted-to-top%21-tp19779752p19834943.html > Sent from the FOP - Users mailing list archive at Nabble.com. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
