summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/polyglossia/gloss-welsh.ldf
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/polyglossia/gloss-welsh.ldf')
-rw-r--r--Master/texmf-dist/tex/latex/polyglossia/gloss-welsh.ldf23
1 files changed, 17 insertions, 6 deletions
diff --git a/Master/texmf-dist/tex/latex/polyglossia/gloss-welsh.ldf b/Master/texmf-dist/tex/latex/polyglossia/gloss-welsh.ldf
index 686ea18e7ac..bb2c9e87cca 100644
--- a/Master/texmf-dist/tex/latex/polyglossia/gloss-welsh.ldf
+++ b/Master/texmf-dist/tex/latex/polyglossia/gloss-welsh.ldf
@@ -1,20 +1,31 @@
\ProvidesFile{gloss-welsh.ldf}[polyglossia: module for welsh]
\PolyglossiaSetup{welsh}{
+ bcp47=cy,
hyphennames={welsh},
hyphenmins={2,3},
langtag=WEL,
fontsetup=true,
}
+% BCP-47 compliant aliases
+\setlanguagealias*{welsh}{cy}
+
\providebool{welsh@formaldate}
-% TODO (maybe) Interface to change that mid-document
-\define@key{welsh}{date}{%
- \ifstrequal{#1}{long}{%
- \welsh@formaldatetrue
- }% Anything else gives \welsh@formaldatefalse
-}
+\define@choicekey*+{welsh}{date}[\val\nr]{long,short}[short]{%
+ \ifcase\nr\relax
+ % long:
+ \welsh@formaldatetrue
+ \or
+ % accented:
+ \welsh@formaldatefalse
+ \fi
+ \xpg@info{Option: Welsh, date=\val}%
+}{\xpg@warning{Unknown date value `#1'}}
+
+% Register default options
+\xpg@initialize@gloss@options{welsh}{date=short}
\def\captionswelsh{%
\def\refname{Cyfeiriadau}%