diff options
author | Karl Berry <karl@freefriends.org> | 2020-11-11 22:02:29 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2020-11-11 22:02:29 +0000 |
commit | 5ca3facf87a90c246e0525fadbc9b7831a86bf34 (patch) | |
tree | d727d5a1c19ff868c0369843097b0f26328eec53 /Master/texmf-dist/tex | |
parent | 332f896e129474a718b2385024208daf39662240 (diff) |
numspell (11nov20)
git-svn-id: svn://tug.org/texlive/trunk@56912 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex')
-rw-r--r-- | Master/texmf-dist/tex/latex/numspell/numspell-english.sty | 13 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/numspell/numspell.sty | 40 |
2 files changed, 25 insertions, 28 deletions
diff --git a/Master/texmf-dist/tex/latex/numspell/numspell-english.sty b/Master/texmf-dist/tex/latex/numspell/numspell-english.sty index a3120e3ca85..4ad8bf476d2 100644 --- a/Master/texmf-dist/tex/latex/numspell/numspell-english.sty +++ b/Master/texmf-dist/tex/latex/numspell/numspell-english.sty @@ -16,24 +16,31 @@ %% The Current Maintainer of this work is Tibor Tomacs. %% \NeedsTeXFormat{LaTeX2e}[1999/12/01] -\ProvidesPackage{numspell-english}[2020/11/07 v1.1 English language package for numspell] +\ProvidesPackage{numspell-english}[2020/11/11 v1.2 English language package for numspell] + +\def\numspell@and@en{\numspell@{ and }} +\def\numspell@and@@en{\numspell@{, }}% It was 'and' in v1.0 %% ----------- -%% \numspellGB (Default) +%% \numspellGB %% ----------- %% It changes to British English %% \def\numspellGB{% + \def\numspell@US{}% \def\numspell@and@en{\numspell@{ and }}% \def\numspell@and@@en{\numspell@{, }}% It was 'and' in v1.0 } -\numspellGB %% ----------- %% \numspellUS %% ----------- %% It changes to American English %% +\def\numspell@US{% + \def\numspell@and@en{\numspell@{ }}% + \def\numspell@and@@en{\numspell@{, }}% +} \def\numspellUS{% \def\numspell@and@en{\numspell@{ }}% \def\numspell@and@@en{\numspell@{, }}% diff --git a/Master/texmf-dist/tex/latex/numspell/numspell.sty b/Master/texmf-dist/tex/latex/numspell/numspell.sty index c74912b8d15..ccd615f3963 100644 --- a/Master/texmf-dist/tex/latex/numspell/numspell.sty +++ b/Master/texmf-dist/tex/latex/numspell/numspell.sty @@ -17,12 +17,10 @@ %% %% The Current Maintainer of this work is Tibor Tomacs. %% -\NeedsTeXFormat{LaTeX2e}[1999/12/01] -\ProvidesPackage{numspell}[2020/11/07 v1.3 Package for spelling cardinal and ordinal numbers] +\NeedsTeXFormat{LaTeX2e}[2020/10/01] +\ProvidesPackage{numspell}[2020/11/11 v1.4 Package for spelling cardinal and ordinal numbers] -\RequirePackage{xstring} -\RequirePackage{iflang} -\RequirePackage{etoolbox} +\RequirePackage{xstring,iflang} \newcounter{numspell@counter@tempa} \newcounter{numspell@counter@tempb} @@ -235,38 +233,30 @@ \IfLanguageName{british}{\@numspell@lang@notsupported@false}{}% \IfLanguageName{ukenglish}{\@numspell@lang@notsupported@false}{}% \IfLanguageName{UKenglish}{\@numspell@lang@notsupported@false}{}% - \IfLanguageName{american}{\@numspell@lang@notsupported@false\numspellUS}{}% - \IfLanguageName{usenglish}{\@numspell@lang@notsupported@false\numspellUS}{}% - \IfLanguageName{USenglish}{\@numspell@lang@notsupported@false\numspellUS}{}% + \IfLanguageName{american}{\@numspell@lang@notsupported@false\numspell@US}{}% + \IfLanguageName{usenglish}{\@numspell@lang@notsupported@false\numspell@US}{}% + \IfLanguageName{USenglish}{\@numspell@lang@notsupported@false\numspell@US}{}% \IfLanguageName{magyar}{\@numspell@lang@notsupported@false\def\numspell@langname{hu}}{}% \IfLanguageName{hungarian}{\@numspell@lang@notsupported@false\def\numspell@langname{hu}}{}% \IfLanguageName{german}{\@numspell@lang@notsupported@false\def\numspell@langname{de}}{}% \IfLanguageName{ngerman}{\@numspell@lang@notsupported@false\def\numspell@langname{de}}{}% \IfLanguageName{french}{\@numspell@lang@notsupported@false\def\numspell@langname{fr}}{}% \IfLanguageName{italian}{\@numspell@lang@notsupported@false\def\numspell@langname{it}}{}% - \if@numspell@lang@notsupported@\PackageWarning{numspell}{Not supported language: \languagename}\fi% + \if@numspell@lang@notsupported@\PackageWarning{numspell}{\languagename\space is not supported language in numspell}\fi% } %% ------------------------- %% Loading language packages %% ------------------------- %% -\AtEndPreamble{% -\newif\if@numspell@lang@loaded@ -\ifdefined\dateenglish\RequirePackage{numspell-english}\@numspell@lang@loaded@true\fi% -\ifdefined\datebritish\RequirePackage{numspell-english}\@numspell@lang@loaded@true\fi% -\ifdefined\dateukenglish\RequirePackage{numspell-english}\@numspell@lang@loaded@true\fi% -\ifdefined\dateUKenglish\RequirePackage{numspell-english}\@numspell@lang@loaded@true\fi% -\ifdefined\dateamerican\RequirePackage{numspell-english}\@numspell@lang@loaded@true\fi% -\ifdefined\dateusenglish\RequirePackage{numspell-english}\@numspell@lang@loaded@true\fi% -\ifdefined\dateUSenglish\RequirePackage{numspell-english}\@numspell@lang@loaded@true\fi% -\ifdefined\datemagyar\RequirePackage{numspell-magyar}\@numspell@lang@loaded@true\fi% -\ifdefined\datehungarian\RequirePackage{numspell-magyar}\@numspell@lang@loaded@true\fi% -\ifdefined\dategerman\RequirePackage{numspell-german}\@numspell@lang@loaded@true\fi% -\ifdefined\datengerman\RequirePackage{numspell-german}\@numspell@lang@loaded@true\fi% -\ifdefined\datefrench\RequirePackage{numspell-french}\@numspell@lang@loaded@true\fi% -\ifdefined\dateitalian\RequirePackage{numspell-italian}\@numspell@lang@loaded@true\fi% -\if@numspell@lang@loaded@\else\RequirePackage{numspell-english}\fi% +\AddToHook{begindocument/before}{ +\RequirePackage{numspell-english} +\ifdefined\datemagyar\RequirePackage{numspell-magyar}\fi% +\ifdefined\datehungarian\RequirePackage{numspell-magyar}\fi% +\ifdefined\dategerman\RequirePackage{numspell-german}\fi% +\ifdefined\datengerman\RequirePackage{numspell-german}\fi% +\ifdefined\datefrench\RequirePackage{numspell-french}\fi% +\ifdefined\dateitalian\RequirePackage{numspell-italian}\fi% } %% --------------------------------- |