From: Hans Hagen <j.hagen@xs4all.nl>
To: ntg-context@ntg.nl
Subject: [NTG-context] Re: “breaking news”
Date: Tue, 1 Oct 2024 00:17:05 +0200 [thread overview]
Message-ID: <d7c5e3dc-e1f6-41db-97ca-0557248e1068@xs4all.nl> (raw)
In-Reply-To: <1ae08539-98d5-44f9-b20a-aeb461b06d30@fiee.net>
On 9/30/2024 10:45 PM, Henning Hraban Ramm wrote:
> Am 30.09.24 um 20:14 schrieb Hans Hagen:
>> On 9/30/2024 6:22 PM, Henning Hraban Ramm wrote:
>>> Hi,
>>> since the latest update, I have differences in line/paragraph/page
>>> breaking. I should have expected that vz and granular aren’t stable
>>> yet, but maybe it’s a problem in my setup and not even related to
>>> that update.
>>>
>>> * widow and orphan penalties seem to work different, preferring empty
>>> lines over single lines.
>>> * looseness doesn’t seem to work any more.
>>>
>>> Were there changes?
>>
>> Not intentionally. We're bringing widow and club penalties stepwise
>> under \setupalign control so maybe something was forgotten. For
>> instance, \widowpenalty and \widowpenalties are competing and the next
>> upload will deal with that (first we need to test some complex
>> documents).
>
> It’s probably something I changed and can’t find it in my git log.
>
> Generally it seems to be a bit better than before, needs less trickery,
> but it’s different enough that I had to start work on my current book
> from the beginning.
>
> It’s a novel of ~650 pages with a big range of paragraph lengths (some
> dialogues with short lines as well as paragraphs that span pages). “Of
> course” you often get a 3-line paragraph over a page break – it’s hard
> to avoid widows and orphans.
depends .. three liners can be made to work in fact one should then use
\widowpenalties and \clubpenalties with a high value for the first two
entries (and maybe disable them to overlap)
here is a teaser:
\permanent \specificationdef \lesswidowpenalties \widowpenalties
\plusthree options
\numexpr\largestspecificationoptioncode+\doublespecificationoptioncode\relax
\plusfivethousand \plusseventyfivehundred
\plustwohundredfifty \plusfivehundred
\zerocount \zerocount
\relax
\permanent \specificationdef \lessclubpenalties \clubpenalties
\plusthree options
\numexpr\largestspecificationoptioncode+\doublespecificationoptioncode\relax
\plusfivethousand \plusseventyfivehundred
\plustwohundredfifty \plusfivehundred
\zerocount \zerocount
\relax
used in upcoming new \setupalign options lesswidows and lessclubs
because the above is not something that users should nother about.
These set high penalties for the first and last line, somewhat lower for
the ones following and preceding.
We also have strictwidows and strictclubs that do your three thing.
In case you wonder about the 'double' ... we can have different values
for left and right pages because (we think that) on a spread a widow or
club is less of a problem.
Fwiw, much of this of this already has been there for a while (as
discussed at the meeting) but we're now integrating it into \setupalign
and making sure that the overhead can be neglected.
> I already do without grid, VZ works, HZ also should (I didn’t check with
> a tracker, and it’s not so extreme that I’d see it), but it’s not enough
> to automatically avoid single lines.
Indeed, so the stricter penalties combine well with vz
> If a paragraph starts at page breaks, I can tweak the layout like
> \page\setuplayout[narrow]. I defined narrow, normal, and wide versions
> with 1 mm difference. Before I didn’t know you can call named layouts
> like this, also relative page numbers like \definelayout[+1][wide] are
> nice.
>
> If that’s not enough, I’m using \letterspacing with tiny ± values.
>
> So much about dirty tricks. ;)
parpasses will permit you to have steps with different solutions so
expansion can be delayed till it is really needed; interesting is that
even with (say 8) par passes, most time the solution is found in the
first (no hyphenation with 100 tolerance) or second pass (hyphenation
with 200 tolerance) and the number last pass can be counted on one hand
(there are options to mark pararaphs and see what pass succeeded as well
as overviews in the logs so that one can go to problematic places but
that's for Keith to experiment with)
We're really surprised how well this all works on complex content (say
very math intense, read: demanmding wrt where to break).
Hans
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___________________________________________________________________________________
next prev parent reply other threads:[~2024-09-30 22:22 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-30 16:22 [NTG-context] " Henning Hraban Ramm
2024-09-30 18:14 ` [NTG-context] " Hans Hagen
2024-09-30 20:45 ` Henning Hraban Ramm
2024-09-30 22:17 ` Hans Hagen [this message]
2024-10-01 19:16 ` Henning Hraban Ramm
2024-10-01 19:31 ` Hans Hagen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=d7c5e3dc-e1f6-41db-97ca-0557248e1068@xs4all.nl \
--to=j.hagen@xs4all.nl \
--cc=ntg-context@ntg.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).