summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/babel-greek
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/generic/babel-greek')
-rw-r--r--Master/texmf-dist/tex/generic/babel-greek/greek.ldf92
1 files changed, 46 insertions, 46 deletions
diff --git a/Master/texmf-dist/tex/generic/babel-greek/greek.ldf b/Master/texmf-dist/tex/generic/babel-greek/greek.ldf
index bec7438e570..6331e5b6f43 100644
--- a/Master/texmf-dist/tex/generic/babel-greek/greek.ldf
+++ b/Master/texmf-dist/tex/generic/babel-greek/greek.ldf
@@ -32,7 +32,7 @@
%% and covered by LPPL is defined by the unpacking script (babel-greek.ins)
%% which is part of the package.
\ProvidesLanguage{greek}
- [2023/08/18 1.14 Greek support for the babel system]
+ [2023/10/13 1.15 Greek support for the babel system]
%% File `babel-greek.dtx'
%% Greek language Definition File
%% Copyright © 1997, 2005 Apostolos Syropoulos, Johannes Braams
@@ -41,6 +41,7 @@
\LdfInit\CurrentOption{captions\CurrentOption}
\gdef\CurrentOption{greek}
\addto\extrasgreek{\languageshorthands{greek}}
+\def\bbl@greek@LGR{LGR}
\ifx\l@greek\@undefined
\@nopatterns{greek}
\adddialect\l@greek 0
@@ -85,8 +86,7 @@
\renewcommand{\greeknumeralNinety}{\textQoppa}%
}
\bbl@declare@ttribute{greek}{keep-semicolon}{%
- \def\bbl@tempa{LGR}
- \ifx\greekfontencoding\bbl@tempa
+ \ifx\greekfontencoding\bbl@greek@LGR
\ProvideTextCommandDefault{\textsemicolon}{;}
\ProvideTextCommand{\textsemicolon}{LGR}{\texterotimatiko}
\initiate@active@char{;}
@@ -97,7 +97,7 @@
}
\def\bbl@greek@modifiers{,%
polutoniko,polytonic,ancient,keep-semicolon,%
- local-LGR-fixes,no-LGR-fixes,local-MakeUppercase-fixes,}
+ local-LGR-fixes,no-LGR-fixes,no-MakeUppercase-fixes,}
\ifx\BabelModifiers\relax\else
\bbl@foreach\BabelModifiers{%
\@expandtwoargs\in@{,#1,}{\bbl@greek@modifiers}
@@ -114,22 +114,20 @@
\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
- \bbl@error{Font support for the Greek script missing.\\
- babel-greek can't typeset Greek.\\
- Install the "greek-fontenc" package\\
- or use XeTeX/LuaTeX with polyglossia.}
- {I can't find the \bbl@greek@fontencdef .def file
- for the Greek fonts (encoding \greekfontencoding)}
- \@@end
+\@ifl@aded{def}{\bbl@greek@fontencdef}
+ {}
+ {\InputIfFileExists{\bbl@greek@fontencdef .def}
+ {}
+ {\bbl@error{Font support for the Greek script missing.\\
+ babel-greek can't typeset Greek.\\
+ Install the "greek-fontenc" package\\
+ or use XeTeX/LuaTeX with polyglossia.}
+ {I can't find the \bbl@greek@fontencdef .def file
+ for the Greek fonts (encoding \greekfontencoding)}
+ \@@end
+ }
}
-}
\AtBeginDocument{%
\@ifl@aded{def}{puenc}%
{\@ifl@aded{def}{puenc-greek}
@@ -138,30 +136,35 @@
\makeatletter
\InputIfFileExists{puenc-greek.def}%
{}%
- {\bbl@warning{I cannot find the "puenc" Greek fixes
- from "greek-fontenc".}%
+ {\bbl@warning{I cannot find the Greek fixes for PDF strings
+ ("punec-greek.def" from "greek-fontenc").}%
}%
\RestoreAtCatcode
}%
}% end "puenc.def loaded" branch
{}% empty "puenc.def not loaded" branch
}
+\addto\extrasgreek{%
+ \let\BabelGreekPreviousFontEncoding\encodingdefault
+ \greekscript}
+\addto\noextrasgreek{\BabelGreekRestoreFontEncoding}
\ProvideTextCommandDefault{\greekscript}{%
\fontencoding{\greekfontencoding}\selectfont
\def\encodingdefault{\greekfontencoding}}
\ProvideTextCommandDefault{\ensuregreek}[1]{%
\leavevmode {\greekscript #1}}
\def\BabelGreekRestoreFontEncoding{%
- \ifx\cf@encoding\BabelGreekPreviousFontEncoding
+ \ifx\encodingdefault\BabelGreekPreviousFontEncoding
\else
\let\encodingdefault\BabelGreekPreviousFontEncoding
\fontencoding{\encodingdefault}\selectfont
\fi
}
-\addto\extrasgreek{%
- \let\BabelGreekPreviousFontEncoding\cf@encoding
- \greekscript}
-\addto\noextrasgreek{\BabelGreekRestoreFontEncoding}
+\AtBeginDocument{
+ \ifx\BabelGreekPreviousFontEncoding\bbl@greek@LGR
+ \let\BabelGreekPreviousFontEncoding\latinencoding
+ \fi
+}
\@ifl@aded{def}{lgrenc}{%
\DeclareRobustCommand{\greektext}{%
\fontencoding{LGR}\selectfont
@@ -180,15 +183,18 @@
\ensureascii{\bbl@greek@original@amp}}
\ProvideTextCommandDefault{\EnsureStandardFontEncoding}{\@firstofone}
\ProvideTextCommand{\EnsureStandardFontEncoding}{LGR}[1]{%
- \ensureascii{#1}}
- \AtBeginDocument{\@ifpackageloaded{hyperref}
- {\pdfstringdefDisableCommands{%
- \let\EnsureStandardFontEncoding\@firstofone}}
- {}}
+ \ensureascii{#1}
+ }
+ \AtBeginDocument{%
+ \@ifpackageloaded{hyperref}
+ {\pdfstringdefDisableCommands{%
+ \let\EnsureStandardFontEncoding\@firstofone}
+ }
+ {}
+ }
}{}
-\def\bbl@tempa{LGR}
-\ifx\greekfontencoding\bbl@tempa
+\ifx\greekfontencoding\bbl@greek@LGR
\def\bbl@greek@roman#1{\expandafter\EnsureStandardFontEncoding%
\expandafter{\romannumeral#1}}
\def\bbl@greek@Roman#1{\expandafter\EnsureStandardFontEncoding%
@@ -534,8 +540,7 @@
\let\@alph\greek@alph
\let\@Alph\greek@Alph
}
-\def\bbl@tempa{LGR}
-\ifx\greekfontencoding\bbl@tempa
+\ifx\greekfontencoding\bbl@greek@LGR
\addto\extrasgreek{%
\babel@savevariable{\lccode`v}\lccode`v=`v%
\babel@savevariable{\lccode`\'}\lccode`\'=`\'%
@@ -573,21 +578,16 @@
\declare@shorthand{greek}{~}{\bbl@greek@tilde}
}
\fi % End of LGR-specific code.
-\providecommand\IfFormatAtLeastTF{\@ifl@t@r\fmtversion} % new in 2020
-\bbl@xin@{,local-MakeUppercase-fixes,}{,\BabelModifiers,}%
+\bbl@xin@{,no-MakeUppercase-fixes,}{,\BabelModifiers,}%
\ifin@
\else
- \IfFormatAtLeastTF{2022/06/01}
- {\ProvideTextCommandDefault{\accACUTE}{\@tabacckludge'}
- \ProvideTextCommandDefault{\accGRAVE}{\@tabacckludge`}
- \ProvideTextCommandDefault{\accTILDE}{\@tabacckludge~}
- \ProvideTextCommandDefault{\accDIAERESIS}{\@tabacckludge"}
- \addto\@uclclist{\'\accACUTE \`\accGRAVE \~\accTILDE \"\accDIAERESIS}%
- }
- {}
+ \ProvideTextCommandDefault{\accACUTE}{\@tabacckludge'}
+ \ProvideTextCommandDefault{\accGRAVE}{\@tabacckludge`}
+ \ProvideTextCommandDefault{\accTILDE}{\@tabacckludge~}
+ \ProvideTextCommandDefault{\accDIAERESIS}{\@tabacckludge"}
+ \addto\@uclclist{\'\accACUTE \`\accGRAVE \~\accTILDE \"\accDIAERESIS}%
\fi
-\def\bbl@tempa{LGR}
-\ifx\greekfontencoding\bbl@tempa
+\ifx\greekfontencoding\bbl@greek@LGR
\ifdefined\DeclareUppercaseMapping % new in 2023
% \DeclareUppercaseMapping[el]{"1FBE}{\prosgegrammeni}%
\DeclareUppercaseMapping[el]{"0027}{}% '