diff options
author | Karl Berry <karl@freefriends.org> | 2019-09-08 21:02:06 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2019-09-08 21:02:06 +0000 |
commit | 52783dec5aad4f166336a1844a697892379c4dfb (patch) | |
tree | 355c3af792baf711e7aa52b355db493e6be02b6e /Master/texmf-dist/source/generic/babel-french | |
parent | 3dbf4f3fa11c18e4342033a7e86a01f9c4ac2a3c (diff) |
babel-french (8sep19)
git-svn-id: svn://tug.org/texlive/trunk@52054 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/generic/babel-french')
-rw-r--r-- | Master/texmf-dist/source/generic/babel-french/frenchb.dtx | 80 |
1 files changed, 63 insertions, 17 deletions
diff --git a/Master/texmf-dist/source/generic/babel-french/frenchb.dtx b/Master/texmf-dist/source/generic/babel-french/frenchb.dtx index d916f838aca..8241658b280 100644 --- a/Master/texmf-dist/source/generic/babel-french/frenchb.dtx +++ b/Master/texmf-dist/source/generic/babel-french/frenchb.dtx @@ -1,4 +1,4 @@ -%\CheckSum{3769} +%\CheckSum{3801} % %\iffalse % Tell the LaTeX system who we are and write an entry on the @@ -13,7 +13,7 @@ %<frenchb>\ProvidesLanguage{frenchb} %<lua>--[[ %<lua> File `frenchb.lua’ generated from frenchb.dtx - [2019/03/30 v3.5e French support from the babel system] + [2019/09/07 v3.5f French support from the babel system] %<*internal> \iffalse %</internal> @@ -151,6 +151,11 @@ % French language, former aliases \opt{frenchb} or \opt{francais} % are \emph{depreciated}; expect them to be removed sooner or later!} % +% A variant \opt{acadian} of \opt{french} is provided; it is +% originally identical to \opt{french} but can be customised +% independently in terms of patterns, punctuation spacing, captions, +% etc. Both variants can be used together inside the same document. +% % \frenchb{} takes account of \babel’s \emph{main language} defined % as the \emph{last} option at \babel’s loading. When French is % not \babel’s main language, \frenchb{} does not alter the general @@ -1034,8 +1039,17 @@ % which stands for Canadian French. % If no specific hyphenation patterns are available, Canadian French % will use the French ones. +% +% \changes{v3.5f}{2019/09/04}{\cs{l@canadien} was defined too early +% in file `canadien.ldf': \cs{l@acadian} might not be defined.} +% % \begin{macrocode} -\ifdefined\l@acadian \else \adddialect\l@acadian\l@french \fi +\ifdefined\l@acadian + \adddialect\l@canadien\l@acadian +\else + \adddialect\l@acadian\l@french + \adddialect\l@canadien\l@french +\fi % \end{macrocode} % % French uses the standard values of |\lefthyphenmin| (2) @@ -3414,9 +3428,9 @@ return french_punctuation % unpleasant when the comma is used as a decimal separator % in French: it has to be entered as |{,}|. % |\DecimalMathComma| makes the comma be an ordinary character -% (of type |\mathord|) in French \emph{only} (no space added); -% |\StandardMathComma| switches back to the standard behaviour -% of the comma. +% (of type |\mathord|) in French (or Acadian) \emph{only} +% (no space added); |\StandardMathComma| switches back to the +% standard behaviour of the comma. % % \changes{v3.2e}{2017/01/09}{\cs{DecimalMathComma} didn’t work % with LuaTeX. Fixed now.} @@ -3424,6 +3438,9 @@ return french_punctuation % \changes{v3.2f}{2017/01/15}{Fixed conflict with the icomma % package.} % +% \changes{v3.5f}{2019/09/07}{Fixed bug with the acadian language. +% Warning added if used with the icomma package.} +% % Unfortunately, |\newcount| inside |\if| breaks Plain formats. % \begin{macrocode} \newif\ifFB@icomma @@ -3454,18 +3471,41 @@ return french_punctuation \newcommand*{\dec@math@comma}{\mathcode`\,=\dec@mcc} \newcommand*{\std@math@comma}{\mathcode`\,=\std@mcc} \fi +% \end{macrocode} +% |\DecimalMathComma| operates in French or Acadian independently. +% \begin{macrocode} \newcommand*{\DecimalMathComma}{% - \ifFBfrench\dec@math@comma\fi - \ifFB@icomma\else\addto\extrasfrench{\dec@math@comma}\fi + \ifFB@icomma + \PackageWarning{french.ldf}{% + icomma package loaded, \protect\DecimalMathComma\MessageBreak + does nothing. Reported}% + \else + \ifFBfrench + \dec@math@comma + \expandafter\addto\csname extras\languagename\endcsname + {\dec@math@comma}% + \fi + \fi } \newcommand*{\StandardMathComma}{% - \std@math@comma - \ifFB@icomma\else\addto\extrasfrench{\std@math@comma}\fi + \ifFB@icomma + \PackageWarning{french.ldf}{% + icomma package loaded, \protect\StandardMathComma\MessageBreak + does nothing. Reported}% + \else + \std@math@comma + \expandafter\addto\csname extras\languagename\endcsname + {\std@math@comma}% + \fi } \ifLaTeXe \AtBeginDocument{\@ifpackageloaded{icomma}% {\FB@icommatrue}% - {\addto\noextrasfrench{\std@math@comma}}% + {\addto\noextrasfrench{\std@math@comma}% + \ifdefined\noextrasacadian + \addto\noextrasacadian{\std@math@comma}% + \fi + }% } \else \addto\noextrasfrench{\std@math@comma} @@ -5809,15 +5849,22 @@ return french_punctuation {Option `canadien' for Babel is *deprecated*,\MessageBreak it might be removed sooner or later. Please\MessageBreak use `acadian' instead; reported}% -\let\l@canadien\l@acadian \def\CurrentOption{acadian} +% \end{macrocode} +% \changes{v3.5f}{2019/09/04}{\cs{selectlanguage}\{canadien\} +% allowed again only for backward compatibility (deprecated).} +% \begin{macrocode} +\def\datecanadien{\dateacadian} +\def\captionscanadien{\captionsacadian} +\def\extrascanadien{\extrasacadian} +\def\noextrascanadien{\noextrasacadian} %</canadien> %<*francais> \PackageWarning{francais.ldf}% {Option `francais' for Babel is *deprecated*,\MessageBreak it might be removed sooner or later. Please\MessageBreak use `french' instead; reported}% -\let\l@francais\l@french +\chardef\l@francais\l@french \def\CurrentOption{french} %</francais> % \end{macrocode} @@ -5828,7 +5875,7 @@ return french_punctuation %<*frenchb> \def\bbl@tempa{frenchb} \ifx\CurrentOption\bbl@tempa - \let\l@frenchb\l@french + \chardef\l@frenchb\l@french \def\CurrentOption{french} \PackageWarning{babel-french}% {Option `frenchb' for Babel is *deprecated*,\MessageBreak @@ -5837,7 +5884,7 @@ return french_punctuation \else \def\bbl@tempa{francais} \ifx\CurrentOption\bbl@tempa - \let\l@francais\l@french + \chardef\l@francais\l@french \def\CurrentOption{french} % \end{macrocode} % Plain formats: no warning when \file{francais.sty} loads @@ -5847,12 +5894,11 @@ return french_punctuation \PackageWarning{babel-french}% {Option `francais' for Babel is *deprecated*,\MessageBreak it might be removed sooner or later. Please\MessageBreak - use `french' instead; reported}% + use `french' instead; reported} \fi \else \def\bbl@tempa{canadien} \ifx\CurrentOption\bbl@tempa - \let\l@canadien\l@acadian \def\CurrentOption{acadian} \PackageWarning{babel-french}% {Option `canadien' for Babel is *deprecated*,\MessageBreak |