From: Hans Hagen <pragma@wxs.nl>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: Intraword spacing proof of concept
Date: Fri, 15 Aug 2008 09:49:40 +0200 [thread overview]
Message-ID: <48A53514.6030707@wxs.nl> (raw)
In-Reply-To: <1218749078.12095.30.camel@elbereth>
Charles P. Schaum wrote:
> Hi all,
>
> Quite a while ago I mentioned letter spacing, or the normal absence
> thereof, in TeX and friends. True, you could skin this cat by
> mathematically scaling the text (font size) by steps to fit the box ---
> the code is out there. But that was not the only way, thought I. Some
> programs also call this general idea tracking, that is, inserting
> positive or negative kerns independent of the \spacingfactor.
>
> Just for grins I nabbed two snippets from, respectively, manmac.tex and
> texbook.tex. I then added a bit of my own hackery that was inspired by
> DEK's length macro. I realized that a non-counting version of the length
> macro was a memory-friendly way to insert a symbol between any two
> others in a given sequence. What I wanted to insert was a negative kern.
>
> The negative kern must be small, less than \negthinspace, or else you
> start getting weird effects like a practically chiastic ordering of
> letters, and certainly a chaotic one. The smallest that one dare go
> seems to be -.066667em, the point where the serifs can start running
> together. Using -.033333em really does not show any letters running
> together, yet it still saves space. I got those figures as suggested by
> Knuth's own selections for tightness in the interword spacing.
>
> And yes, you could theoretically space out the letters, like the soul
> package that does proper Sperrdruck. One major drawback with my kludge
> is the need to use control spaces, else all spaces evaporate. If soul
> were ported to ConTeXt, and it seems like the code might allow that,
> then a version that "spaces in" and "spaces out" could well be possible.
in my opinion letterspacing only makes sense in titles, not in the main
body of text (i consider kerning to be part of the font design)
anyhow, since we have to letterspace titles and such, there is provision
for it in the core (non advertised low level stuff)
\stretched {The badness of this line is very bad.}
\hbox spread 2cm{\stretched {The badness of this line is very bad.}}
\def\stretchedspaceamount{.25em}
\stretchednormalcase {The badness of this line is very bad.}
\def\stretchedspaceamount{.5em}
\stretchednormalcase {The badness of this line is very bad.}
\def\stretchedspaceamount{-.125em}
\def\stretchedspacefactor{-4}
\stretchednormalcase {The badness of this line is very bad.}
\hbox{The badness of this line is very bad.}
ps. the negative kerning was not supported, but i enabled it in the beta
ps. in mkiv there is another model, one that permits kerning of
arbitrary text
Hans
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
| 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 / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
next prev parent reply other threads:[~2008-08-15 7:49 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-13 14:50 Partly OT: some luatex questions Ulrike Fischer
2008-08-13 21:07 ` Arthur Reutenauer
2008-08-14 7:48 ` Ulrike Fischer
2008-08-14 7:58 ` Wolfgang Schuster
2008-08-14 8:11 ` Hans Hagen
2008-08-14 12:25 ` Ulrike Fischer
2008-08-14 14:27 ` Hans Hagen
2008-08-14 9:07 ` Ulrike Fischer
2008-08-14 9:44 ` Wolfgang Schuster
2008-08-14 11:53 ` Ulrike Fischer
2008-08-14 13:49 ` Arthur Reutenauer
2008-08-14 14:28 ` Ulrike Fischer
2008-08-14 20:08 ` Hans Hagen
2008-08-14 21:24 ` Intraword spacing proof of concept Charles P. Schaum
2008-08-15 7:49 ` Hans Hagen [this message]
2008-08-15 15:50 ` Charles P. Schaum
2008-08-15 17:40 ` AUCTeX issues not necessarily ConTeXt-related Charles P. Schaum
2008-08-15 20:53 ` Peter Münster
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=48A53514.6030707@wxs.nl \
--to=pragma@wxs.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).