summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/babel-greek/greek.ldf
blob: 6c0f020b09af407ee9f102a2b57a7e81b46a5774 (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
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
%%
%% This is file `greek.ldf',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% greek.dtx  (with options: `code')
%% This is a generated file.
%% 
%% Copyright 1989-2008 Apostolos Syropoulos, Johannes L. Braams,  Guenter Milde,
%% and the authors listed elsewhere in this file. All rights reserved.
%% 
%% This file was generated from file(s) of the babel-greek package.
%% ----------------------------------------------------------------
%% 
%% It may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either version 1.3
%% of this license or (at your option) any later version.
%% The latest version of this license is in
%%   http://www.latex-project.org/lppl.txt
%% and version 1.3 or later is part of all distributions of LaTeX
%% version 2003/12/01 or later.
%% 
%% This work has the LPPL maintenance status "maintained".
%% 
%% The Current Maintainer of this work is Günter Milde <milde@users.sf.net>.
%% 
%% Babel-greek is a contributed package providing support for the Greek
%% language and script via the Babel system (http://www.ctan.org/pkg/babel).
%% 
%% The list of derived (unpacked) files belonging to this work
%% and covered by LPPL is defined by the unpacking script (greek.ins)
%% which is part of the package.
\ProvidesLanguage{greek}
        [2013/09/13 v1.7a Greek support for the babel system]
%% File `greek.dtx'
%% Babel package for LaTeX version 2e
%% Copyright (C) 1989 -- 2005
%%           by Johannes Braams, TeXniek
%% Greek language Definition File
%% Copyright (C) 1997, 2005
%%           by Apostolos Syropoulos
%%              Johannes Braams, TeXniek
%% Please report errors to: G\"unter Milde <milde@users.sf.net>
\LdfInit\CurrentOption{captions\CurrentOption}
\gdef\CurrentOption{greek}%
\ifx\l@greek\@undefined
  \@nopatterns{greek}
  \adddialect\l@greek0\fi
\bbl@declare@ttribute{greek}{polutoniko}{%
  \expandafter\addto\expandafter\extrasgreek
  \expandafter{\extraspolutonikogreek}%
  \let\captionsgreek\captionspolutonikogreek
  \let\gr@month\gr@c@month
  \let\l@polutonikogreek\l@greek
  \let\datepolutonikogreek\dategreek
  \let\extraspolutonikogreek\extrasgreek
  \let\noextraspolutonikogreek\noextrasgreek
  }
\ifdefined\if@bbl@greek@unicode
  \PackageError{babel}{if@bbl@greek@unicode already defined.\MessageBreak
    Please contact author of greek.ldf}
  \relax
\fi
\newif\if@bbl@greek@unicode
\ifdefined\luatexversion \@bbl@greek@unicodetrue \else
\ifdefined\XeTeXrevision \@bbl@greek@unicodetrue \fi\fi
\if@bbl@greek@unicode
  % No font encoding switch required with Unicode fonts.
  % Define dummy commands for |\textgreek| and |\greektext| (cf. below):
  \let\greektext\relax
  \let\textgreek\@firstofone
\else
  \@ifundefined{ver@lgrenc.def}{
    \InputIfFileExists{lgrenc.def}{}{%
      \errhelp{I can't find the lgrenc.def file for the Greek fonts}%
      \errmessage{Since I do not know the LGR font encoding^^J
        I can't typeset Greek with 8-bit TeX.^^J
        Please install the "greek-fontenc" package or use XeTeX/LuaTeX.}%
        \@@end
     }
   }{}
  \ProvideTextCommand{\textcopyright}{LGR}{\textlatin{\textcopyright}}
  \ProvideTextCommand{\textregistered}{LGR}{\textlatin{\textregistered}}
  \ProvideTextCommand{\texttrademark}{LGR}{\textlatin{\texttrademark}}
  \let\ltx@amp\&
  \DeclareTextCommandDefault{\&}{\ltx@amp}
  \DeclareTextCommand{\&}{LGR}{\textlatin{\ltx@amp}}
  \ProvideTextCommand{\SS}{LGR}{\textlatin{\SS}}
  \def\@roman#1{\expandafter\textlatin\expandafter{\romannumeral#1}}
  \def\@Roman#1{\expandafter\textlatin\expandafter{%
                \expandafter\@slowromancap\romannumeral#1@}}
  \DeclareTextCompositeCommand{\"}{LGR}{^^9F}{\accdialytika}
  \DeclareTextCompositeCommand{\'}{LGR}{^^9F}{\LGR@hiatus}
  \DeclareTextCompositeCommand{\`}{LGR}{^^9F}{\LGR@hiatus}
  \DeclareTextCompositeCommand{\<}{LGR}{^^9F}{\LGR@hiatus}
  \DeclareTextCompositeCommand{\>}{LGR}{^^9F}{\LGR@hiatus}
  \DeclareRobustCommand{\greektext}{%
    \fontencoding{LGR}\selectfont
    \def\encodingdefault{LGR}}
  \DeclareRobustCommand{\textgreek}[1]{\leavevmode{\greektext #1}}
  \def\outlfamily{\usefont{LGR}{cmro}{m}{n}}
  \DeclareTextFontCommand{\textol}{\outlfamily}
\fi  % End of LGR fixes not required with XeTeX/LuaTeX.
\providehyphenmins{\CurrentOption}{\@ne\@ne}
\addto\captionsgreek{%
  \def\prefacename{\textPi\textrho\'\textomicron\textlambda\textomicron%
    \textgamma\textomicron\textfinalsigma}%
  \def\refname{\textAlpha\textnu\textalpha%
    \textphi\textomicron\textrho\'\textepsilon\textfinalsigma}%
  \def\abstractname{\textPi\textepsilon\textrho\'\textiota%
    \textlambda\texteta\textpsi\texteta}%
  \def\bibname{\textBeta\textiota\textbeta\textlambda\textiota\textomicron%
    \textgamma\textrho\textalpha\textphi\'\textiota\textalpha}%
  \def\chaptername{\textKappa\textepsilon\textphi\'\textalpha%
    \textlambda\textalpha\textiota\textomicron}%
  \def\appendixname{\textPi\textalpha\textrho\'\textalpha\textrho%
    \texttau\texteta\textmu\textalpha}%
  \def\contentsname{\textPi\textepsilon\textrho\textiota%
    \textepsilon\textchi\'\textomicron\textmu\textepsilon\textnu\textalpha}%
  \def\listfigurename{\textKappa\textalpha\texttau\'\textalpha%
    \textlambda\textomicron\textgamma\textomicron\textfinalsigma{}
    \textSigma\textchi\texteta\textmu\'\textalpha\texttau\textomega\textnu}%
  \def\listtablename{\textKappa\textalpha\texttau\'\textalpha%
    \textlambda\textomicron\textgamma\textomicron\textfinalsigma{}
    \textPi\textiota\textnu\'\textalpha\textkappa\textomega\textnu}%
  \def\indexname{\textEpsilon\textupsilon\textrho\textepsilon%
    \texttau\'\texteta\textrho\textiota\textomicron}%
  \def\figurename{\textSigma\textchi\'\texteta\textmu\textalpha}%
  \def\tablename{\textPi\'\textiota\textnu\textalpha%
    \textkappa\textalpha\textfinalsigma}%
  \def\partname{\textMu\'\textepsilon\textrho\textomicron\textfinalsigma}%
  \def\enclname{\textSigma\textupsilon\textnu\texteta\textmu%
    \textmu\'\textepsilon\textnu\textalpha}%
  \def\ccname{\textKappa\textomicron\textiota\textnu\textomicron%
    \textpi\textomicron\'\textiota\texteta\textsigma\texteta}%
  \def\headtoname{\textPi\textrho\textomicron\textfinalsigma}%
  \def\pagename{\textSigma\textepsilon\textlambda\'\textiota%
    \textdelta\textalpha}%
  \def\seename{\textbeta\textlambda\'\textepsilon\textpi\textepsilon}%
  \def\alsoname{\textbeta\textlambda\'\textepsilon\textpi\textepsilon{}
    \textepsilon\textpi\'\textiota\textsigma\texteta\textfinalsigma}%
  \def\proofname{\textAlpha\textpi\'\textomicron%
    \textdelta\textepsilon\textiota\textxi\texteta}%
  \def\glossaryname{\textGamma\textlambda\textomega\textsigma%
    \textsigma\'\textalpha\textrho\textiota}%
  }
\let\captionspolutonikogreek\captionsgreek
\addto\captionspolutonikogreek{%
  \def\refname{\>\textAlpha\textnu\textalpha%
    \textphi\textomicron\textrho\`\textepsilon\textfinalsigma}%
  \def\indexname{\textEpsilon\<\textupsilon\textrho\textepsilon%
    \texttau\'\texteta\textrho\textiota\textomicron}%
  \def\figurename{\textSigma\textchi\~\texteta\textmu\textalpha}%
  \def\headtoname{\textPi\textrho\`\textomicron\textfinalsigma}%
  \def\alsoname{\textbeta\textlambda\'\textepsilon\textpi\textepsilon{}
    \>\textepsilon\textpi\'\textiota\textsigma\texteta\textfinalsigma}%
  \def\proofname{\>\textAlpha\textpi\'\textomicron%
    \textdelta\textepsilon\textiota\textxi\texteta}%
}
\def\gr@month{%
  \ifcase\month\or
    \textIota\textalpha\textnu\textomicron\textupsilon\textalpha%
      \textrho\'\textiota\textomicron\textupsilon\or
    \textPhi\textepsilon\textbeta\textrho\textomicron\textupsilon%
      \textalpha\textrho\'\textiota\textomicron\textupsilon\or
    \textMu\textalpha\textrho\texttau\'\textiota\textomicron\textupsilon\or
    \textAlpha\textpi\textrho\textiota\textlambda\'\textiota%
      \textomicron\textupsilon\or
    \textMu\textalpha\'"\textiota\textomicron\textupsilon\or
    \textIota\textomicron\textupsilon\textnu\'\textiota%
      \textomicron\textupsilon\or
    \textIota\textomicron\textupsilon\textlambda\'\textiota%
      \textomicron\textupsilon\or
    \textAlpha\textupsilon\textgamma\textomicron\'\textupsilon\textsigma%
      \texttau\textomicron\textupsilon\or
    \textSigma\textepsilon\textpi\texttau\textepsilon\textmu%
      \textbeta\textrho\'\textiota\textomicron\textupsilon\or
    \textOmicron\textkappa\texttau\textomega\textbeta%
      \textrho\'\textiota\textomicron\textupsilon\or
    \textNu\textomicron\textepsilon\textmu\textbeta%
      \textrho\'\textiota\textomicron\textupsilon\or
    \textDelta\textepsilon\textkappa\textepsilon\textmu\textbeta%
      \textrho\'\textiota\textomicron\textupsilon%
  \fi%
}
\def\dategreek{%
  \def\today{\number\day \space \gr@month\space \number\year}}
\def\gr@c@month{%
  \ifcase\month\or
    \>\textIota\textalpha\textnu\textomicron\textupsilon\textalpha%
      \textrho\'\textiota\textomicron\textupsilon\or
    \textPhi\textepsilon\textbeta\textrho\textomicron\textupsilon%
      \textalpha\textrho\'\textiota\textomicron\textupsilon\or
    \textMu\textalpha\textrho\texttau\'\textiota\textomicron\textupsilon\or
    \>\textAlpha\textpi\textrho\textiota\textlambda%
      \'\textiota\textomicron\textupsilon\or
    \textMu\textalpha\"'\textiota\textomicron\textupsilon\or
    \>\textIota\textomicron\textupsilon\textnu%
      \'\textiota\textomicron\textupsilon\or
    \>\textIota\textomicron\textupsilon\textlambda%
      \'\textiota\textomicron\textupsilon\or
    \textAlpha\>\textupsilon\textgamma\textomicron\'\textupsilon\textsigma%
      \texttau\textomicron\textupsilon\or
    \textSigma\textepsilon\textpi\texttau\textepsilon\textmu\textbeta%
      \textrho\'\textiota\textomicron\textupsilon\or
    \>\textOmicron\textkappa\texttau\textomega\textbeta%
      \textrho\'\textiota\textomicron\textupsilon\or
    \textNu\textomicron\textepsilon\textmu\textbeta%
      \textrho\'\textiota\textomicron\textupsilon\or
    \textDelta\textepsilon\textkappa\textepsilon\textmu%
      \textbeta\textrho\'\textiota\textomicron\textupsilon%
  \fi
}
\def\Grtoday{%
  \expandafter\Greeknumeral\expandafter{\the\day}\space
  \gr@c@month \space
  \expandafter\Greeknumeral\expandafter{\the\year}}
\if@bbl@greek@unicode
  \relax
\else
  \addto\extrasgreek{\greektext}
  \addto\noextrasgreek{\latintext}
\fi
\def\gr@ill@value#1{%
  \PackageWarningNoLine{babel}{Illegal value (#1) for greeknumeral}}
\DeclareRobustCommand\anw@false{%
  \DeclareRobustCommand\anw@print{}}
\DeclareRobustCommand\anw@true{%
  \DeclareRobustCommand\anw@print{\textdexiakeraia}} % \anwtonos
\anw@true
\def\greeknumeral#1{%
  \ifnum#1<\@ne\space\gr@ill@value{#1}%
  \else
    \ifnum#1<10\expandafter\gr@num@i\number#1%
    \else
      \ifnum#1<100\expandafter\gr@num@ii\number#1%
      \else
        \ifnum#1<\@m\expandafter\gr@num@iii\number#1%
        \else
          \ifnum#1<\@M\expandafter\gr@num@iv\number#1%
          \else
            \ifnum#1<100000\expandafter\gr@num@v\number#1%
            \else
              \ifnum#1<1000000\expandafter\gr@num@vi\number#1%
              \else
                \space\gr@ill@value{#1}%
              \fi
            \fi
          \fi
        \fi
      \fi
    \fi
  \fi
}
\def\Greeknumeral#1{%
  \expandafter\MakeUppercase\expandafter{\greeknumeral{#1}}}
\let\latin@alph\@alph
\let\latin@Alph\@Alph
\def\greek@alph#1{\expandafter\greeknumeral\expandafter{\the#1}}
\def\greek@Alph#1{\expandafter\Greeknumeral\expandafter{\the#1}}
\addto\extrasgreek{%
  \let\@alph\greek@alph
  \let\@Alph\greek@Alph}
\addto\noextrasgreek{%
  \let\@alph\latin@alph
  \let\@Alph\latin@Alph}
\def\gr@num@i#1{%
  \ifcase#1\or \textalpha\or \textbeta\or \textgamma\or \textdelta\or
  \textepsilon\or \textstigma\or \textzeta\or \texteta\or \texttheta\fi
  \ifnum#1=\z@\else\anw@true\fi\anw@print}
\def\gr@num@ii#1{%
  \ifcase#1\or \textiota\or \textkappa\or \textlambda\or \textmu\or
  \textnu\or \textxi\or \textomicron\or \textpi\or \textqoppa\fi
  \ifnum#1=\z@\else\anw@true\fi\gr@num@i}
\def\gr@num@iii#1{%
  \ifcase#1\or \textrho\or \textsigma\or \texttau\or \textupsilon\or
  \textphi\or \textchi\or \textpsi\or \textomega\or \textsampi\fi
  \ifnum#1=\z@\anw@false\else\anw@true\fi\gr@num@ii}
\def\gr@num@iv#1{%
  \ifnum#1=\z@\else\textaristerikeraia\fi
  \ifcase#1\or \textalpha\or \textbeta\or \textgamma\or \textdelta\or
  \textepsilon\or \stigma\or \textzeta\or \texteta\or \texttheta\fi
  \gr@num@iii}
\def\gr@num@v#1{%
  \ifnum#1=\z@\else\textaristerikeraia\fi
  \ifcase#1\or \textiota\or \textkappa\or \textlambda\or \textmu\or
  \textnu\or \textxi\or \textomicron\or \textpi\or \textqoppa\fi
  \gr@num@iv}
\def\gr@num@vi#1{%
  \textaristerikeraia
  \ifcase#1\or \textrho\or \textsigma\or \texttau\or \textupsilon\or
  \textphi\or \textchi\or \textpsi\or \textomega\or \textsampi\fi
  \gr@num@v}

\if@bbl@greek@unicode
  \InputIfFileExists{xgreek-fixes.def}{}{\PackageWarningNoLine{babel}{%
      Can't find the file "xgreek-fixes.def".\MessageBreak
      For correct up/downcasing of Greek text,\MessageBreak
      install the "polyglossia" package}%
    }
\else % 8-bit TeX
  \begingroup
    \@ifundefined{active@char\string!}{}{\catcode`!=12\relax}
    \catcode`\~=12
    \lccode`\!=`\~
    \lowercase{\def\x{\endgroup
        \def\greek@tilde{!}}\x}
  \addto\extrasgreek{%
    \babel@savevariable{\lccode`v}\lccode`v=`v%
    \babel@savevariable{\lccode`\'}\lccode`\'=`\'%
    \babel@savevariable{\lccode`\"}\lccode`\"=`\"}
  \addto\extraspolutonikogreek{%
    \babel@savevariable{\lccode`\<}\lccode`\<=`\<%
    \babel@savevariable{\lccode`\>}\lccode`\>=`\>%
    \babel@savevariable{\lccode`\~}\lccode`\~=`\~%
    \babel@savevariable{\lccode`\|}\lccode`\|=`\|%
    \babel@savevariable{\lccode`\`}\lccode`\`=`\`}
  \addto\extrasgreek{%
    \babel@savevariable{\uccode`\"}\uccode`\"=`\"%
    \babel@savevariable{\uccode`\'}\uccode`\'=159} %% 159 == ^^9f
  \addto\extraspolutonikogreek{%
    \babel@savevariable{\uccode`\~}\uccode`\~=159%
    \babel@savevariable{\uccode`\>}\uccode`\>=159%
    \babel@savevariable{\uccode`\<}\uccode`\<=159%
    \babel@savevariable{\uccode`\|}\uccode`\|=`\|%
    \babel@savevariable{\uccode`\`}\uccode`\`=159}
  \@tempcnta=\lccode`\~
  \lccode`\~=159
  \lowercase{%
    \initiate@active@char{~}%
    \declare@shorthand{greek}{~}{}}
  \lccode`\~=\@tempcnta
  \addto\extraspolutonikogreek{\languageshorthands{greek}}%
  \declare@shorthand{greek}{~}{\greek@tilde}
\fi  % End of LGR-specific code not required with XeTeX/LuaTeX.
\addto\extraspolutonikogreek{} % set up \extraspolutonikogreek for Xe/LuaTeX
\providecommand*{\anwtonos}{\textdexiakeraia}
\providecommand*{\katwtonos}{\textaristerikeraia}
\providecommand*{\qoppa}{\textqoppa}
\providecommand*{\stigma}{\textstigma}
\providecommand*{\sampi}{\textsampi}
\providecommand*{\Digamma}{\textDigamma}
\providecommand*{\ddigamma}{\textdigamma}
\providecommand*{\vardigamma}{\textvardigamma}
\providecommand*{\euro}{\texteuro}
\providecommand*{\permill}{\textperthousand}
\ldf@finish{\CurrentOption}
%% \CharacterTable
%%  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
%%   Lower-case    \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
%%   Digits        \0\1\2\3\4\5\6\7\8\9
%%   Exclamation   \!     Double quote  \"     Hash (number) \#
%%   Dollar        \$     Percent       \%     Ampersand     \&
%%   Acute accent  \'     Left paren    \(     Right paren   \)
%%   Asterisk      \*     Plus          \+     Comma         \,
%%   Minus         \-     Point         \.     Solidus       \/
%%   Colon         \:     Semicolon     \;     Less than     \<
%%   Equals        \=     Greater than  \>     Question mark \?
%%   Commercial at \@     Left bracket  \[     Backslash     \\
%%   Right bracket \]     Circumflex    \^     Underscore    \_
%%   Grave accent  \`     Left brace    \{     Vertical bar  \|
%%   Right brace   \}     Tilde         \~}
%%
\endinput
%%
%% End of file `greek.ldf'.