diff options
author | Karl Berry <karl@freefriends.org> | 2020-04-11 22:20:38 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2020-04-11 22:20:38 +0000 |
commit | a0fc5a65fc2886b3bd8a04e94db45c2f9f126d24 (patch) | |
tree | 4106d1450864fc4c39fe8f1f1ac456f210c21157 /Master/texmf-dist | |
parent | ab92e63936783c8aaee1aa7d8b665db287565e96 (diff) |
acronym (11apr20)
git-svn-id: svn://tug.org/texlive/trunk@54651 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist')
-rw-r--r-- | Master/texmf-dist/doc/latex/acronym/CHANGES | 13 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/acronym/README | 10 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/acronym/acronym.pdf | bin | 275685 -> 275707 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/latex/acronym/acrotest.tex | 4 | ||||
-rw-r--r-- | Master/texmf-dist/source/latex/acronym/acronym.dtx | 73 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/acronym/acronym.sty | 57 |
6 files changed, 100 insertions, 57 deletions
diff --git a/Master/texmf-dist/doc/latex/acronym/CHANGES b/Master/texmf-dist/doc/latex/acronym/CHANGES index 13914c24e79..95a9095483f 100644 --- a/Master/texmf-dist/doc/latex/acronym/CHANGES +++ b/Master/texmf-dist/doc/latex/acronym/CHANGES @@ -1,10 +1,21 @@ +Version 1.47 (Apr 2020) + +- Fixed \Iac macro expansion bug +-- Tobias Oetiker +- Fixed regression in commands for capitalisation +-- Marcus Meeßen +- Fixed bug were output depends on the position of the list of acronyms +-- Marcus Meeßen +- Fixed \Iac hyperlink nesting +-- Marcus Meeßen + Version 1.46 (Mar 2020) - Fix merge error Version 1.45 (Mar 2020) -- Fixed hyperref and "missing aux" regressions +- Fixed hyperref regression and the longstanding "missing aux" bug. -- Marcus Meeßen Version 1.44 (Feb 2020) diff --git a/Master/texmf-dist/doc/latex/acronym/README b/Master/texmf-dist/doc/latex/acronym/README index bd6e3debaf9..d60f9eaadb3 100644 --- a/Master/texmf-dist/doc/latex/acronym/README +++ b/Master/texmf-dist/doc/latex/acronym/README @@ -16,11 +16,11 @@ Note that acronym requires the 'suffix' package. You can find it on CTAN:macros/latex/contrib/bigfoot/ Files of the `acronym' package: - README This file - acronym.dtx Sourcecode, example file & documentation - acronym.ins Installation script generating the source and an example - acronym.pdf PDF Version of the Docs - CHANGES list of changes + README This file + acronym.dtx Sourcecode, example file & documentation + acronym.ins Installation script generating the source and an example + acronym.pdf PDF Version of the Docs + CHANGES list of changes If you run into trouble or would like to contribute, please use diff --git a/Master/texmf-dist/doc/latex/acronym/acronym.pdf b/Master/texmf-dist/doc/latex/acronym/acronym.pdf Binary files differindex 411480df9f2..b65f18794c1 100644 --- a/Master/texmf-dist/doc/latex/acronym/acronym.pdf +++ b/Master/texmf-dist/doc/latex/acronym/acronym.pdf diff --git a/Master/texmf-dist/doc/latex/acronym/acrotest.tex b/Master/texmf-dist/doc/latex/acronym/acrotest.tex index ff6944baff1..f7fa973a991 100644 --- a/Master/texmf-dist/doc/latex/acronym/acrotest.tex +++ b/Master/texmf-dist/doc/latex/acronym/acrotest.tex @@ -71,7 +71,8 @@ neutrinoless double beta decay. \subsection{Some testing fundamentals} When testing \acp{IC}, one typically wants to identify functional blocks to be tested separately. The latter are commonly indicated as -\acp{BUT}. To test a \ac{BUT} requires defining a testing strategy\dots +\acp{BUT}. To test a \ac{BUT} requires defining a testing strategy\dots{} +\Iac{IC} popped up unexpectedly. \section{Acronyms} \begin{acronym}[TDMA] @@ -90,6 +91,7 @@ blocks to be tested separately. The latter are commonly indicated as \acro{IC}{Integrated Circuit}% \acro{BUT}{Block Under Test}% \acrodefplural{BUT}{Blocks Under Test}% + \acroindefinite{IC}{an}{an} \end{acronym} \end{document} diff --git a/Master/texmf-dist/source/latex/acronym/acronym.dtx b/Master/texmf-dist/source/latex/acronym/acronym.dtx index 31211759a80..f7d8e8eabd2 100644 --- a/Master/texmf-dist/source/latex/acronym/acronym.dtx +++ b/Master/texmf-dist/source/latex/acronym/acronym.dtx @@ -35,7 +35,7 @@ %</driver> % \fi % -% \CheckSum{1522} +% \CheckSum{1526} % %% \CharacterTable %% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z @@ -82,6 +82,7 @@ % \DoNotIndex{\textbf, \textsf, \textsmaller, \textsuperscript, \the} % \DoNotIndex{\usepackage} % +% \changes{v1.47}{2020/04/10}{Tobi Oetiker and Marcus Meeßen \cmd{hskip} Fixed several bugs in macros that use capitalisation, a bug were the output depends on the position of the list of acronyms, and a bug were nested hyperlinks could cause errors.} % \changes{v1.46}{2020/03/13}{Tobi Oetiker \cmd{hskip} Fixed miss merge} % \changes{v1.45}{2020/03/13}{Marcus Meeßen \cmd{hskip} Fixed hyperref and "missing aux" regressions.} % \changes{v1.44}{2020/02/07}{Marcus Meeßen \cmd{hskip} Added the |printonlyreused| option, which allows to automatically exclude acronyms from the list of acronyms if they are used only once} @@ -636,7 +637,8 @@ neutrinoless double beta decay. \subsection{Some testing fundamentals} When testing \acp{IC}, one typically wants to identify functional blocks to be tested separately. The latter are commonly indicated as -\acp{BUT}. To test a \ac{BUT} requires defining a testing strategy\dots +\acp{BUT}. To test a \ac{BUT} requires defining a testing strategy\dots{} +\Iac{IC} popped up unexpectedly. \section{Acronyms} \begin{acronym}[TDMA] @@ -655,6 +657,7 @@ blocks to be tested separately. The latter are commonly indicated as \acro{IC}{Integrated Circuit}% \acro{BUT}{Block Under Test}% \acrodefplural{BUT}{Blocks Under Test}% + \acroindefinite{IC}{an}{an} \end{acronym} \end{document} @@ -679,8 +682,8 @@ blocks to be tested separately. The latter are commonly indicated as % First we test that we got the right format and name the package. % \begin{macrocode} \NeedsTeXFormat{LaTeX2e}[1999/12/01] -\ProvidesPackage{acronym}[2020/03/13 - v1.46 +\ProvidesPackage{acronym}[2020/04/17 + v1.47 Support for acronyms (Tobias Oetiker)] \RequirePackage{suffix,xstring} % \end{macrocode} @@ -1039,7 +1042,6 @@ blocks to be tested separately. The latter are commonly indicated as % acronyms is in the front matter of the document. % \begin{macrocode} \newcommand*{\AC@logged}[1]{% - \acronymused{#1}% mark it as used in the current run too \@bsphack \protected@write\@auxout{}{\string\acronymused{#1}}% \@esphack} @@ -1080,9 +1082,8 @@ blocks to be tested separately. The latter are commonly indicated as % Internal commands for making a first letter upper case. % \begin{macrocode} \newcommand{\@firstupper}[1]{% - \StrLeft{#1}{1}[\firstletter]% - \StrGobbleLeft{#1}{1}[\remainder]% - \MakeUppercase\firstletter\remainder% + \StrSplit{#1}{1}{\head}{\tail}% + \MakeUppercase\head\tail% } % \end{macrocode} % \end{macro} @@ -1340,7 +1341,7 @@ blocks to be tested separately. The latter are commonly indicated as \newcommand\AC@acroindefinite[3]{ \@bsphack \protected@write\@auxout{}% - {\string\newacroindefinite{#1}{\string\AC@hyperlink{#1}{#2}}{#3}}% + {\string\newacroindefinite{#1}{#2}{#3}}% \@esphack } % \end{macrocode} @@ -1438,7 +1439,9 @@ blocks to be tested separately. The latter are commonly indicated as \fi } \newcommand*\AC@Aclp[1]{% - \@firstupper\expandafter{\AC@aclp{#1}}% + \AC@uppertrue% + \AC@aclp{#1}% + \AC@upperfalse% } \newcommand*\AC@acsp[1]{% \ifcsname fn@#1@PS\endcsname @@ -1465,6 +1468,16 @@ blocks to be tested separately. The latter are commonly indicated as % \end{macrocode} % \end{macro} % +% \begin{macro}{\ifAC@upper} +% If an acronym needs to be capitalized, this flag is used to indicate +% this at an appropriate point in the code. In that case, the firstupper +% command will be called at a time when the acronym is expandable, otherwise +% the xstring command will not work properly. +% \begin{macrocode} +\newif\ifAC@upper +% \end{macrocode} +% \end{macro} +% % \begin{macro}{\AC@get} % If the acronym is undefined, the internal macro \cmd{\AC@get} % warns the user by printing the name in bold with an exclamation @@ -1475,12 +1488,17 @@ blocks to be tested separately. The latter are commonly indicated as % saved in \fnacro. % \begin{macrocode} \newcommand*\AC@get[3]{% - \ifx#1\relax - \PackageWarning{acronym}{Acronym `#3' is not defined}% - \textbf{#3!}% + \ifx#1\relax + \PackageWarning{acronym}{Acronym `#3' is not defined}% + \textbf{#3!}% + \else + \ifAC@upper + \@firstupper{\expandafter#2#1}% \else - \expandafter#2#1% - \fi} + \expandafter#2#1% + \fi + \fi +} % \end{macrocode} % \end{macro} % @@ -1500,7 +1518,9 @@ blocks to be tested separately. The latter are commonly indicated as % \end{macrocode} % \begin{macrocode} \newcommand*\AC@Acl[1]{% - \@firstupper\expandafter{\AC@acl{#1}}% + \AC@uppertrue% + \AC@acl{#1}% + \AC@upperfalse% } % \end{macrocode} % \end{macro} @@ -1780,25 +1800,26 @@ blocks to be tested separately. The latter are commonly indicated as % \end{macrocode} % \begin{macrocode} \newcommand*{\@iaci}[1]{% - \ifcsname fn@#1@IL\endcsname - \ifAC@dua - \csname fn@#1@IL\endcsname% - \else - \expandafter\ifx\csname AC@\AC@prefix#1\endcsname\AC@used% + \ifcsname fn@#1@IL\endcsname + \ifAC@dua + \csname fn@#1@IL\endcsname% + \else + \expandafter\ifx\csname AC@\AC@prefix#1\endcsname\AC@used% \csname fn@#1@IS\endcsname% \else \csname fn@#1@IL\endcsname% \fi - \fi - \else - a% - \fi + \fi + \else + a% + \fi } \newcommand*{\@iac}[2][\AC@linebreakpenalty]{% \@iaci{#2} \ifAC@starred\ac*[#1]{#2}\else\ac[#1]{#2}\fi% } \newcommand*{\@Iac}[2][\AC@linebreakpenalty]{% - \@firstupper{\@iaci{#2}} \ifAC@starred\ac*[#1]{#2}\else\ac[#1]{#2}\fi% + \@firstupper{\@iaci{#2}}\space% + \ifAC@starred\ac*[#1]{#2}\else\ac[#1]{#2}\fi% } % \end{macrocode} % \end{macro} diff --git a/Master/texmf-dist/tex/latex/acronym/acronym.sty b/Master/texmf-dist/tex/latex/acronym/acronym.sty index 134d97500b6..cd6f1cf2921 100644 --- a/Master/texmf-dist/tex/latex/acronym/acronym.sty +++ b/Master/texmf-dist/tex/latex/acronym/acronym.sty @@ -40,8 +40,8 @@ %% %% \NeedsTeXFormat{LaTeX2e}[1999/12/01] -\ProvidesPackage{acronym}[2020/03/13 - v1.46 +\ProvidesPackage{acronym}[2020/04/17 + v1.47 Support for acronyms (Tobias Oetiker)] \RequirePackage{suffix,xstring} \newif\ifAC@footnote @@ -172,7 +172,6 @@ \newcommand*\AC@used{@<>@<>@} \newcommand{\AC@populated}{} \newcommand*{\AC@logged}[1]{% - \acronymused{#1}% mark it as used in the current run too \@bsphack \protected@write\@auxout{}{\string\acronymused{#1}}% \@esphack} @@ -199,9 +198,8 @@ \fi% } \newcommand{\@firstupper}[1]{% - \StrLeft{#1}{1}[\firstletter]% - \StrGobbleLeft{#1}{1}[\remainder]% - \MakeUppercase\firstletter\remainder% + \StrSplit{#1}{1}{\head}{\tail}% + \MakeUppercase\head\tail% } \ifAC@noacroprefix \newcommand*\AC@prefix{} @@ -344,7 +342,7 @@ \newcommand\AC@acroindefinite[3]{ \@bsphack \protected@write\@auxout{}% - {\string\newacroindefinite{#1}{\string\AC@hyperlink{#1}{#2}}{#3}}% + {\string\newacroindefinite{#1}{#2}{#3}}% \@esphack } \newcommand*\newacroplural[1]{% @@ -399,7 +397,9 @@ \fi } \newcommand*\AC@Aclp[1]{% - \@firstupper\expandafter{\AC@aclp{#1}}% + \AC@uppertrue% + \AC@aclp{#1}% + \AC@upperfalse% } \newcommand*\AC@acsp[1]{% \ifcsname fn@#1@PS\endcsname @@ -409,19 +409,27 @@ \fi } \newif\ifAC@starred +\newif\ifAC@upper \newcommand*\AC@get[3]{% - \ifx#1\relax - \PackageWarning{acronym}{Acronym `#3' is not defined}% - \textbf{#3!}% + \ifx#1\relax + \PackageWarning{acronym}{Acronym `#3' is not defined}% + \textbf{#3!}% + \else + \ifAC@upper + \@firstupper{\expandafter#2#1}% \else - \expandafter#2#1% - \fi} + \expandafter#2#1% + \fi + \fi +} \newcommand*\AC@acs[1]{% \mbox{\expandafter\AC@get\csname fn@#1\endcsname\@firstoftwo{#1}}} \newcommand*\AC@acl[1]{% \expandafter\AC@get\csname fn@#1\endcsname\@secondoftwo{#1}} \newcommand*\AC@Acl[1]{% - \@firstupper\expandafter{\AC@acl{#1}}% + \AC@uppertrue% + \AC@acl{#1}% + \AC@upperfalse% } \newcommand*{\acs}{\AC@starredfalse\protect\acsa}% \WithSuffix\newcommand\acs*{\AC@starredtrue\protect\acsa}% @@ -581,25 +589,26 @@ \newcommand*{\Iac}{\AC@starredfalse\protect\@Iac}% \WithSuffix\newcommand\Iac*{\AC@starredtrue\protect\@Iac}% \newcommand*{\@iaci}[1]{% - \ifcsname fn@#1@IL\endcsname - \ifAC@dua - \csname fn@#1@IL\endcsname% - \else - \expandafter\ifx\csname AC@\AC@prefix#1\endcsname\AC@used% + \ifcsname fn@#1@IL\endcsname + \ifAC@dua + \csname fn@#1@IL\endcsname% + \else + \expandafter\ifx\csname AC@\AC@prefix#1\endcsname\AC@used% \csname fn@#1@IS\endcsname% \else \csname fn@#1@IL\endcsname% \fi - \fi - \else - a% - \fi + \fi + \else + a% + \fi } \newcommand*{\@iac}[2][\AC@linebreakpenalty]{% \@iaci{#2} \ifAC@starred\ac*[#1]{#2}\else\ac[#1]{#2}\fi% } \newcommand*{\@Iac}[2][\AC@linebreakpenalty]{% - \@firstupper{\@iaci{#2}} \ifAC@starred\ac*[#1]{#2}\else\ac[#1]{#2}\fi% + \@firstupper{\@iaci{#2}}\space% + \ifAC@starred\ac*[#1]{#2}\else\ac[#1]{#2}\fi% } \newcommand*{\acsp}{\AC@starredfalse\protect\acspa}% \WithSuffix\newcommand\acsp*{\AC@starredtrue\protect\acspa}% |