summaryrefslogtreecommitdiff
path: root/tex/context/modules/mkiv/s-lingual-de.mkiv
blob: d5436e1e2f039b964925c5a7c16ea43f9826634b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
%D \module
%D   [      file=s-lingual-de,
%D        version=2016.04.17,
%D          title=\CONTEXT\ Linguistic File,
%D       subtitle=German TWeaks,
%D         author=Hans Hagen,
%D           date=\currentdate,
%D      copyright={PRAGMA ADE \& \CONTEXT\ Development Team}]
%C
%C This module is part of the \CONTEXT\ macro||package and is
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.

\startluacode
    fonts.handlers.otf.addfeature {
        name = "sz",
        type = "multiple",
        data = {
            ["ẞ"] = { "S", "S" }
        }
    }
\stopluacode

\definefontfeature[sz][sz=yes]

\unexpanded\def\enableuppercasesharps {\overloaduppercase{0xDF}{0x1E9E}}
\unexpanded\def\disableuppercasesharps{\overloaduppercase{0xDF}{0x53,0x53}}

\installtexdirective
  {fonts.uppercasesharps}
  \enableuppercasesharps
  \disableuppercasesharps

\continueifinputfile{s-lingual-de.mkiv}

\setupbodyfont[libertine]

\starttext
    \def\TestString{Buße Busse BUẞE BUSSE \WORD{Buße Busse}}
   %\definefontfeature[default][default][sz=yes]
    \dorecurse{5} {
        \disableuppercasesharps
        \TestString\par
        \enableuppercasesharps
        \TestString\par
        {\addfeature{sz}\TestString}\par
    }
\stoptext