ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* modifying kerning breaks opentype ligatures (and other features)
@ 2018-12-10 15:26 mf
  2018-12-10 15:57 ` mf
  2018-12-10 16:14 ` Hans Hagen
  0 siblings, 2 replies; 11+ messages in thread
From: mf @ 2018-12-10 15:26 UTC (permalink / raw)
  To: Mailing list ConTeXt

Hello list,
i noticed that setting a different kerning breaks some features of 
opentype fonts; that is true, for example, for ligatures and fractions 
(frac feature).

It looks like a modified kerning inserts something between two adjacent 
character, making them no more adjacent.
That way the lookup of opentype tables fails.

"f", "l"            => "fl" ligature glyph

"f", [kerning], "l" => distinct "f" and "l" glyphs

"1", "/", "4" => "¼" glyph (with "frac" feature switched on)

"1", [kerning], "/", [kerning], "4" => distinct "1", "/", "4" glyphs 
(always with "frac" feature switched on)

MWE:

\definecharacterkerning[narrow][factor=-.015]
\definecharacterkerning[wide][factor=.015]

\definefontfeature[frac][frac=yes]

\starttext
\feature[+][frac]%
Some ligatures: float, finance, affine; a fraction: 1/4.

\setcharacterkerning[narrow]Some ligatures: float, finance, affine; a 
fraction: 1/4.

\setcharacterkerning[wide]Some ligatures: float, finance, affine; a 
fraction: 1/4.

\stoptext

In my XML to PDF workflow, fractions are marked up, so it's easy to 
switch the kerning off only for them.

Instead i have no solution for ligatures: parts of text with a modified 
kerning loose ligatures, and i end up with the same words, once with 
ligatures, once without, even in the same page.
Is there a workaround for this?

Massimiliano


___________________________________________________________________________________
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2018-12-12  0:00 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-10 15:26 modifying kerning breaks opentype ligatures (and other features) mf
2018-12-10 15:57 ` mf
2018-12-10 16:14 ` Hans Hagen
2018-12-10 17:16   ` mf
2018-12-10 18:33     ` Hans Hagen
2018-12-11 10:34     ` mf
2018-12-11 12:06       ` Hans Hagen
2018-12-11 12:45         ` mf
2018-12-11 13:52           ` Hans Hagen
2018-12-11 20:54         ` Rik Kabel
2018-12-12  0:00           ` Rik Kabel

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).