[texhax] TeX Queries (2): Artificial Break
zappathustra at free.fr
Wed Jul 18 08:29:05 CEST 2012
Paul Stanley <paulrichardstanley at gmail.com> a écrit:
> The latter result isn't so bad, but the lines are quite stretched,
> and of course there is that fourth single-word line, smaller than the
> paragraph indentation, which is quite bad-looking.
> By "stretched" do you mean the tracking space is too wide?
If by ``tracking'' you mean interword space, then yes; if on the other
hand you mean interletter space, then no. Letterspacing (``tracking''
proper) can be used in recent TeX engines, but not in Knuth's legacy
> Interestingly, I've browsed the first fifteen chapters of the
> TeXbook, and I haven't been able to find any last line of a paragraph
> being smaller than the indentation (at least when directly followed
> by an indented paragraph). So it seems that Knuth paid much attention
> to that, and what we're discussing here might be a situation where he
> had to rely on \break to do so. (There aren't so many \break's
> elsewhere in the text.)
> Is there a substitute for the visual inspection of the lines --- for
> example, a formula or some other heuristics --- in determining the
> appropriate amount of tracking in a paragraph (to ensure the glyphs
> aren't too stretched or compressed together)?
Unfortunately, I can't see how you can do that ``unvisually''. Of
course, TeX's algorithm is not visual at all: it simply has a default
space, plus maximum shrink and stretch of that space, and compute
everything so that the actual space in lines is as close as possible to
the default space (to put it simply). But space, stretch and shrink can
all be reset by hand (the default values are inherited from the font),
and that is a visual matter.
As for real tracking, i.e. letterspacing, it's all visual to me, but
perhaps somebody has found a nice formula (e.g. do not letterspace by
more than ...). The crux of the matter is that letterspacing should be
invisible, although of course it's often blatant in magazines with
> Could you expand a little more on vertical spacing please? I'm
> assuming it's not the same as leading, or is it?
It is. TeX takes into account the depth of the upper line (i.e. the
depth of the glyph with the larger descender) and height of the lower
line (i.e. the height of the glyph with the larger ascender) and adds
space so that the two baselines are spaced by a given amount
(\baselineskip). You can deactivate that operation, in which case the
distance between the baselines depends on the glyphs in the lines -- a
bad idea, of course.
> Finally, how, if at all, can tracking and kerning affect
> one-another? for example, does the kerning of a pair of glyphs
> override the tracking in the line?
As I've said, TeX normally doesn't letterspace. Personally, I haven't
played with letterspacing enough to make a sensible answer here, but I
suppose, since letterspacing should be invisible, that it doesn't
(Note that I've been talking about letterspacing in the main text here,
not the much more visible letterspacing sometimes used in all-cap text
More information about the texhax