blob: 42bbf9718a8420a922867f539dde1b154d004fb5 (
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
|
%D \module
%D [ file=regi-ini,
%D version=2000.12.27, % 1998.12.03,
%D title=\CONTEXT\ Regime Macros,
%D subtitle=Initialization,
%D author=Hans Hagen,
%D date=\currentdate,
%D copyright={PRAGMA / Hans Hagen \& Ton Otten}]
%C
%C This module is part of the \CONTEXT\ macro||package and is
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
\unprotect
%D Messages (to be translated).
\startmessages dutch library: regimes
title: regime
1: regime --
2: regime -- wordt geladen
3: onbekend regime --
\stopmessages
\startmessages english library: regimes
title: regime
1: regime --
2: regime -- is loaded
3: unknown regime --
\stopmessages
\startmessages german library: regimes
title: Kodierung
1: Kodierung --
2: Kodierung -- ist geladen
3: Unbekannte Kodierung --
\stopmessages
\startmessages czech library: regimes
title: kodovani
1: kodovani --
2: je nacteno kodovani --
3: nezname kodovani --
\stopmessages
\startmessages italian library: regimes
title: codifica
1: codifica --
2: codifica -- caricata
3: codifica sconosciuta --
\stopmessages
\startmessages norwegian library: regimes
title: koding
1: koding --
2: koding -- er lest inn
3: ukjent koding --
\stopmessages
\startmessages romanian library: regimes
title: codificari
1: codificarea --
2: codificarea -- este Encarcata
3: codificarea -- este necunoscuta
\stopmessages
\startmessages french library: regimes
title: encodage
1: encodage --
2: l'encodage -- est chargé
3: encodage -- inconnu
\stopmessages
%D Variables.
\def\@reg@{@r@eg@} % regime prefix
%D \macros
%D {currentregime}
\let\currentregime\empty
\let\defaultregime\s!default
%D Plugin interface.
\let\mkloadregime \gobbleoneargument
\let\mkenableregime \gobbleoneargument
\let\mkdisableregime\relax
\let\mkshowregime \gobbleoneargument
\let\mkwalkregime \gobbleoneargument
\let\mkautosetregime\gobbletwoarguments
%D Some low level inheritance stuff (mkii).
\def\doautosetregime{\mkautosetregime}
%D \macros
%D {defineregimesynonym,trueregimename}
\def\defineregimesynonym
{\dodoubleargument\dodefineregimesynonym}
\def\dodefineregimesynonym[#1][#2]%
{\setevalue{\@reg@:s:#1}{#2}}
\def\trueregimename#1%
{\executeifdefined{\@reg@:s:#1}{#1}}
%D \macros
%D {useregime}
\def\useregime[#1]%
{\processcommalist[#1]\douseregime}
\def\douseregime#1%
{\doifundefined{\c!file\f!regimeprefix#1}%
{\letgvalue{\c!file\f!regimeprefix#1}\empty
\mkloadregime{#1}}}
%D \macros
%D {enableregime,disableregime}
\let\enabledregime\empty
\def\enableregime[#1]%
{\edef\currentregime{\trueregimename{#1}}%
\doifelsenothing\currentregime
{\disableregime}
{\douseregime\currentregime
\mkenableregime\currentregime}}
\def\disableregime
{\let\currentregime\empty
\mkdisableregime}
%D \macros
%D {protectregime, settoletterunlessactive, settocodeunlessactive}
%D
%D The next boolean is used later on to prevent unwanted
%D catcode changes. Use it with care.
\newif\ifprotectregime \protectregimetrue
\def\settoletterunlessactive#1%
{\ifprotectregime\ifnum\catcode#1=\active\else
\catcode#1\@@letter
\fi\else
\catcode#1\@@letter
\fi}
\def\settootherunlessactive#1%
{\ifprotectregime\ifnum\catcode#1=\active\else
\catcode#1=\@@other
\fi\else
\catcode#1=\@@other
\fi}
\def\settocodeunlessactive#1#2%
{\ifprotectregime\ifnum\catcode#1=\active\else
\catcode#1=#2\relax
\fi\else
\catcode#1=#2\relax
\fi}
%D Sort related:
\def\dowalkregime{\mkwalkregime} % #1
%D \macros
%D {showregime}
\def\showregime
{\dosingleempty\doshowregime}
\def\doshowregime[#1]%
{\mkshowregime{#1}}
%D Plugins.
\loadmarkfile{regi-ini}
\protect \endinput
|