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
|
% Language definition file (part of polyglossia v2.2 -- 2024/07/15)
%
% Translations provided by ଅଶୋକ ଦାସ୍ <das@pas.rochester.edu> and ଅଭିଷେକ ଜେନା <avisekjena@gmail.com>
% TODO implement Odia calendar
\ProvidesFile{gloss-odia.ldf}[polyglossia: module for Odia]
\RequirePackage{devanagaridigits}
\RequirePackage{odiadigits}
\PolyglossiaSetup{odia}{
bcp47=or,
bcp47-language=or,
bcp47-script=Orya,
script=Odia,
scripttag=odia,
langtag=ODI,
hyphennames={odia},
hyphenmins={2,2},%CHECK
fontsetup=true,
localnumeral=odianumerals
%TODO nouppercase=true,
}
% BCP-47 compliant aliases
\setlanguagealias*{odia}{or}
%Adapted from gloss-bengali.ldf
\newif\ifodia@devanagari@numerals
\newif\ifodia@odia@numerals
\def\extras@odia{}
\def\noextras@odia{}
\DeclareKeys[polyglossia/gloss/odia]
{
changecounternumbering.if = odia@changecounternumbering,
changecounternumbering.default:n = true,
numerals.choice:,
numerals / devanagari.code =
{%
\odia@odia@numeralsfalse
\odia@devanagari@numeralstrue
\SetLanguageKeys{odia}{bcp47=or,bcp47-language=or,bcp47-extension-u=nu-deva}%
},
numerals / odia.code =
{%
\odia@odia@numeralstrue
\odia@devanagari@numeralsfalse
},
numerals / western.code =
{%
\odia@odia@numeralsfalse
\odia@devanagari@numeralsfalse
\SetLanguageKeys{odia}{bcp47=or,bcp47-language=or,bcp47-extension-u=nu-latn}%
},
numerals.default:n = devanagari,
numerals/unknown.code = \xpg@warning{Unknown Odia numeral `#1'}
}
% Register default options
\InitializeGlossOptions{odia}{changecounternumbering=false,numerals=Devanagari}
\def\captionsodia{%
\def\refname{ସନ୍ଦର୍ଭ}%
\def\abstractname{ସାରାଂଶ}%
\def\bibname{ସୂଚନା}%
\def\prefacename{ପ୍ରାରମ୍ଭ}%
\def\chaptername{ଅଧ୍ୟାୟ}%
\def\appendixname{ପରିଶିଷ୍ଟ}%
\def\contentsname{ସୁଚୀ ପତ୍ର}%
\def\listfigurename{ପ୍ରତିଛବି ତାଲିକା}%
\def\listtablename{ଟେବୁଲ ତାଲିକା}%
\def\indexname{ସୂଚକାଙ୍କ}%
\def\figurename{ପ୍ରତିଛବି}%
\def\tablename{ଟେବୁଲ୍}%
\def\partname{ବିଭାଗ}%
\def\pagename{ପୃଷ୍ଠା}%
\def\seename{ଦେଖନ୍ତୁ}%
\def\alsoname{ଅଧିକ ଦେଖନ୍ତୁ}%
\def\enclname{ସଂଲଗ୍ନ}%
\def\ccname{କପି କରନ୍ତୁ}%
\def\headtoname{ପ୍ରତି}%
\def\proofname{ପ୍ରମାଣ}%
\def\glossaryname{ଶବ୍ଦର ଶବ୍ଦକୋଷ}%
}
\def\dateodia{%
\def\odiamonth{%
\ifcase\month\or
ଜାନୁଆରୀ\or
ଫେବୃଆରୀ\or
ମାର୍ଚ୍ଚ\or
ଏପ୍ରିଲ୍\or
ମେ\or
ଜୁନ୍\or
ଜୁଲାଇ\or
ଅଗଷ୍ଟ\or
ସେପ୍ଟେମ୍ବର\or
ଅକ୍ଟୋବର\or
ନଭେମ୍ବର\or
ଡିସେମ୍ବର\fi}%
\def\today{\odianumber\day\space\odiamonth\space\odianumber\year}%
}
\newcommand{\odianumerals}[2]{\odianumber{#2}}
\def\odianumber#1{%
\ifodia@devanagari@numerals
\devanagaridigits{\number#1}%
\else
\ifodia@odia@numerals
\odiadigits{\number#1}%
\else % Assumed Western
\number#1%
\fi
\fi%
}
\def\odia@globalnumbers{%
\ifodia@changecounternumbering
\let\@arabic\odianumber%
\renewcommand\thefootnote{\localnumeral*{footnote}}%
\fi
}
%Adapted from gloss-marathi.ldf
\def\odia@akshar#1{\ifcase#1\or ଅ\or ଆ\or ଇ\or ଈ\or ଉ\or ଊ\or ଋ\or ଏ\or ଐ\or ଓ\or ଔ\else\@ctrerr\fi}
\def\odia@alph#1{%
\ifcase#1\or କ\or ଖ\or ଗ\or ଘ\or ଙ\or ଚ\or ଛ\or ଜ\or ଝ\or ଞ\or ଟ\or ଠ\or ଡ\or ଢ\or ଣ\or ତ\or ଥ\or ଦ%
\or ଧ\or ନ\or ପ\or ଫ\or ବ\or ଭ\or ମ\or ଯ\or ର\or ଲ\or ଳ\or ଶ\or ସ\or ଷ\or ହ\or କ୍ଷ \else\@ctrerr%
\fi%
}
\def\odia@numbers{%
\let\@alph\odia@alph
\let\@Alph\devanagari@letter
\let\@roman\odia@akshar
\let\@Roman\devanagari@letter
}
% Store original definition
\let\xpg@save@arabic\@arabic
\def\noodia@globalnumbers{%
\let\@arabic\xpg@save@arabic%
}
\def\blockextras@odia{\extras@odia}
\def\inlineextras@odia{\extras@odia}
\endinput
|