1
2
3
4
5
6
7
8
9
10
11
12
13
14\writestatus{loading}{ConTeXt Math Macros Scripts}
15
16\unprotect
17
18
19
20
21
22
23\def\math_scripts_raised_symbol#1
24 {\mathchoice
25 {\math_scripts_raised_symbol_indeed5\tf {#1}}
26 {\math_scripts_raised_symbol_indeed5\tf {#1}}
27 {\math_scripts_raised_symbol_indeed4\tx {#1}}
28 {\math_scripts_raised_symbol_indeed3\txx{#1}}}
29
30\def\math_scripts_raised_symbol_indeed#1#2#3
31 {\mathord{#2\raise.#1\exheight\hbox{#2\symbol[#3]}}}
32
33\def\math_scripts_raised_number#1
34 {\mathchoice
35 {\math_scripts_raised_number_indeed\tf {#1}}
36 {\math_scripts_raised_number_indeed\tf {#1}}
37 {\math_scripts_raised_number_indeed\tx {#1}}
38 {\math_scripts_raised_number_indeed\txx{#1}}}
39
40\def\math_scripts_raised_number_indeed#1#2
41 {\setbox\scratchbox\hbox{0}
42 \mathord{\hbox to \wd\scratchbox{\hss#1\symbol[#2]\hss}}}
43
44\definesymbol[positive] [\getglyph{Mono}{}]
45\definesymbol[negative] [\getglyph{Mono}{}]
46\definesymbol[zeroamount][\getglyph{Mono}{}]
47
48\permanent\protected\def\negative {\math_scripts_raised_symbol{negative}}
49\permanent\protected\def\positive {\math_scripts_raised_symbol{positive}}
50\permanent\protected\def\zeroamount{\math_scripts_raised_number{zeroamount}}
51
52
53
54
55
56
57
58\protect \endinput
59 |