[latex3-commits] [git/LaTeX3-latex3-babel] main: Fix #43. Assume \AddToHook exists. Dates in genitive for sr. (2457139)

Javier email at dante.de
Thu May 5 18:47:59 CEST 2022


Repository : https://github.com/latex3/babel
On branch  : main
Link       : https://github.com/latex3/babel/commit/245713928d7d6dc289a7d5e447da0b402a796034

>---------------------------------------------------------------

commit 245713928d7d6dc289a7d5e447da0b402a796034
Author: Javier <email at localhost>
Date:   Thu May 5 18:47:59 2022 +0200

    Fix #43. Assume \AddToHook exists. Dates in genitive for sr.


>---------------------------------------------------------------

245713928d7d6dc289a7d5e447da0b402a796034
 README.md              |   5 ++-
 babel.dtx              |  90 ++++++++++++++++++++-----------------------------
 babel.ins              |   2 +-
 babel.pdf              | Bin 857732 -> 857683 bytes
 bbcompat.dtx           |   2 +-
 locale/sr/babel-sr.ini |  30 +++++++++++++++++
 6 files changed, 72 insertions(+), 57 deletions(-)

diff --git a/README.md b/README.md
index 537cda3..a0ffe5f 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,4 @@
-## Babel 3.74
+## Babel 3.75.2728
 
 This package manages culturally-determined typographical (and other)
 rules, and hyphenation patterns for a wide range of languages. Many
