[latex3-commits] [git/LaTeX3-latex3-babel] main: \babelprovide - improved when called several times. (1ac3e22)
Javier
email at dante.de
Sun Jun 27 17:20:20 CEST 2021
Repository : https://github.com/latex3/babel
On branch : main
Link : https://github.com/latex3/babel/commit/1ac3e22e18723c4c57ec1c9180f72dd09463bc6f
>---------------------------------------------------------------
commit 1ac3e22e18723c4c57ec1c9180f72dd09463bc6f
Author: Javier <email at localhost>
Date: Sun Jun 27 17:20:20 2021 +0200
\babelprovide - improved when called several times.
>---------------------------------------------------------------
1ac3e22e18723c4c57ec1c9180f72dd09463bc6f
README.md | 11 +-
babel.dtx | 282 +++++++++++++++++++++++++++++++------------------
babel.ins | 2 +-
babel.pdf | Bin 843933 -> 846853 bytes
bbcompat.dtx | 2 +-
locale/ar/babel-ar.ini | 3 +-
6 files changed, 189 insertions(+), 111 deletions(-)
diff --git a/README.md b/README.md
index 615c8a1..1b6c10b 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,4 @@
-## Babel 3.60.2404
+## Babel 3.60.2416
This package manages culturally-determined typographical (and other)
rules, and hyphenation patterns for a wide range of languages. Many
@@ -8,9 +8,9 @@ is a set of ini files for about 250 languages.
The latest stable version is available on <https://ctan.org/pkg/babel>.
-Changes in version 3.60 are described in:
+Changes in version 3.61 are described in:
-https://github.com/latex3/babel/blob/master/news-guides/news/whats-new-in-babel-3.60.md
+https://latex3.github.io/babel/news/whats-new-in-babel-3.61.html
Apart from the manual, you can find information on some aspects of babel at:
@@ -46,9 +46,11 @@ respective authors.
### Summary of Latest changes
```
-3.61 2021-06-??
+3.61 2021-06-29??
* Improved justification=kashida/elongated: hboxes (lua).
* Transform danda.nobreak for several Indic scripts (lua).
+ * Improved \babelprovide when used to reconfigure a language.
+ * Partial fix for #114.
3.60 2021-06-02
* A major fix for a bug with the latest LaTeX releases: class
@@ -61,4 +63,3 @@ respective authors.
### Previous changes
See https://github.com/latex3/babel/blob/master/news-guides/README.md#whats-new
-
diff --git a/babel.dtx b/babel.dtx
index 91d229b..9bcfce6 100644
--- a/babel.dtx
+++ b/babel.dtx
@@ -6,6 +6,7 @@
%% any individual authors listed elsewhere in this file.
%% All rights reserved.
%%
+%%
%% This file is part of the Babel system.
%% --------------------------------------
%%
@@ -20,7 +21,6 @@
%% This work has the LPPL maintenance status "maintained".
%%
%% The Current Maintainer of this work is Javier Bezos.
-
%%
%% The list of derived (unpacked) files belonging to the distribution
%% and covered by LPPL is defined by the unpacking scripts (with
@@ -32,7 +32,7 @@
%
% \iffalse
%<*filedriver>
-\ProvidesFile{babel.dtx}[2021/06/15 v3.60.2404 The Babel package]
+\ProvidesFile{babel.dtx}[2021/06/27 v3.60.2416 The Babel package]
\documentclass{ltxdoc}
\GetFileInfo{babel.dtx}
\usepackage{fontspec}
@@ -710,7 +710,8 @@ the surrounding language is still in force), and (3) it works even if
the language has not been set as package option (but in such a case it
only sets the hyphenation patterns and a warning is shown). With the
|bidi| option, it also enters in horizontal mode (this is not done
-always for backwards compatibility).
+always for backwards compatibility), and since it is meant for phrases
+only the text direction (and not the paragraph one) is set.
\New{3.44} As already said, captions and dates are not switched.
However, with the optional argument you can switch them, too. So, you
@@ -4972,8 +4973,8 @@ help from Bernd Raichle, for which I am grateful.
% \section{Tools}
%
% \begin{macrocode}
-%<<version=3.60.2404>>
-%<<date=2021/06/15>>
+%<<version=3.60.2416>>
+%<<date=2021/06/27>>
% \end{macrocode}
%
% \textbf{Do not use the following macros in \texttt{ldf} files. They
@@ -5290,6 +5291,23 @@ help from Bernd Raichle, for which I am grateful.
\else
\expandafter\@firstofone
\fi}
+% \end{macrocode}
+%
+% The following adds some code to |\extras...| both before and after,
+% while avoiding doing it twice. It's somewhat convoluted, to deal with
+% |#|'s.
+%
+% \begin{macrocode}
+\def\bbl at extras@wrap#1#2#3{% 1:in-test, 2:before, 3:after
+ \toks@\expandafter\expandafter\expandafter{%
+ \csname extras\languagename\endcsname}%
+ \bbl at exp{\\\in@{#1}{\the\toks@}}%
+ \ifin@\else
+ \@temptokena{#2}%
+ \edef\bbl at tempc{\the\@temptokena\the\toks@}%
+ \toks@\expandafter{\bbl at tempc#3}%
+ \expandafter\edef\csname extras\languagename\endcsname{\the\toks@}%
+ \fi}
%<</Basic macros>>
% \end{macrocode}
%
@@ -7500,6 +7518,13 @@ help from Bernd Raichle, for which I am grateful.
% We also write a command to change the current language in the
% auxiliary files.
%
+% |\bbl at savelastskip| is used to deal with skips before the write
+% whatsit (as suggested by U Fischer). Adapted from \textsf{hyperref},
+% but it might fail, so I'll consider it a temporary hack, while I
+% study other options (the ideal, but very likely unfeasible except
+% perhaps in \luatex, is to avoid the |\write| altogether when not
+% needed).
+%
% \begin{macrocode}
\def\BabelContentsFiles{toc,lof,lot}
\def\bbl at set@language#1{% from selectlanguage, pop@
@@ -7517,9 +7542,6 @@ help from Bernd Raichle, for which I am grateful.
macro containing the actual locale, make\\%
sure it does not not match any language.\\%
Reported}%
-% I'll\\%
-% try to fix '\string\localename', but I cannot promise\\%
-% anything. Reported}%
\ifx\scantokens\@undefined
\def\localename{??}%
\else
@@ -7535,16 +7557,15 @@ help from Bernd Raichle, for which I am grateful.
\expandafter\ifx\csname date\languagename\endcsname\relax\else
\if at filesw
\ifx\babel at aux\@gobbletwo\else % Set if single in the first, redundant
- % \bbl at savelastskip
+ \bbl at savelastskip
\protected at write\@auxout{}{\string\babel at aux{\bbl at auxname}{}}%
- % \bbl at restorelastskip
+ \bbl at restorelastskip
\fi
\bbl at usehooks{write}{}%
\fi
\fi}
-% The following is used above to deal with skips before the write
-% whatsit. Adapted from hyperref, but it might fail, so for the moment
-% it's not activated. TODO.
+%
+\let\bbl at restorelastskip\relax
\def\bbl at savelastskip{%
\let\bbl at restorelastskip\relax
\ifvmode
@@ -7557,6 +7578,7 @@ help from Bernd Raichle, for which I am grateful.
\\\nobreak \vskip-\skip@ \vskip\skip@}}%
\fi
\fi}
+%
\newif\ifbbl at bcpallowed
\bbl at bcpallowedfalse
\def\select at language#1{% from set@, babel at aux
@@ -9626,6 +9648,29 @@ help from Bernd Raichle, for which I am grateful.
\bbl at elt{\string.}\@m{3000}\bbl at elt{\string?}\@m{3000}%
\bbl at elt{\string!}\@m{3000}\bbl at elt{\string:}\@m{2000}%
\bbl at elt{\string;}\@m{1500}\bbl at elt{\string,}\@m{1250}}
+\def\bbl at pre@fs{%
+ \def\bbl at elt##1##2##3{\sfcode`##1=\the\sfcode`##1\relax}%
+ \edef\bbl at save@sfcodes{\bbl at fs@chars}}%
+\def\bbl at post@fs{%
+ \bbl at save@sfcodes
+ \edef\bbl at tempa{\bbl at cl{frspc}}%
+ \edef\bbl at tempa{\expandafter\@car\bbl at tempa\@nil}%
+ \if u\bbl at tempa % do nothing
+ \else\if n\bbl at tempa % non french
+ \def\bbl at elt##1##2##3{%
+ \ifnum\sfcode`##1=##2\relax
+ \babel at savevariable{\sfcode`##1}%
+ \sfcode`##1=##3\relax
+ \fi}%
+ \bbl at fs@chars
+ \else\if y\bbl at tempa % french
+ \def\bbl at elt##1##2##3{%
+ \ifnum\sfcode`##1=##3\relax
+ \babel at savevariable{\sfcode`##1}%
+ \sfcode`##1=##2\relax
+ \fi}%
+ \bbl at fs@chars
+ \fi\fi\fi}
% \end{macrocode}
%
% \end{macro}
@@ -10801,13 +10846,14 @@ help from Bernd Raichle, for which I am grateful.
%
% \begin{macrocode}
\bbl at trace{Creating languages and reading ini files}
+\let\bbl at extend@ini\@gobble
\newcommand\babelprovide[2][]{%
\let\bbl at savelangname\languagename
\edef\bbl at savelocaleid{\the\localeid}%
% Set name and locale id
\edef\languagename{#2}%
- % \global\@namedef{bbl at lcname@#2}{#2}%
\bbl at id@assign
+ % Initialize keys
\let\bbl at KVP@captions\@nil
\let\bbl at KVP@date\@nil
\let\bbl at KVP@import\@nil
@@ -10830,27 +10876,34 @@ help from Bernd Raichle, for which I am grateful.
\let\bbl at KVP@labels\@nil
\bbl at csarg\let{KVP at labels*}\@nil
\global\let\bbl at inidata\@empty
+ \global\let\bbl at extend@ini\@gobble
+ \gdef\bbl at key@list{;}%
\bbl at forkv{#1}{% TODO - error handling
\in@{/}{##1}%
\ifin@
+ \global\let\bbl at extend@ini\bbl at extend@ini at aux
\bbl at renewinikey##1\@@{##2}%
\else
\bbl at csarg\def{KVP@##1}{##2}%
\fi}%
+ \chardef\bbl at howloaded=% 0:none; 1:ldf without ini; 2:ini
+ \bbl at ifunset{date#2}\z@{\bbl at ifunset{bbl at llevel@#2}\@ne\tw@}%
% == init ==
\ifx\bbl at screset\@undefined
\bbl at ldfinit
\fi
% ==
\let\bbl at lbkflag\relax % \@empty = do setup linebreak
- \bbl at ifunset{date#2}%
- {\let\bbl at lbkflag\@empty}% new
- {\ifx\bbl at KVP@hyphenrules\@nil\else
- \let\bbl at lbkflag\@empty
- \fi
- \ifx\bbl at KVP@import\@nil\else
+ \ifcase\bbl at howloaded
+ \let\bbl at lbkflag\@empty % new
+ \else
+ \ifx\bbl at KVP@hyphenrules\@nil\else
\let\bbl at lbkflag\@empty
- \fi}%
+ \fi
+ \ifx\bbl at KVP@import\@nil\else
+ \let\bbl at lbkflag\@empty
+ \fi
+ \fi
% == import, captions ==
\ifx\bbl at KVP@import\@nil\else
\bbl at exp{\\\bbl at ifblank{\bbl at KVP@import}}%
@@ -10872,13 +10925,19 @@ help from Bernd Raichle, for which I am grateful.
\bbl at replace\bbl at KVP@transforms{ }{,}%
\fi
% Load ini
- \bbl at ifunset{date#2}%
- {\bbl at provide@new{#2}}%
- {\bbl at ifblank{#1}%
+ \ifcase\bbl at howloaded
+ \bbl at provide@new{#2}%
+ \else
+ \bbl at ifblank{#1}%
{}% With \bbl at load@basic below
- {\bbl at provide@renew{#2}}}%
+ {\bbl at provide@renew{#2}}%
+ \fi
% Post tasks
% ----------
+ % == subsequent calls after the first provide for a locale ==
+ \ifx\bbl at inidata\@empty\else
+ \bbl at extend@ini{#2}%
+ \fi
% == ensure captions ==
\ifx\bbl at KVP@captions\@nil\else
\bbl at ifunset{bbl at extracaps@#2}%
@@ -10997,7 +11056,7 @@ help from Bernd Raichle, for which I am grateful.
\bbl at csarg\edef{intsp@#2}{\bbl at KVP@intraspace}%
\fi
\bbl at provide@intraspace
- %
+ % == Line breaking: justification ==
\ifx\bbl at KVP@justification\@nil\else
\let\bbl at KVP@linebreaking\bbl at KVP@justification
\fi
@@ -11011,7 +11070,7 @@ help from Bernd Raichle, for which I am grateful.
\bbl at xin@{/e}{/\bbl at cl{lnbrk}}%
\ifin@\else\bbl at xin@{/k}{/\bbl at cl{lnbrk}}\fi
\ifin@\bbl at arabicjust\fi
- % == Line breaking: hyphenate.other.locale/.script==
+ % == Line breaking: hyphenate.other.(locale|script) ==
\ifx\bbl at lbkflag\@empty
\bbl at ifunset{bbl at hyotl@\languagename}{}%
{\bbl at csarg\bbl at replace{hyotl@\languagename}{ }{,}%
@@ -11096,25 +11155,21 @@ help from Bernd Raichle, for which I am grateful.
% restored correctly when exiting the language, so we ignore
% this change with the \bbl at alph@saved trick.
\ifx\bbl at KVP@alph\@nil\else
- \toks@\expandafter\expandafter\expandafter{%
- \csname extras\languagename\endcsname}%
+ \bbl at extras@wrap{\\\bbl at alph@saved}%
+ {\let\bbl at alph@saved\@alph}%
+ {\let\@alph\bbl at alph@saved
+ \babel at save\@alph}%
\bbl at exp{%
- \def\<extras\languagename>{%
- \let\\\bbl at alph@saved\\\@alph
- \the\toks@
- \let\\\@alph\\\bbl at alph@saved
- \\\babel at save\\\@alph
+ \\\bbl at add\<extras\languagename>{%
\let\\\@alph\<bbl at cntr@\bbl at KVP@alph @\languagename>}}%
\fi
\ifx\bbl at KVP@Alph\@nil\else
- \toks@\expandafter\expandafter\expandafter{%
- \csname extras\languagename\endcsname}%
+ \bbl at extras@wrap{\\\bbl at Alph@saved}%
+ {\let\bbl at Alph@saved\@Alph}%
+ {\let\@Alph\bbl at Alph@saved
+ \babel at save\@Alph}%
\bbl at exp{%
- \def\<extras\languagename>{%
- \let\\\bbl at Alph@saved\\\@Alph
- \the\toks@
- \let\\\@Alph\\\bbl at Alph@saved
- \\\babel at save\\\@Alph
+ \\\bbl at add\<extras\languagename>{%
\let\\\@Alph\<bbl at cntr@\bbl at KVP@Alph @\languagename>}}%
\fi
% == require.babel in ini ==
@@ -11128,8 +11183,17 @@ help from Bernd Raichle, for which I am grateful.
\bbl at input@texini{\bbl at cs{rqtex@\languagename}}%
\catcode`\@=\atcatcode
\let\atcatcode\relax
+ \global\bbl at csarg\let{rqtex@\languagename}\relax
\fi}%
\fi
+ % == frenchspacing ==
+ \ifcase\bbl at howloaded\in at true\else\in at false\fi
+ \ifin@\else\bbl at xin@{typography/frenchspacing}{\bbl at key@list}\fi
+ \ifin@
+ \bbl at extras@wrap{\\\bbl at pre@fs}%
+ {\bbl at pre@fs}%
+ {\bbl at post@fs}%
+ \fi
% == Release saved transforms ==
\bbl at release@transforms\relax % \relax closes the last item.
% == main ==
@@ -11139,7 +11203,9 @@ help from Bernd Raichle, for which I am grateful.
\fi}
% \end{macrocode}
%
-% Depending on whether or not the language exists, we define two macros.
+% Depending on whether or not the language exists (based on
+% |\date<language>|), we define two macros. Remember
+% |\bbl at startcommands| opens a group.
%
% \begin{macrocode}
\def\bbl at provide@new#1{%
@@ -11178,37 +11244,11 @@ help from Bernd Raichle, for which I am grateful.
\gdef\<#1hyphenmins>{%
{\bbl at ifunset{bbl at lfthm@#1}{2}{\bbl at cs{lfthm@#1}}}%
{\bbl at ifunset{bbl at rgthm@#1}{3}{\bbl at cs{rgthm@#1}}}}}%
- % == hyphenrules ==
+ % == hyphenrules (also in renew) ==
\bbl at provide@hyphens{#1}%
- % == frenchspacing == (only if new)
- \bbl at ifunset{bbl at frspc@#1}{}%
- {\edef\bbl at tempa{\bbl at cl{frspc}}%
- \edef\bbl at tempa{\expandafter\@car\bbl at tempa\@nil}%
- \if u\bbl at tempa % do nothing
- \else\if n\bbl at tempa % non french
- \expandafter\bbl at add\csname extras#1\endcsname{%
- \let\bbl at elt\bbl at fs@elt at i
- \bbl at fs@chars}%
- \else\if y\bbl at tempa % french
- \expandafter\bbl at add\csname extras#1\endcsname{%
- \let\bbl at elt\bbl at fs@elt at ii
- \bbl at fs@chars}%
- \fi\fi\fi}%
- %
\ifx\bbl at KVP@main\@nil\else
\expandafter\main at language\expandafter{#1}%
\fi}
-% A couple of macros used above, to avoid hashes #######...
-\def\bbl at fs@elt at i#1#2#3{%
- \ifnum\sfcode`#1=#2\relax
- \babel at savevariable{\sfcode`#1}%
- \sfcode`#1=#3\relax
- \fi}%
-\def\bbl at fs@elt at ii#1#2#3{%
- \ifnum\sfcode`#1=#3\relax
- \babel at savevariable{\sfcode`#1}%
- \sfcode`#1=#2\relax
- \fi}%
%
\def\bbl at provide@renew#1{%
\ifx\bbl at KVP@captions\@nil\else
@@ -11222,7 +11262,7 @@ help from Bernd Raichle, for which I am grateful.
\bbl at savedate
\EndBabelCommands
\fi
- % == hyphenrules ==
+ % == hyphenrules (also in new) ==
\ifx\bbl at lbkflag\@empty
\bbl at provide@hyphens{#1}%
\fi}
@@ -11235,11 +11275,11 @@ help from Bernd Raichle, for which I am grateful.
%
% \begin{macrocode}
\def\bbl at load@basic#1{%
- \bbl at ifunset{bbl at inidata@\languagename}{}%
- {\getlocaleproperty\bbl at tempa{\languagename}{identification/load.level}%
- \ifcase\bbl at tempa
- \bbl at csarg\let{lname@\languagename}\relax
- \fi}%
+ \ifcase\bbl at howloaded\else
+ \ifcase0\csname bbl at llevel@\languagename\endcsname
+ \bbl at csarg\let{lname@\languagename}\relax
+ \fi
+ \fi
\bbl at ifunset{bbl at lname@#1}%
{\def\BabelBeforeIni##1##2{%
\begingroup
@@ -11322,16 +11362,17 @@ help from Bernd Raichle, for which I am grateful.
% \begin{macrocode}
\def\bbl at iniline#1\bbl at iniline{%
\@ifnextchar[\bbl at inisect{\@ifnextchar;\bbl at iniskip\bbl at inistore}#1\@@}% ]
-\def\bbl at inisect[#1]#2\@@{\def\bbl at section{#1}}%
+\def\bbl at inisect[#1]#2\@@{\def\bbl at section{#1}}
\def\bbl at iniskip#1\@@{}% if starts with ;
\def\bbl at inistore#1=#2\@@{% full (default)
\bbl at trim@def\bbl at tempa{#1}%
\bbl at trim\toks@{#2}%
- \bbl at ifunset{bbl at KVP@\bbl at section/\bbl at tempa}%
- {\bbl at exp{%
+ \bbl at xin@{;\bbl at section/\bbl at tempa;}{\bbl at key@list}%
+ \ifin@\else
+ \bbl at exp{%
\\\g at addto@macro\\\bbl at inidata{%
- \\\bbl at elt{\bbl at section}{\bbl at tempa}{\the\toks@}}}}%
- {}}%
+ \\\bbl at elt{\bbl at section}{\bbl at tempa}{\the\toks@}}}%
+ \fi}
\def\bbl at inistore@min#1=#2\@@{% minimal (maybe set in \bbl at read@ini)
\bbl at trim@def\bbl at tempa{#1}%
\bbl at trim\toks@{#2}%
@@ -11339,7 +11380,7 @@ help from Bernd Raichle, for which I am grateful.
\ifin@
\bbl at exp{\\\g at addto@macro\\\bbl at inidata{%
\\\bbl at elt{identification}{\bbl at tempa}{\the\toks@}}}%
- \fi}%
+ \fi}
% \end{macrocode}
%
% Now, the ‘main loop’, which \textbf{**must be executed inside a
@@ -11357,6 +11398,7 @@ help from Bernd Raichle, for which I am grateful.
\csname newread\endcsname\bbl at readstream
\fi
\def\bbl at read@ini#1#2{%
+ \global\let\bbl at extend@ini\@gobble
\openin\bbl at readstream=babel-#1.ini
\ifeof\bbl at readstream
\bbl at error
@@ -11365,7 +11407,7 @@ help from Bernd Raichle, for which I am grateful.
is not complete.}%
{Fix the name or reinstall babel.}%
\else
- % Store ini data in \bbl at inidata
+ % == Store ini data in \bbl at inidata ==
\catcode`\[=12 \catcode`\]=12 \catcode`\==12 \catcode`\&=12
\catcode`\;=12 \catcode`\|=12 \catcode`\%=14 \catcode`\-=12
\bbl at info{Importing
@@ -11388,28 +11430,62 @@ help from Bernd Raichle, for which I am grateful.
\expandafter\bbl at iniline\bbl at line\bbl at iniline
\fi
\repeat
- % Process stored data
+ % == Process stored data ==
\bbl at csarg\xdef{lini@\languagename}{#1}%
- \let\bbl at savestrings\@empty
- \let\bbl at savetoday\@empty
- \let\bbl at savedate\@empty
- \def\bbl at elt##1##2##3{%
- \def\bbl at section{##1}%
- \in@{=date.}{=##1}% Find a better place
- \ifin@
- \bbl at ini@calendar{##1}%
- \fi
- \global\bbl at csarg\let{bbl at KVP@##1/##2}\relax
- \bbl at ifunset{bbl at inikv@##1}{}%
- {\csname bbl at inikv@##1\endcsname{##2}{##3}}}%
- \bbl at inidata
- % 'Export' data
+ \bbl at read@ini at aux
+ % == 'Export' data ==
\bbl at ini@exports{#2}%
\global\bbl at csarg\let{inidata@\languagename}\bbl at inidata
\global\let\bbl at inidata\@empty
\bbl at exp{\\\bbl at add@list\\\bbl at ini@loaded{\languagename}}%
\bbl at toglobal\bbl at ini@loaded
\fi}
+\def\bbl at read@ini at aux{%
+ \let\bbl at savestrings\@empty
+ \let\bbl at savetoday\@empty
+ \let\bbl at savedate\@empty
+ \def\bbl at elt##1##2##3{%
+ \def\bbl at section{##1}%
+ \in@{=date.}{=##1}% Find a better place
+ \ifin@
+ \bbl at ini@calendar{##1}%
+ \fi
+ \bbl at ifunset{bbl at inikv@##1}{}%
+ {\csname bbl at inikv@##1\endcsname{##2}{##3}}}%
+ \bbl at inidata}
+% \end{macrocode}
+%
+% A variant to be used when the ini file has been already loaded,
+% because it's not the first |\babelprovide| for this language.
+%
+% \begin{macrocode}
+\def\bbl at extend@ini at aux#1{%
+ \bbl at startcommands*{#1}{captions}%
+ % Activate captions/... and modify exports
+ \bbl at csarg\def{inikv at captions.licr}##1##2{%
+ \setlocalecaption{#1}{##1}{##2}}%
+ \def\bbl at inikv@captions##1##2{%
+ \bbl at ini@captions at aux{##1}{##2}}%
+ \def\bbl at stringdef##1##2{\gdef##1{##2}}%
+ \def\bbl at exportkey##1##2##3{%
+ \bbl at ifunset{bbl@@kv@##2}{}%
+ {\expandafter\ifx\csname bbl@@kv@##2\endcsname\@empty\else
+ \bbl at exp{\global\let\<bbl@##1@\languagename>\<bbl@@kv@##2>}%
+ \fi}}%
+ % As with \bbl at read@ini, but with some changes
+ \bbl at read@ini at aux
+ \bbl at ini@exports\tw@
+ % Update inidata at lang by pretending the ini is read.
+ \def\bbl at elt##1##2##3{%
+ \def\bbl at section{##1}%
+ \bbl at iniline##2=##3\bbl at iniline}%
+ \csname bbl at inidata@#1\endcsname
+ \global\bbl at csarg\let{inidata@#1}\bbl at inidata
+ \StartBabelCommands*{#1}{date}% And from the import stuff
+ \def\bbl at stringdef##1##2{\gdef##1{##2}}%
+ \bbl at savetoday
+ \bbl at savedate
+ \bbl at endcommands}
% \end{macrocode}
%
% A somewhat hackish tool to handle calendar sections. To be improved.
@@ -11449,7 +11525,7 @@ help from Bernd Raichle, for which I am grateful.
\edef\bbl at tempb{\zap at space #2 \@empty}% key
\bbl at trim\toks@{#3}% value
\bbl at exp{%
- \global\let\<bbl at KVP@\bbl at tempa/\bbl at tempb>\\\@empty % just a flag
+ \edef\\\bbl at key@list{\bbl at key@list \bbl at tempa/\bbl at tempb;}%
\\\g at addto@macro\\\bbl at inidata{%
\\\bbl at elt{\bbl at tempa}{\bbl at tempb}{\the\toks@}}}}%
% \end{macrocode}
@@ -11494,6 +11570,7 @@ help from Bernd Raichle, for which I am grateful.
\or
\bbl at iniwarning{.xelatex}%
\fi%
+ \bbl at exportkey{llevel}{identification.load.level}{}%
\bbl at exportkey{elname}{identification.name.english}{}%
\bbl at exp{\\\bbl at exportkey{lname}{identification.name.opentype}%
{\csname bbl at elname@\languagename\endcsname}}%
@@ -11519,9 +11596,9 @@ help from Bernd Raichle, for which I am grateful.
\bbl at exportkey{hyotl}{typography.hyphenate.other.locale}{}%
\bbl at exportkey{hyots}{typography.hyphenate.other.script}{}%
\bbl at exportkey{intsp}{typography.intraspace}{}%
+ \bbl at exportkey{frspc}{typography.frenchspacing}{u}%
\bbl at exportkey{chrng}{characters.ranges}{}%
\bbl at exportkey{dgnat}{numbers.digits.native}{}%
- \bbl at exportkey{frspc}{typography.frenchspacing}{u}%
\ifnum#1=\tw@ % only (re)new
\bbl at exportkey{rqtex}{identification.require.babel}{}%
\bbl at toglobal\bbl at savetoday
@@ -11694,6 +11771,7 @@ help from Bernd Raichle, for which I am grateful.
\bbl at replace\bbl at toreplace{[}{\csname the}%
\bbl at replace\bbl at toreplace{]}{\endcsname{}}%
\toks@\expandafter{\bbl at toreplace}%
+ % TODO. Execute only once:
\bbl at exp{%
\\\bbl at add\<extras\languagename>{%
\\\babel at save\<labelenum\romannumeral\bbl at tempa>%
@@ -11796,9 +11874,7 @@ help from Bernd Raichle, for which I am grateful.
\bbl at trim@def\bbl at toreplace{#5}%
\bbl at TG@@date
\bbl at ifunset{bbl at date@\languagename @}%
- {\global\bbl at csarg\let{date@\languagename @}\bbl at toreplace
- % TODO. Move to a better place.
- \bbl at exp{%
+ {\bbl at exp{% TODO. Move to a better place.
\gdef\<\languagename date>{\\\protect\<\languagename date >}%
\gdef\<\languagename date >####1####2####3{%
\\\bbl at usedategrouptrue
@@ -11809,6 +11885,7 @@ help from Bernd Raichle, for which I am grateful.
\<\languagename date>%
{\\\the\year}{\\\the\month}{\\\the\day}}}}}%
{}%
+ \global\bbl at csarg\let{date@\languagename @}\bbl at toreplace
\ifx\bbl at tempb\@empty\else
\global\bbl at csarg\let{date@\languagename @\bbl at tempb}\bbl at toreplace
\fi}%
@@ -13026,6 +13103,7 @@ help from Bernd Raichle, for which I am grateful.
\expandafter\bbl at intrapenalty\bbl at KVP@intrapenalty\@@
\fi
\bbl at exp{%
+ % TODO. Execute only once (but redundant):
\\\bbl at add\<extras\languagename>{%
\XeTeXlinebreaklocale "\bbl at cl{tbcp}"%
\<bbl at xeisp@\languagename>%
diff --git a/babel.ins b/babel.ins
index 894fbbd..e1fdcb4 100644
--- a/babel.ins
+++ b/babel.ins
@@ -26,7 +26,7 @@
%% and covered by LPPL is defined by the unpacking scripts (with
%% extension .ins) which are part of the distribution.
%%
-\def\filedate{2021/06/15}
+\def\filedate{2021/06/27}
\def\batchfile{babel.ins}
\input docstrip.tex
diff --git a/babel.pdf b/babel.pdf
index ff9d73a..88f6699 100644
Binary files a/babel.pdf and b/babel.pdf differ
diff --git a/bbcompat.dtx b/bbcompat.dtx
index 8f171a8..575f5cd 100644
--- a/bbcompat.dtx
+++ b/bbcompat.dtx
@@ -30,7 +30,7 @@
%
% \iffalse
%<*dtx>
-\ProvidesFile{bbcompat.dtx}[2021/06/15 v3.60.2404]
+\ProvidesFile{bbcompat.dtx}[2021/06/27 v3.60.2416]
%</dtx>
%
%% File 'bbcompat.dtx'
diff --git a/locale/ar/babel-ar.ini b/locale/ar/babel-ar.ini
index 13c91e2..2746033 100644
--- a/locale/ar/babel-ar.ini
+++ b/locale/ar/babel-ar.ini
@@ -24,9 +24,8 @@ script.name = Arabic
script.tag.bcp47 = Arab
script.tag.opentype = arab
level = 1
-encodings =
+encodings = LAE
derivate = no
-require.babel = arabic
[captions]
preface = مدخل
More information about the latex3-commits
mailing list.