[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Groff] holistic widow elimination
From: |
Pierre-Jean |
Subject: |
Re: [Groff] holistic widow elimination |
Date: |
Sat, 07 Jan 2012 20:25:16 +0100 |
User-agent: |
Heirloom mailx 12.5 7/5/10 |
Hello Dave,
hello alls,
This is a quite interesting problem, so I hope my opinion may
help.
Dave Kemper <address@hidden> wrote:
> In professionally typeset novels, when a page is shortened by
> one line
> to eliminate a widow on the following page, bottom-line
> alignment is
> handled in one of two ways (at least, in the novels where I've
> been able
> to figure out their trick):
>
> - the leading (aka line spacing) of the page is increased
> slightly, or
> - the facing page (whether preceding or following) is also
> shortened
> by one line.
I must add that in nicely typeset books, lines are always on the
same place on the page. So if you look the page in transparency,
you'll see that each line exactly recover the line of the other
side of the page. This is needed when the paper is not
perfectly opaque, but it's also a sign of well done job.
That means that the vertical unit of a page is the line spacing,
and if, for example, you add space before and after titles, you
should take care that the width of the title plus the extra
spaces is proportionnal to an amount of lines.
So, dealing with orphans by changing the line spacing, is just
a "not other choice" solution. You should prefer dealing with
interword and interletter spaces. This is usually invisible.
I'm personnaly doing this manually: I've just created two macros,
".min" and ".max", to minimize and maximize the width of a
paragraph, and I put them where it's needed.
One can also have this at the beginning of the paragraph macro,
to inform the position of orphans:
.nr orphan \\n[header-width]v+1v
.if \\n(nl=\\n[orphan] .tm Orphan on page \\n%, \\n(.F line
\\n(.c
One solution to automatically deal with that in a multi-pass
invocation of troff could use this trick:
* first pass: for each paragraph, output the position on the page
of the last word of the paragraph, the position on the line
of the last word of the paragraph, and the number of lines of
the paragraph. Also output page breaks caused by macros.
* It is now possible to find the best paragraph that should be
modified to avoid widows and orphans: it's a long one, with the
last word near the beginning or the end of the line, with no
page break between him and the widow.
* A filter could calculate that and add '.min' or '.max' at the
beginning of the paragraphs that need to be changed before the
next pass.
Cheers,
Pierre-Jean.
- [Groff] holistic widow elimination, Dave Kemper, 2012/01/07
- Re: [Groff] holistic widow elimination, Sverre Slotte, 2012/01/07
- Re: [Groff] holistic widow elimination,
Pierre-Jean <=
- Re: [Groff] holistic widow elimination, Peter Schaffter, 2012/01/07
- Re: [Groff] holistic widow elimination, Deri James, 2012/01/07
- Re: [Groff] holistic widow elimination, Ted Harding, 2012/01/07
- Re: [Groff] holistic widow elimination, Werner LEMBERG, 2012/01/08
- Re: [Groff] holistic widow elimination, Pierre-Jean, 2012/01/08
- Re: [Groff] holistic widow elimination, Werner LEMBERG, 2012/01/08