@@ -46,6 +46,9 @@ respective authors.
 
 ### Summary of latest changes
 ```
+3.75   2022-05-?? (dev)
+       * Fixes: diagbox (#43)
+
 3.74   2022-04-30
        * Fixes:
          - Error in transforms if | is active.
diff --git a/babel.dtx b/babel.dtx
index 980ab2b..60a57a3 100644
--- a/babel.dtx
+++ b/babel.dtx
@@ -32,7 +32,7 @@
 %
 % \iffalse
 %<*filedriver>
-\ProvidesFile{babel.dtx}[2022/04/30 v3.74 The Babel package]
+\ProvidesFile{babel.dtx}[2022/05/05 v3.75.2728 The Babel package]
 \documentclass{ltxdoc}
 \GetFileInfo{babel.dtx}
 \usepackage{fontspec}
@@ -184,11 +184,7 @@
    Poppelier, Piet van Oostrum and many others have been used.
    Bernd Raichle has provided many helpful suggestions.}}
 \author{Johannes Braams\\
-        Kersengaarde 33\\
-        2723 BP Zoetermeer\\
-        The Netherlands\\
-        \normalsize From version 3.9 on, Javier Bezos\\
-        \normalsize \texttt{www.texnia.com}}
+        Javier Bezos}
 
 \date{Typeset \today}
 \begin{titlepage}
@@ -213,12 +209,12 @@ Version \csname @gobble\expandafter\endcsname\fileversion\newline
 
 \LARGE
 \vspace{1.2cm}
-Johannes L. Braams\\[-.5ex]
-{\large Original author}
-
-\vspace{.3cm}
 Javier Bezos\\[-.5ex]
 {\large Current maintainer}
+
+\vspace{.3cm}
+Johannes L. Braams\\[-.5ex]
+{\large Original author}
 \end{minipage}
 &\cellcolor[rgb]{.92, .86, .73}
 \vspace{2cm}
@@ -5116,8 +5112,8 @@ help from Bernd Raichle, for which I am grateful.
 % \section{Tools}
 %
 %    \begin{macrocode}
-%<<version=3.74>>
-%<<date=2022/04/30>>
+%<<version=3.75.2728>>
+%<<date=2022/05/05>>
 %    \end{macrocode}
 %
 % \textbf{Do not use the following macros in \texttt{ldf} files. They
@@ -11791,11 +11787,7 @@ help from Bernd Raichle, for which I am grateful.
 % latter solution will be eventually removed).
 %
 %    \begin{macrocode}
-\bbl at ifformatlater{2021-06-01}%
-  {\def\bbl at patchfont#1{\AddToHook{selectfont}{#1}}}
-  {\def\bbl at patchfont#1{%
-     \expandafter\bbl at add\csname selectfont \endcsname{#1}%
-     \expandafter\bbl at toglobal\csname selectfont \endcsname}}
+\def\bbl at patchfont#1{\AddToHook{selectfont}{#1}}
 %    \end{macrocode}
 %
 % \end{macro}
@@ -14767,22 +14759,21 @@ end
        % \(text|par)dir required in pgf:
        \def\bbl at pictresetdir{\bodydir TRT\pardir TRT\textdir TRT\relax}%
      \fi}%
-   \ifx\AddToHook\@undefined\else
-     \AddToHook{env/picture/begin}{\bbl at pictsetdir\tw@}%
-     \directlua{
-       Babel.get_picture_dir = true
-       Babel.picture_has_bidi = 0
-       %
-       function Babel.picture_dir (head)
-         if not Babel.get_picture_dir then return head end
-         if Babel.hlist_has_bidi(head) then 
-           Babel.picture_has_bidi = 1
-         end
-         return head
+   \AddToHook{env/picture/begin}{\bbl at pictsetdir\tw@}%
+   \directlua{
+     Babel.get_picture_dir = true
+     Babel.picture_has_bidi = 0
+     %
+     function Babel.picture_dir (head)
+       if not Babel.get_picture_dir then return head end
+       if Babel.hlist_has_bidi(head) then 
+         Babel.picture_has_bidi = 1
        end
-       luatexbase.add_to_callback("hpack_filter", Babel.picture_dir,
-         "Babel.picture_dir")
-     }%
+       return head
+     end
+     luatexbase.add_to_callback("hpack_filter", Babel.picture_dir,
+       "Babel.picture_dir")
+   }%
    \AtBeginDocument{%
      \long\def\put(#1,#2)#3{%
        \@killglue 
@@ -14797,7 +14788,7 @@ end
          \setbox\z@\hb at xt@\z@{%
            \@defaultunitsset\@tempdimc{#1}\unitlength
            \kern\@tempdimc
-           #3\hss}%
+           #3\hss}% TODO: #3 executed twice (below). That’s bad.
          \edef\bbl at tempc{\directlua{tex.print(Babel.picture_has_bidi)}}%
        \fi
        % Do:
@@ -14807,35 +14798,26 @@ end
          \kern\@tempdimc
          {\ifnum\bbl at tempc>\z@\bbl at pictresetdir\fi#3}\hss}% 
        \ignorespaces}%
-       \MakeRobust\put}%
-   \fi
+     \MakeRobust\put}%
    \AtBeginDocument
-     {\ifx\pgfpicture\@undefined\else % TODO. Allow deactivate?
-        \ifx\AddToHook\@undefined
-          \bbl at sreplace\pgfpicture{\pgfpicturetrue}%
-            {\bbl at pictsetdir\z@\pgfpicturetrue}%
-        \else
-          \AddToHook{env/pgfpicture/begin}{\bbl at pictsetdir\@ne}%
-        \fi
+     {\AddToHook{cmd/diagbox at pict/before}{\let\bbl at pictsetdir\@gobble}%
+      \ifx\pgfpicture\@undefined\else % TODO. Allow deactivate?
+        \AddToHook{env/pgfpicture/begin}{\bbl at pictsetdir\@ne}%
         \bbl at add\pgfinterruptpicture{\bbl at pictresetdir}%
         \bbl at add\pgfsys at beginpicture{\bbl at pictsetdir\z@}%
       \fi
       \ifx\tikzpicture\@undefined\else    
-        \ifx\AddToHook\@undefined\else
-          \AddToHook{env/tikzpicture/begin}{\bbl at pictsetdir\z@}%
-        \fi
+        \AddToHook{env/tikzpicture/begin}{\bbl at pictsetdir\z@}%
         \bbl at add\tikz at atbegin@node{\bbl at pictresetdir}%
         \bbl at sreplace\tikz{\begingroup}{\begingroup\bbl at pictsetdir\tw@}%
       \fi
-      \ifx\AddToHook\@undefined\else
-        \ifx\tcolorbox\@undefined\else
-          \AddToHook{env/tcolorbox/begin}{\bbl at pictsetdir\@ne}%
-          \bbl at sreplace\tcb at savebox
-            {\ignorespaces}{\ignorespaces\bbl at pictresetdir}%
-          \ifx\tikzpicture at tcb@hooked\@undefined\else
-            \bbl at sreplace\tikzpicture at tcb@hooked{\noexpand\tikzpicture}%
-              {\textdir TLT\noexpand\tikzpicture}%
-          \fi
+      \ifx\tcolorbox\@undefined\else
+        \AddToHook{env/tcolorbox/begin}{\bbl at pictsetdir\@ne}%
+        \bbl at sreplace\tcb at savebox
+          {\ignorespaces}{\ignorespaces\bbl at pictresetdir}%
+        \ifx\tikzpicture at tcb@hooked\@undefined\else
+          \bbl at sreplace\tikzpicture at tcb@hooked{\noexpand\tikzpicture}%
+            {\textdir TLT\noexpand\tikzpicture}%
         \fi
       \fi
     }}
diff --git a/babel.ins b/babel.ins
index 1c80ae6..289b286 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{2022/04/30}
+\def\filedate{2022/05/05}
 \def\batchfile{babel.ins}
 \input docstrip.tex
 
diff --git a/babel.pdf b/babel.pdf
index b68346d..2ca0739 100644
Binary files a/babel.pdf and b/babel.pdf differ
diff --git a/bbcompat.dtx b/bbcompat.dtx
index b7a7c3d..b8fb288 100644
--- a/bbcompat.dtx
+++ b/bbcompat.dtx
@@ -30,7 +30,7 @@
 %
 % \iffalse
 %<*dtx>
-\ProvidesFile{bbcompat.dtx}[2022/04/30 v3.74]
+\ProvidesFile{bbcompat.dtx}[2022/05/05 v3.75.2728]
 %</dtx>
 %
 %% File 'bbcompat.dtx'
diff --git a/locale/sr/babel-sr.ini b/locale/sr/babel-sr.ini
index c0e4f1d..690fefd 100644
--- a/locale/sr/babel-sr.ini
+++ b/locale/sr/babel-sr.ini
@@ -74,6 +74,22 @@ also = \cyrv\cyri\cyrd\cyri\cyrt\cyra\cyrk\cyro\cyrdje\cyre
 proof = \CYRD\cyro\cyrk\cyra\cyrz
 glossary = \CYRR\cyre\cyrch\cyrn\cyri\cyrk
 
+[date.gregorian.Genitive]
+date.long = [d].[ ][MMMM] [y].
+date.short = [d].[M].[yy].
+months.wide.1 =    јануара
+months.wide.2 =    фебруара
+months.wide.3 =    марта
+months.wide.4 =    априла
+months.wide.5 =    маја
+months.wide.6 =    јуна
+months.wide.7 =    јула
+months.wide.8 =    августа
+months.wide.9 =    септембра
+months.wide.10 =   октобра
+months.wide.11 =   новембра
+months.wide.12 =   децембра
+
 [date.gregorian]
 date.long = [d].[ ][MMMM] [y].
 date.short = [d].[M].[yy].
@@ -129,6 +145,20 @@ dayPeriods.narrow.pm = p
 dayPeriods.wide.am = пре подне
 dayPeriods.wide.pm = по подне
 
+[date.gregorian.Genitive.licr]
+months.wide.1 =  \cyrje\cyra\cyrn\cyru\cyra\cyrr\cyra
+months.wide.2 =  \cyrf\cyre\cyrb\cyrr\cyru\cyra\cyrr\cyra
+months.wide.3 =  \cyrm\cyra\cyrr\cyrt\cyra
+months.wide.4 =  \cyra\cyrp\cyrr\cyri\cyrl\cyra
+months.wide.5 =  \cyrm\cyra\cyrje\cyra
+months.wide.6 =  \cyrje\cyru\cyrn\cyra
+months.wide.7 =  \cyrje\cyru\cyrl\cyra
+months.wide.8 =  \cyra\cyrv\cyrg\cyru\cyrs\cyrt\cyra
+months.wide.9 =  \cyrs\cyre\cyrp\cyrt\cyre\cyrm\cyrb\cyrr\cyra
+months.wide.10 = \cyro\cyrk\cyrt\cyro\cyrb\cyrr\cyra
+months.wide.11 = \cyrn\cyro\cyrv\cyre\cyrm\cyrb\cyrr\cyra
+months.wide.12 = \cyrd\cyre\cyrc\cyre\cyrm\cyrb\cyrr\cyra
+
 [date.gregorian.licr]
 months.wide.1 = \cyrje\cyra\cyrn\cyru\cyra\cyrr
 months.wide.2 = \cyrf\cyre\cyrb\cyrr\cyru\cyra\cyrr





More information about the latex3-commits mailing list.