ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* ligatures/substituation at word boundaries
@ 2017-07-27 18:09 Ulrike Fischer
  2017-07-28 21:21 ` Hans Hagen
  0 siblings, 1 reply; 4+ messages in thread
From: Ulrike Fischer @ 2017-07-27 18:09 UTC (permalink / raw)
  To: ntg-context

Is it possible to refer in fonts.handlers.otf.addfeature to the word
boundary? The luatex manual speaks of a virtual "left_boundary"
char, but I couldn't find a way to use it. 

\startluacode
    fonts.handlers.otf.addfeature {
        name = "ltest",
        type = "ligature",
        data = {
            ['1'] = { "a", "b" },
            ['2'] = { "d", "a" },
        }
    }
\stopluacode

%how to replace only the start a????

\startluacode
    fonts.handlers.otf.addfeature {
        name = "wtest",
        type = "ligature",
        data = {
            ['1'] = { "left_boundary", "a" },
        }
    }
\stopluacode

\definefontfeature[wtest][wtest=yes]
\definefontfeature[ltest][ltest=yes]
\starttext

    \definedfont[file:dejavu-serif.ttf*default]%


    {\addff{ltest} ababa\par}

    {\addff{wtest} ababa\par}


\stoptext





-- 
Ulrike Fischer 
http://www.troubleshooting-tex.de/

___________________________________________________________________________________
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] 4+ messages in thread

end of thread, other threads:[~2017-07-30 14:52 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-07-27 18:09 ligatures/substituation at word boundaries Ulrike Fischer
2017-07-28 21:21 ` Hans Hagen
2017-07-30  9:39   ` Ulrike Fischer
2017-07-30 14:52     ` Hans Hagen

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