summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/babel-greek/greek.ldf
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2023-03-04 21:09:20 +0000
committerKarl Berry <karl@freefriends.org>2023-03-04 21:09:20 +0000
commitec142bccfefd46708d42e2431f91e47cfb92e99a (patch)
tree048c6baeb7d75df07bb5048192db70a9a24a49ea /Master/texmf-dist/tex/generic/babel-greek/greek.ldf
parent3a00abb8ff4e1a4cffd27b79441a3f7e1b1f5578 (diff)
babel-greek (4mar23)
git-svn-id: svn://tug.org/texlive/trunk@66346 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/generic/babel-greek/greek.ldf')
-rw-r--r--Master/texmf-dist/tex/generic/babel-greek/greek.ldf378
1 files changed, 235 insertions, 143 deletions
diff --git a/Master/texmf-dist/tex/generic/babel-greek/greek.ldf b/Master/texmf-dist/tex/generic/babel-greek/greek.ldf
index 6c920e715eb..0c67a235de6 100644
--- a/Master/texmf-dist/tex/generic/babel-greek/greek.ldf
+++ b/Master/texmf-dist/tex/generic/babel-greek/greek.ldf
@@ -7,7 +7,7 @@
%% babel-greek.dtx (with options: `code')
%% This is a generated file.
%%
-%% Copyright 1989-2008 Apostolos Syropoulos, Johannes L. Braams, Guenter Milde,
+%% Copyright 1989-2008 Apostolos Syropoulos, Johannes L. Braams, Günter Milde,
%% and the authors listed elsewhere in this file. All rights reserved.
%%
%% This file was generated from file(s) of the babel-greek package.
@@ -26,61 +26,78 @@
%% 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).
+%% language and script via the Babel system (https://ctan.org/pkg/babel).
%%
%% The list of derived (unpacked) files belonging to this work
%% and covered by LPPL is defined by the unpacking script (babel-greek.ins)
%% which is part of the package.
\ProvidesLanguage{greek}
- [2020/11/10 v1.10 Greek support for the babel system]
+ [2023/03/04 1.12 Greek support for the babel system]
%% File `babel-greek.dtx'
%% Greek language Definition File
%% Copyright © 1997, 2005 Apostolos Syropoulos, Johannes Braams
-%% Copyright © 2013, 2019 Günter Milde
+%% Copyright © 2013 -- 2020 Günter Milde
%% Please report errors to: Günter Milde <milde@users.sf.net>
\LdfInit\CurrentOption{captions\CurrentOption}
\gdef\CurrentOption{greek}
\ifx\l@greek\@undefined
\@nopatterns{greek}
- \adddialect\l@greek 0\fi
+ \adddialect\l@greek 0
+\fi
\ifx\l@monogreek\@undefined
- \adddialect\l@monogreek 0\fi
+ \@nopatterns{greek}
+ \adddialect\l@monogreek 0
+\fi
\ifx\l@ancientgreek\@undefined
- \adddialect\l@ancientgreek 0\fi
+ \@nopatterns{greek}
+ \adddialect\l@ancientgreek 0
+\fi
\newcount\bbl@monogreek \bbl@monogreek=\l@monogreek
\newcount\bbl@polygreek \bbl@polygreek=\l@greek
-\newcount\bbl@ancientgreek \bbl@ancientgreek=\l@ancientgreek
-\addto\extrasgreek{\let\l@greek\bbl@monogreek\relax}
+\newcount\bbl@ancientgreek \bbl@ancientgreek=\l@ancientgreek
+\addto\extrasgreek{\let\l@greek=\bbl@monogreek}
\addto\extraspolutonikogreek{\l@greek=\bbl@polygreek}
\addto\extrasancientgreek{\l@greek=\bbl@ancientgreek}
+\providehyphenmins{\CurrentOption}{\@ne\@ne}
\bbl@declare@ttribute{greek}{polutoniko}{%
\expandafter\addto\expandafter\extrasgreek
\expandafter{\extraspolutonikogreek}%
\let\captionsgreek\captionspolutonikogreek
- \let\gr@month\gr@c@month
+ \let\gr@month\gr@polutoniko@month
\let\l@polutonikogreek\l@greek
\let\datepolutonikogreek\dategreek
\let\extraspolutonikogreek\extrasgreek
\let\noextraspolutonikogreek\noextrasgreek
- }
+}
+\bbl@declare@ttribute{greek}{polytonic}{%
+ \expandafter\addto\expandafter\extrasgreek
+ \expandafter{\extraspolutonikogreek}%
+ \let\captionsgreek\captionspolutonikogreek
+ \let\gr@month\gr@polutoniko@month
+}
\bbl@declare@ttribute{greek}{ancient}{%
\expandafter\addto\expandafter\extrasgreek
\expandafter{\extraspolutonikogreek}% multi-accented letters
\expandafter\addto\expandafter\extrasgreek
\expandafter{\extrasancientgreek}%
\let\captionsgreek\captionsancientgreek
- \let\gr@month\gr@c@month % (modern) polytonic month names
- }
-\ifdefined \UnicodeEncodingName % set by LaTeX for Unicode-aware engines
+ \let\gr@month\gr@polutoniko@month % (modern) polytonic month names
+ \renewcommand{\greeknumeralninety}{\textqoppa}%
+ \renewcommand{\greeknumeralNinety}{\textQoppa}%
+}
+\ifdefined\UnicodeEncodingName % set by XeTeX/LuaTeX
\providecommand*{\greekfontencoding}{\UnicodeEncodingName}
\providecommand*{\bbl@greek@fontencdef}{tuenc-greek}
\else
\providecommand*{\greekfontencoding}{LGR}
\providecommand*{\bbl@greek@fontencdef}{lgrenc}
+ % TODO the more generic version fails :(
+ % \edef\bbl@greek@fontencdef{\lowercase{\greekfontencoding}enc}
\fi
\@ifl@aded{def}{\bbl@greek@fontencdef}{}
{% else
- \InputIfFileExists{\bbl@greek@fontencdef .def}{}{% else
+ \InputIfFileExists{\bbl@greek@fontencdef .def}{}
+ {% else
\bbl@error{Font support for the Greek script missing.\\
babel-greek can't typeset Greek.\\
Install the "greek-fontenc" package\\
@@ -90,40 +107,92 @@
\@@end
}
}
+\AtBeginDocument{%
+ \@ifl@aded{def}{puenc}%
+ {\@ifl@aded{def}{puenc-greek}
+ {}%
+ {\edef\RestoreAtCatcode{\catcode`@=\the\catcode`@\relax}%
+ \makeatletter
+ \InputIfFileExists{puenc-greek.def}%
+ {}%
+ {\bbl@warning{I cannot find the "puenc" Greek fixes
+ from "greek-fontenc".}%
+ }%
+ \RestoreAtCatcode
+ }%
+ }% end "puenc.def loaded" branch
+ {}% empty "puenc.def not loaded" branch
+}
\ProvideTextCommandDefault{\greekscript}{%
\fontencoding{\greekfontencoding}\selectfont
- \def\encodingdefault{\greekfontencoding}}
+ \def\encodingdefault{\greekfontencoding}}
\ProvideTextCommandDefault{\ensuregreek}[1]{%
- \leavevmode{\greekscript #1}}
-\AtBeginDocument{
- \@ifl@aded{def}{puenc}{
- \makeatletter % required inside \AtBeginDocument
- \InputIfFileExists{puenc-greek.def}{}{% else
- \bbl@warning{I can't find the file puenc-greek.def from "greek-fontenc".}
- }
- \makeatother
- }{}
+ \leavevmode {\greekscript #1}}
+\def\BabelGreekRestoreFontEncoding{%
+ \ifx\cf@encoding\BabelGreekPreviousFontEncoding
+ \else
+ \let\encodingdefault\BabelGreekPreviousFontEncoding
+ \fontencoding{\encodingdefault}\selectfont
+ \fi
}
+\addto\extrasgreek{%
+ \let\BabelGreekPreviousFontEncoding\cf@encoding
+ \greekscript}
+\addto\noextrasgreek{\BabelGreekRestoreFontEncoding}
\@ifl@aded{def}{lgrenc}{%
- \ProvideTextCommand{\textcopyright}{LGR}{\ensureascii{\textcopyright}}
- \ProvideTextCommand{\textregistered}{LGR}{\ensureascii{\textregistered}}
- \ProvideTextCommand{\texttrademark}{LGR}{\ensureascii{\texttrademark}}
- \let\ltx@amp\&
- \ProvideTextCommandDefault{\textampersand}{\ltx@amp}
- \ProvideTextCommand{\textampersand}{LGR}{\ensureascii{\ltx@amp}}
- \DeclareRobustCommand{\&}{\ifmmode\ltx@amp\else\textampersand\fi}
- \ProvideTextCommand{\SS}{LGR}{\ensureascii{\SS}}
- \def\@roman#1{\expandafter\ensureascii\expandafter{\romannumeral#1}}
- \def\@Roman#1{\expandafter\ensureascii\expandafter{%
- \expandafter\@slowromancap\romannumeral#1@}}
\DeclareRobustCommand{\greektext}{%
\fontencoding{LGR}\selectfont
\def\encodingdefault{LGR}}
- \DeclareRobustCommand{\textgreek}[1]{\leavevmode{\greektext #1}}
+ \DeclareTextFontCommand{\lgrfont}{\greektext}
+ \let\textgreek\lgrfont
\def\outlfamily{\usefont{LGR}{cmro}{m}{n}}
\DeclareTextFontCommand{\textol}{\outlfamily}
-}{} % End of LGR fixes.
-\providehyphenmins{\CurrentOption}{\@ne\@ne}
+ \ProvideTextCommand{\textcopyright}{LGR}{\ensureascii{\textcopyright}}
+ \ProvideTextCommand{\textregistered}{LGR}{\ensureascii{%
+ \textregistered}}
+ \ProvideTextCommand{\texttrademark}{LGR}{\ensureascii{\texttrademark}}
+ \let\bbl@greek@original@amp\&
+ \ProvideTextCommandDefault{\textampersand}{\bbl@greek@original@amp}
+ \ProvideTextCommand{\textampersand}{LGR}{%
+ \ensureascii{\bbl@greek@original@amp}}
+ \ProvideTextCommandDefault{\EnsureStandardFontEncoding}{\@firstofone}
+ \ProvideTextCommand{\EnsureStandardFontEncoding}{LGR}[1]{%
+ \ensureascii{#1}}
+ \AtBeginDocument{\@ifpackageloaded{hyperref}
+ {\pdfstringdefDisableCommands{%
+ \let\EnsureStandardFontEncoding\@firstofone}}
+ {}}
+}{}
+
+\def\bbl@tempa{LGR}
+\ifx\greekfontencoding\bbl@tempa
+ \def\bbl@greek@roman#1{\expandafter\EnsureStandardFontEncoding%
+ \expandafter{\romannumeral#1}}
+ \def\bbl@greek@Roman#1{\expandafter\EnsureStandardFontEncoding%
+ \expandafter{\expandafter\@slowromancap\romannumeral#1@}}
+ \DeclareRobustCommand{\bbl@greek@ampersand}{%
+ \ifmmode\bbl@greek@original@amp\else\textampersand\fi}
+ \bbl@xin@{,no-LGR-fixes,}{,\BabelModifiers,}%
+ \ifin@
+ % skip re-definitions
+ \else
+ \bbl@xin@{,local-LGR-fixes,}{,\BabelModifiers,}%
+ \ifin@
+ \addto\extrasgreek{%
+ \babel@save\@roman
+ \babel@save\@Roman
+ \let\@roman\bbl@greek@roman
+ \let\@Roman\bbl@greek@Roman
+ \babel@save\&%
+ \let\&\bbl@greek@ampersand%
+ }
+ \else
+ \let\@roman\bbl@greek@roman
+ \let\@Roman\bbl@greek@Roman
+ \let\&\bbl@greek@ampersand
+ \fi
+ \fi
+\fi
\addto\captionsgreek{%
\def\prefacename{\textPi\textrho\acctonos\textomicron\textlambda
\textomicron\textgamma\textomicron\textfinalsigma}%
@@ -131,8 +200,9 @@
\textphi\textomicron\textrho\acctonos\textepsilon\textfinalsigma}%
\def\abstractname{\textPi\textepsilon\textrho\acctonos\textiota
\textlambda\texteta\textpsi\texteta}%
- \def\bibname{\textBeta\textiota\textbeta\textlambda\textiota\textomicron
- \textgamma\textrho\textalpha\textphi\acctonos\textiota\textalpha}%
+ \def\bibname{\textBeta\textiota\textbeta\textlambda\textiota
+ \textomicron\textgamma\textrho\textalpha\textphi\acctonos
+ \textiota\textalpha}%
\def\chaptername{\textKappa\textepsilon\textphi\acctonos\textalpha
\textlambda\textalpha\textiota\textomicron}%
\def\appendixname{\textPi\textalpha\textrho\acctonos\textalpha\textrho
@@ -146,7 +216,8 @@
\textomega\textnu}%
\def\listtablename{\textKappa\textalpha\texttau\acctonos\textalpha
\textlambda\textomicron\textgamma\textomicron\textfinalsigma{}
- \textPi\textiota\textnu\acctonos\textalpha\textkappa\textomega\textnu}%
+ \textPi\textiota\textnu\acctonos\textalpha\textkappa\textomega
+ \textnu}%
\def\indexname{\textEpsilon\textupsilon\textrho\textepsilon
\texttau\acctonos\texteta\textrho\textiota\textomicron}%
\def\figurename{\textSigma\textchi\acctonos\texteta\textmu\textalpha}%
@@ -161,76 +232,89 @@
\def\headtoname{\textPi\textrho\textomicron\textfinalsigma}%
\def\pagename{\textSigma\textepsilon\textlambda\acctonos\textiota
\textdelta\textalpha}%
- \def\seename{\textbeta\textlambda\acctonos\textepsilon\textpi\textepsilon}%
- \def\alsoname{\textbeta\textlambda\acctonos\textepsilon\textpi\textepsilon{}
- \textepsilon\textpi\acctonos\textiota\textsigma\texteta\textfinalsigma}%
+ \def\seename{\textbeta\textlambda\acctonos\textepsilon\textpi
+ \textepsilon}%
+ \def\alsoname{\textbeta\textlambda\acctonos\textepsilon\textpi
+ \textepsilon{} \textepsilon\textpi\acctonos\textiota\textsigma
+ \texteta\textfinalsigma}%
\def\proofname{\textAlpha\textpi\acctonos\textomicron
\textdelta\textepsilon\textiota\textxi\texteta}%
\def\glossaryname{\textGamma\textlambda\textomega\textsigma
\textsigma\acctonos\textalpha\textrho\textiota}%
- }
+}
\let\captionspolutonikogreek\captionsgreek
\addto\captionspolutonikogreek{%
\def\refname{\accpsili\textAlpha\textnu\textalpha
\textphi\textomicron\textrho\accvaria\textepsilon\textfinalsigma}%
\def\indexname{\textEpsilon\accdasia\textupsilon\textrho\textepsilon
\texttau\acctonos\texteta\textrho\textiota\textomicron}%
- \def\figurename{\textSigma\textchi\accperispomeni\texteta\textmu\textalpha}%
+ \def\figurename{\textSigma\textchi\accperispomeni\texteta\textmu
+ \textalpha}%
\def\headtoname{\textPi\textrho\accvaria\textomicron\textfinalsigma}%
- \def\alsoname{\textbeta\textlambda\acctonos\textepsilon\textpi\textepsilon{}
- \accpsili\textepsilon\textpi\acctonos\textiota\textsigma\texteta\textfinalsigma}%
+ \def\alsoname{\textbeta\textlambda\acctonos\textepsilon\textpi
+ \textepsilon{} \accpsili\textepsilon\textpi\acctonos\textiota
+ \textsigma\texteta\textfinalsigma}%
\def\proofname{\accpsili\textAlpha\textpi\acctonos\textomicron
\textdelta\textepsilon\textiota\textxi\texteta}%
}
\let\captionsancientgreek\captionsgreek
\addto\captionsancientgreek{%
- \def\prefacename{\textPi\textrho\textomicron\textomicron\acctonos\textiota\textmu
- \textiota\textomicron\textnu}%
- \def\refname{\accpsili\textAlpha\textnu\textalpha\textphi\textomicron\textrho
- \textalpha\accvaria\textiota}%
- \def\abstractname{\textPi\textepsilon\textrho\acctonos\textiota\textlambda\texteta
- \textpsi\textiota\textvarsigma}%
- \def\bibname{\textBeta\textiota\textbeta\textlambda\textiota\textomicron
- \textgamma\textrho\textalpha\textphi\acctonos\textiota\textalpha}%
- \def\chaptername{\textKappa\textepsilon\textphi\acctonos\textalpha\textlambda
- \textalpha\textiota\textomicron\textnu}%
- \def\appendixname{\textPi\textalpha\textrho\acctonos\textalpha\textrho\texttau
- \texteta\textmu\textalpha}%
- \def\contentsname{\textPi\textepsilon\textrho\textiota\textepsilon\textchi
- \acctonos\textomicron\textmu\textepsilon\textnu\textalpha}%
- \def\listfigurename{\textKappa\textalpha\texttau\acctonos\textalpha\textlambda
- \textomicron\textgamma\textomicron\textvarsigma{}
- \textsigma\textchi\texteta\textmu\acctonos\textalpha\texttau\textomega\textnu}%
- \def\listtablename{\textKappa\textalpha\texttau\acctonos\textalpha\textlambda
- \textomicron\textgamma\textomicron\textvarsigma{}
- \textpi\textiota\textnu\acctonos\textalpha\textkappa\textomega\textnu}%
- \def\indexname{\textEpsilon\accdasia\textupsilon\textrho\textepsilon\texttau
- \acctonos\texteta\textrho\textiota\textomicron\textnu}%
- \def\figurename{\textSigma\textchi\accperispomeni\texteta\textmu\textalpha}%
+ \def\prefacename{\textPi\textrho\textomicron\textomicron
+ \acctonos\textiota\textmu\textiota\textomicron\textnu}%
+ \def\refname{\accpsili\textAlpha\textnu\textalpha\textphi\textomicron
+ \textrho\textalpha\accvaria\textiota}%
+ \def\abstractname{\textPi\textepsilon\textrho\acctonos\textiota
+ \textlambda\texteta\textpsi\textiota\textvarsigma}%
+ \def\bibname{\textBeta\textiota\textbeta\textlambda\textiota
+ \textomicron\textgamma\textrho\textalpha\textphi
+ \acctonos\textiota\textalpha}%
+ \def\chaptername{\textKappa\textepsilon\textphi\acctonos\textalpha
+ \textlambda\textalpha\textiota\textomicron\textnu}%
+ \def\appendixname{\textPi\textalpha\textrho\acctonos\textalpha
+ \textrho\texttau\texteta\textmu\textalpha}%
+ \def\contentsname{\textPi\textepsilon\textrho\textiota\textepsilon
+ \textchi\acctonos\textomicron\textmu\textepsilon\textnu\textalpha}%
+ \def\listfigurename{\textKappa\textalpha\texttau\acctonos\textalpha
+ \textlambda\textomicron\textgamma\textomicron\textvarsigma{}
+ \textsigma\textchi\texteta\textmu\acctonos\textalpha\texttau
+ \textomega\textnu}%
+ \def\listtablename{\textKappa\textalpha\texttau\acctonos\textalpha
+ \textlambda\textomicron\textgamma\textomicron\textvarsigma{}
+ \textpi\textiota\textnu\acctonos\textalpha\textkappa
+ \textomega\textnu}%
+ \def\indexname{\textEpsilon\accdasia\textupsilon\textrho\textepsilon
+ \texttau\acctonos\texteta\textrho\textiota\textomicron\textnu}%
+ \def\figurename{\textSigma\textchi\accperispomeni\texteta\textmu
+ \textalpha}%
\def\tablename{\textPi\acctonos\textiota\textnu\textalpha\textxi}%
- \def\partname{\textMu\acctonos\textepsilon\textrho\textomicron\textvarsigma}%
+ \def\partname{\textMu\acctonos\textepsilon\textrho\textomicron
+ \textvarsigma}%
\def\enclname{\textSigma\textupsilon\textnu\texteta\textmu\textmu
\acctonos\textepsilon\textnu\textomega\textvarsigma}%
\def\ccname{\textKappa\textomicron\textiota\textnu\textomicron\textpi
- \textomicron\acctonos\textiota\texteta\textsigma\textiota\textvarsigma}%
+ \textomicron\acctonos\textiota\texteta\textsigma\textiota
+ \textvarsigma}%
\def\headtoname{\textPi\textrho\accvaria\textomicron\textvarsigma}%
- \def\pagename{\textSigma\textepsilon\textlambda\accvaria\textiota\textvarsigma}%
+ \def\pagename{\textSigma\textepsilon\textlambda\accvaria\textiota
+ \textvarsigma}%
\def\seename{\accdasiaoxia\textomicron\textrho\textalpha}%
- \def\alsoname{\accdasiaoxia\textomicron\textrho\textalpha{} \accdasia\textomega\textsigma
- \textalpha\acctonos\textupsilon\texttau\textomega\textvarsigma}%
- \def\proofname{\accpsili\textAlpha\textpi\acctonos\textomicron\textdelta\textepsilon
- \textiota\textxi\textiota\textvarsigma}%
+ \def\alsoname{\accdasiaoxia\textomicron\textrho\textalpha{}
+ \accdasia\textomega\textsigma\textalpha\acctonos\textupsilon
+ \texttau\textomega\textvarsigma}%
+ \def\proofname{\accpsili\textAlpha\textpi\acctonos\textomicron
+ \textdelta\textepsilon\textiota\textxi\textiota\textvarsigma}%
\def\glossaryname{\textGamma\textlambda\textomega\textsigma\textsigma
\acctonos\textalpha\textrho\textiota\textomicron\textnu}%
- }
+}
\def\gr@month{%
\ifcase\month\or
\textIota\textalpha\textnu\textomicron\textupsilon\textalpha
\textrho\acctonos\textiota\textomicron\textupsilon \or
\textPhi\textepsilon\textbeta\textrho\textomicron\textupsilon
\textalpha\textrho\acctonos\textiota\textomicron\textupsilon \or
- \textMu\textalpha\textrho\texttau\acctonos\textiota\textomicron\textupsilon
- \or \textAlpha\textpi\textrho\textiota\textlambda\acctonos\textiota
+ \textMu\textalpha\textrho\texttau\acctonos\textiota\textomicron
+ \textupsilon \or
+ \textAlpha\textpi\textrho\textiota\textlambda\acctonos\textiota
\textomicron\textupsilon \or
\textMu\textalpha\'"\textiota\textomicron\textupsilon \or
\textIota\textomicron\textupsilon\textnu\acctonos\textiota
@@ -249,19 +333,18 @@
\textrho\acctonos\textiota\textomicron\textupsilon
\fi
}
-\def\dategreek{%
- \def\today{\number\day \space \gr@month\space \number\year}}
-\def\gr@c@month{%
+\def\gr@polutoniko@month{%
\ifcase\month\or
- \accpsili\textIota\textalpha\textnu\textomicron\textupsilon\textalpha
- \textrho\acctonos\textiota\textomicron\textupsilon \or
+ \accpsili\textIota\textalpha\textnu\textomicron\textupsilon
+ \textalpha\textrho\acctonos\textiota\textomicron\textupsilon \or
\textPhi\textepsilon\textbeta\textrho\textomicron\textupsilon
\textalpha\textrho\acctonos\textiota\textomicron\textupsilon \or
\textMu\textalpha\textrho\texttau\acctonos\textiota\textomicron
\textupsilon \or
\accpsili\textAlpha\textpi\textrho\textiota\textlambda
\acctonos\textiota\textomicron\textupsilon \or
- \textMu\textalpha\"'\textiota\textomicron\textupsilon \or
+ \textMu\textalpha\accdialytikatonos\textiota\textomicron
+ \textupsilon \or
\accpsili\textIota\textomicron\textupsilon\textnu
\acctonos\textiota\textomicron\textupsilon \or
\accpsili\textIota\textomicron\textupsilon\textlambda
@@ -278,19 +361,23 @@
\textbeta\textrho\acctonos\textiota\textomicron\textupsilon
\fi
}
+\def\dategreek{%
+ \def\today{\number\day \space \gr@month\space \number\year}}
\def\Grtoday{%
\expandafter\Greeknumeral\expandafter{\the\day}\space
- \gr@c@month \space
+ \gr@polutoniko@month \space
\expandafter\Greeknumeral\expandafter{\the\year}}
-\addto\extrasgreek{\greekscript}
-\addto\noextrasgreek{\latintext}
+\providecommand*{\greeknumeralsix}{\textstigma}
+\providecommand*{\greeknumeralSix}{\textStigma}
+\providecommand*{\greeknumeralninety}{\textkoppa}
+\providecommand*{\greeknumeralNinety}{\textKoppa}
\def\greeknumeral#1{%
{\greekscript
- \bbl@greek@GreekNum\@firstoftwo{#1}}%
+ \bbl@greek@GreekNum\@firstoftwo{#1}}%
}
\def\Greeknumeral#1{%
{\greekscript
- \bbl@greek@GreekNum\@secondoftwo{#1}}%
+ \bbl@greek@GreekNum\@secondoftwo{#1}}%
}
\def\bbl@greek@ill@value#1{%
\PackageWarningNoLine{babel}{Illegal value (#1) for greeknumeral}%
@@ -350,7 +437,7 @@
\or\textgamma\textGamma
\or\textdelta\textDelta
\or\textepsilon\textEpsilon
- \or\textstigmagreek\textStigmagreek
+ \or\greeknumeralsix\greeknumeralSix % stigma or digamma
\or\textzeta\textZeta
\or\texteta\textEta
\or\texttheta\textTheta
@@ -375,7 +462,7 @@
\or\textxi\textXi
\or\textomicron\textOmicron
\or\textpi\textPi
- \or\textkoppa\textKoppa
+ \or\greeknumeralninety\greeknumeralNinety % koppa or qoppa
\else
{}{}%
\fi
@@ -416,27 +503,30 @@
\bbl@greek@GreekNumIII\@firstofone#1#2#3#4%
\bbl@greek@@GreekNum#1{#5#6#7}%
}
-\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{%
+ \babel@save\@alph
+ \babel@save\@Alph
\let\@alph\greek@alph
- \let\@Alph\greek@Alph}
-\addto\noextrasgreek{%
- \let\@alph\latin@alph
- \let\@Alph\latin@Alph}
-\@ifl@aded{def}{lgrenc}{%
- \begingroup
- \@ifundefined{active@char\string!}{}{\catcode`!=12\relax}
- \catcode`\~=12%
- \lccode`\!=`\~%
- \lowercase{\def\x{\endgroup
- \def\greek@tilde{!}}\x}
+ \let\@Alph\greek@Alph
+}
+\def\bbl@tempa{LGR}
+\ifx\greekfontencoding\bbl@tempa
\addto\extrasgreek{%
\babel@savevariable{\lccode`v}\lccode`v=`v%
\babel@savevariable{\lccode`\'}\lccode`\'=`\'%
\babel@savevariable{\lccode`\"}\lccode`\"=`\"%
+ }
+ \addto\extraspolutonikogreek{%
+ % \l@greek=\bbl@polygreek
+ \babel@savevariable{\lccode`\<}\lccode`\<=`\<%
+ \babel@savevariable{\lccode`\>}\lccode`\>=`\>%
+ \babel@savevariable{\lccode`\~}\lccode`\~=`\~%
+ \babel@savevariable{\lccode`\|}\lccode`\|=`\|%
+ \babel@savevariable{\lccode`\`}\lccode`\`=`\`%
+ }
+ \addto\extrasgreek{%
% ``high bit characters'': set in a loop and correct exceptions
\@tempcnta=128%
\@whilenum\@tempcnta<253\do{%
@@ -455,38 +545,44 @@
\lccode219=240% GREEK CAPITAL LETTER IOTA WITH DIALYTIKA
\lccode223=244% GREEK CAPITAL LETTER UPSILON WITH DIALYTIKA
}
-
- \addto\extraspolutonikogreek{%
- % \l@greek=\bbl@polygreek
- \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
- \DeclareTextCompositeCommand{\"}{LGR}{^^9f}{\accdialytika}
- \DeclareTextCompositeCommand{\'}{LGR}{^^9f}{\LGR@hiatus}
- \DeclareTextCompositeCommand{\`}{LGR}{^^9f}{\LGR@hiatus}
- \addto\extraspolutonikogreek{\languageshorthands{greek}}%
+ % fallback for for LaTeX versions older than 2020-10-01
+ \providecommand\IfFormatAtLeastTF{\@ifl@t@r\fmtversion}
+ \IfFormatAtLeastTF{2022/06/01}%
+ {}
+ {% else
+ \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%
+ }
+ \bgroup
+ \uccode`\~159%
+ \uppercase{%
+ \egroup
+ \def~{}%
+ }
+ \DeclareTextCompositeCommand{\"}{LGR}{^^9f}{\accdialytika}
+ \DeclareTextCompositeCommand{\'}{LGR}{^^9f}{\LGR@hiatus}
+ \DeclareTextCompositeCommand{\`}{LGR}{^^9f}{\LGR@accdropped}
+ \ifdefined\UnicodeEncodingName % set by XeTeX/LuaTeX
+ \DeclareTextCompositeCommand{\"}{TU}{^^9f}{\accdialytika}
+ \fi
+ }% end of the \IfFormatAtLeastTF else block
+ \begingroup
+ \@ifundefined{active@char\string!}{}{\catcode`!=12\relax}
+ \catcode`\~=12%
+ \lccode`\!=`\~%
+ \lowercase{\def\x{\endgroup
+ \def\greek@tilde{!}}\x}
+ \addto\extraspolutonikogreek{\languageshorthands{greek}}
\declare@shorthand{greek}{~}{\greek@tilde}
-}{} % End of LGR-specific code.
+\fi % End of LGR-specific code.
\providecommand*{\anwtonos}{\textdexiakeraia}
\providecommand*{\katwtonos}{\textaristerikeraia}
\providecommand*{\qoppa}{\textkoppa}
@@ -498,10 +594,6 @@
\providecommand*{\vardigamma}{\textvardigamma}
\providecommand*{\euro}{\texteuro}
\providecommand*{\permill}{\textperthousand}
-\@ifl@aded{def}{lgrenc}{%
- \ProvideTextCommand{\textKoppa}{LGR}{\textkoppa}
- \ProvideTextCommand{\textmugreek}{LGR}{\textmu}
-}{}
\ProvideTextCommand{\textmugreek}{\greekfontencoding}{\textmu}
\ldf@finish{\CurrentOption}
%% \CharacterTable