summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/fmtcount/fmtcount.dtx
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2020-01-29 03:01:39 +0000
committerNorbert Preining <norbert@preining.info>2020-01-29 03:01:39 +0000
commit0d9a20b65398ec99149b5c3d700e78f891b90842 (patch)
treeca173f2c5bbd75b090b58afdc71e6dc3ed1a1f3a /macros/latex/contrib/fmtcount/fmtcount.dtx
parentfdd916a9e0d94bbf49f74c3b796e1bab88964d4c (diff)
CTAN sync 202001290301
Diffstat (limited to 'macros/latex/contrib/fmtcount/fmtcount.dtx')
-rw-r--r--macros/latex/contrib/fmtcount/fmtcount.dtx243
1 files changed, 148 insertions, 95 deletions
diff --git a/macros/latex/contrib/fmtcount/fmtcount.dtx b/macros/latex/contrib/fmtcount/fmtcount.dtx
index 20d2f75195..910ff33571 100644
--- a/macros/latex/contrib/fmtcount/fmtcount.dtx
+++ b/macros/latex/contrib/fmtcount/fmtcount.dtx
@@ -1,11 +1,11 @@
%\iffalse
% fmtcount.dtx generated using makedtx version 1.2 (c) Nicola Talbot
% Command line args:
-% -author "Nicola Talbot and Vincent Belaïche"
% -doc "fmtcount-manual.tex"
+% -author "Nicola Talbot and Vincent Belaïche"
% -src "(.+)\.(sty|def)$=>\1.\2"
% fmtcount
-% Created on 2017/12/26 22:09
+% Created on 2020/1/28 8:17
%\fi
%\iffalse
%<*package>
@@ -28,7 +28,7 @@
%\fi
% \iffalse
% Doc-Source file to use with LaTeX2e
-% Copyright (C) 2017 Nicola Talbot and Vincent Belaïche, all rights reserved.
+% Copyright (C) 2020 Nicola Talbot and Vincent Belaïche, all rights reserved.
% \fi
% \iffalse
%<*driver>
@@ -77,7 +77,7 @@
pdftitle={fmtcount.sty: Displaying the Values of LaTeX Counters},
pdfkeywords={LaTeX,counter}]{hyperref}
-\CheckSum{10334}
+\CheckSum{10311}
\doxitem{Option}{option}{options}
@@ -104,7 +104,7 @@
% \url{www.dickimaw-books.com}
% \and
% Vincent Bela\"iche}
-% \date{2017-12-26 (version 3.05)\relax
+% \date{2020-01-30 (version 3.06)\relax
%}
% \maketitle
% \tableofcontents
@@ -135,8 +135,8 @@
%is used to format the st, nd, rd, th bit. By default the ordinal is
%formatted as a superscript, if the package option \pkgopt{level} is
%used, it is level with the text. For example, if the current section
-%is 3, then \verb"\ordinal{section}" will produce the output:
-%3\textsuperscript{rd}. Note that the optional argument \meta{gender}
+%is \arabic{section}, then \verb"\ordinal{section}" will produce the output:
+%\ordinal{section}. Note that the optional argument \meta{gender}
%occurs \emph{at the end}. This argument may only take one of
%the following values: \texttt{m} (masculine), \texttt{f}
%(feminine) or \texttt{n} (neuter.) If \meta{gender} is omitted,
@@ -155,24 +155,20 @@
%\end{definition}
%to access \styfmt{fmtcount}'s version of \cs{ordinal}, and use
%\cs{ordinal} to use \cls{memoir}'s version of that command.
-%
-%\item As with all commands which have an optional argument as the
-%last argument, if the optional argument is omitted, any spaces
-%following the final argument will be ignored. Whereas, if the
-%optional argument is present, any spaces following the optional
-%argument won't be ignored. so \verb"\ordinal{section} !"
-%will produce: 3\textsuperscript{rd}! whereas
-% \verb"\ordinal{section}[m] !" will produce:
-%3\textsuperscript{rd} !
+%\item When the \oarg{gender} optional argument is omitted, no ignoring of spaces
+% following the final argument occurs. So both
+% \verb"\ordinal{section}"\textvisiblespace\verb"!" and
+% \verb"\ordinal{section}[m]"\textvisiblespace\verb"!" will produce:
+% \ordinal{section}\textvisiblespace!, where \textvisiblespace\ denotes a space. See
+% \S~\ref{sec:tailing-oarg}.
%\end{enumerate}
%
%The commands below only work for numbers in the range 0~to~99999.
%\begin{definition}[\DescribeMacro{\ordinalnum}]
%\cs{ordinalnum}\marg{n}\oarg{gender}
%\end{definition}
-%This is like \cs{ordinal} but takes an actual number rather than a
-%counter as the argument. For example: \verb"\ordinalnum{3}" will
-%produce: 3\textsuperscript{rd}.
+%This is like \cs{ordinal} but takes an actual number rather than a counter as the argument. For example:
+%\verb"\ordinalnum{"\texttt{\arabic{section}}\verb"}" will produce: \ordinal{section}.
%
%\begin{definition}[\DescribeMacro{\numberstring}]
%\cs{numberstring}\marg{counter}\oarg{gender}
@@ -186,7 +182,7 @@
%\end{definition}
%This does the same as \cs{numberstring}, but with initial letters in
%uppercase. For example, \verb"\Numberstring{section}" will produce:
-%Three.
+%\Numberstring{section}.
%
%\begin{definition}[\DescribeMacro{\NUMBERstring}]
%\cs{NUMBERstring}\marg{counter}\oarg{gender}
@@ -225,7 +221,7 @@
%\end{definition}
%This does the same as \cs{ordinalstring}, but with initial letters in
%uppercase. For example, \verb"\Ordinalstring{section}" will produce:
-%Third.
+%\Ordinalstring{section}.
%
%\begin{definition}[\DescribeMacro{\ORDINALstring}]
%\cs{ORDINALstring}\marg{counter}\oarg{gender}
@@ -243,9 +239,10 @@
%\cs{ORDINALstringnum}\marg{n}\oarg{gender}
%\end{definition}
%These macros work like \cs{ordinalstring}, \cs{Ordinalstring} and
-%\cs{ORDINALstring}, respectively, but take an actual number rather
-%than a counter as the argument. For example,
-%\verb"\ordinalstringnum{3}" will produce: third.
+%\cs{ORDINALstring}, respectively, but take an actual number rather than a
+%counter as the argument. For example,
+%\verb"\ordinalstringnum{"\texttt{\arabic{section}}\verb"}" will produce:
+%\ordinalstring{section}.
%
%\changes{v.1.09}{21 Apr 2007}{store facility added}
%As from version 1.09, textual representations can be stored for
@@ -328,14 +325,15 @@
%\begin{definition}[\DescribeMacro{\binary}]
%\cs{binary}\marg{counter}
%\end{definition}
-%This will print the value of \meta{counter} as a binary number.
-%E.g.\ \verb"\binary{section}" will produce: 11. The declaration
+%This will print the value of \meta{counter} as a binary number. E.g.\
+%\verb"\binary{section}" will produce: \binary{section}. The declaration
%\begin{definition}[\DescribeMacro{\padzeroes}]
%\cs{padzeroes}\oarg{n}
%\end{definition}
-%will ensure numbers are written to \meta{n} digits, padding with
-%zeroes if necessary. E.g.\ \verb"\padzeroes[8]\binary{section}" will
-%produce: 00000011. The default value for \meta{n} is 17.
+%will ensure numbers are written to \meta{n} digits, padding with zeroes if
+%necessary. E.g.\ \verb"\padzeroes"\discretionary{}{}{}\verb"[8]\binary{section}"
+%will produce: \padzeroes[8]\binary{section}. The default value for \meta{n} is
+%17.
%
%\begin{definition}[\DescribeMacro{\binarynum}]
%\cs{binary}\marg{n}
@@ -370,32 +368,43 @@
%will be padded with zeroes if necessary, depending on whether
%\cs{padzeroes} has been used.
%
-%\begin{definition}[\DescribeMacro{\Hexadecimal}]
-%\cs{Hexadecimal}\marg{counter}
+%\begin{definition}[\DescribeMacro{\HEXADecimal}]
+%\cs{HEXADecimal}\marg{counter}
%\end{definition}
%This does the same thing, but uses uppercase characters, e.g.\
-%\verb"\Hexadecimal{mycounter}" will produce: 7D.
+%\verb"\HEXADecimal{mycounter}" will produce: 7D.
+%
+%\DescribeMacro{\Hexadecimal}The macro \cs{Hexadecimal} is a deprecated alias of
+%\cs{HEXADecimal}. Its name was confusing so it was
+%changed. See~\ref{sec:macro-naming}.
+%
%
%\begin{definition}[\DescribeMacro{\hexadecimalnum}]
%\cs{hexadecimalnum}\marg{n}
%\end{definition}
%
-%\begin{definition}[\DescribeMacro{\Hexadecimalnum}]
-%\cs{Hexadecimalnum}\marg{n}
+%\begin{definition}[\DescribeMacro{\HEXADecimalnum}]
+%\cs{HEXADecimalnum}\marg{n}
%\end{definition}
%These are like \cs{hexadecimal} and \cs{Hexadecimal}
%but take an actual number rather than a counter as the
%argument. For example: \verb"\hexadecimalnum{125}" will
-%produce: 7d, and \verb"\Hexadecimalnum{125}" will
+%produce: 7d, and \verb"\HEXADecimalnum{125}" will
%produce: 7D.
%
+%\DescribeMacro{\Hexadecimalnum}The macro \cs{Hexadecimalnum} is a deprecated
+%alias of \cs{HEXADecimalnum}. Its name was confusing so it was changed.
+%See~\ref{sec:macro-naming}.
+%
+%
%\begin{definition}[\DescribeMacro{\decimal}]
%\cs{decimal}\marg{counter}
%\end{definition}
-%This is similar to \cs{arabic} but the number can be padded with
-%zeroes depending on whether \cs{padzeroes} has been used. For
-%example: \verb"\padzeroes[8]\decimal{section}" will produce:
-%00000005.
+%This is similar to \cs{arabic} but the number can be padded with zeroes
+%depending on whether \cs{padzeroes} has been used. For example:
+%\verb"\padzeroes[8]\decimal{section}" will produce:
+%\padzeroes[8]\decimal{section} still assuming current section is
+%section~\arabic{section}.
%
%\begin{definition}[\DescribeMacro{\decimalnum}]
%\cs{decimalnum}\marg{n}
@@ -407,8 +416,8 @@
%\begin{definition}[\DescribeMacro{\aaalph}]
%\cs{aaalph}\marg{counter}
%\end{definition}
-%This will print the value of \meta{counter} as: a b \ldots\ z aa bb
-%\ldots\ zz etc. For example, \verb"\aaalpha{mycounter}" will
+%This will print the value of \meta{counter} as: a b \ldots\ z aa bb \ldots\ zz
+%etc. For example, \verb"\aaalpha"\discretionary{}{}{}\verb"{mycounter}" will
%produce: uuuuu if \texttt{mycounter} is set to 125.
%
%\begin{definition}[\DescribeMacro{\AAAlph}]
@@ -819,7 +828,7 @@
%La valeur par défaut de cette option est \og\texttt{le}\fg. Il s'agit de la terminaison ajoutée à \og
%mil\fg\ pour former le pluriel, c'est à dire \og mille\fg, cette option ne sert pas à grand chose sauf dans
%l'éventualité où ce pluriel serait francisé un jour --- à dire vrai si cela se produisait une alternance
-%mille/milles est plus vraisemblable, car \og mille\fg\ est plus fréquent que \og mille\fg\ et que les
+%mille/milles est plus vraisemblable, car \og mille\fg\ est plus fréquent que \og mil\fg\ et que les
%pluriels francisés sont formés en ajoutant \og s\fg\ à la forme la plus fréquente, par exemple \og
%blini/blinis\fg, alors que \og blini\fg\ veut dire \og crêpes\fg\ (au pluriel).
%
@@ -880,9 +889,56 @@
%
%\end{itemize}
%
+%\section{Miscellaneous}
+%\label{sec:misc}
+%
+%\subsection{Handling of spaces with tailing optional argument}
+%\label{sec:tailing-oarg}
+%
+%Quite some of the commands in \styfmt{fmtcount} have a tailing optional argument, notably a \oarg{gender}
+%argument, which is due to historical reasons, and is a little unfortunate.
+%
+%When the tailing optional argument is omitted, then any subsequent space will:
+%\begin{itemize}
+%\item \texttt{not} be gobbled if the command make some typset output, like \cs{ordinal} or \cs{numbestring}, and
+%\item be gobbled if the command stores a number into a label like \cs{storeordinalnum} or
+% \cs{storenumberstring}, or make some other border effect like \cs{padzeroes} without any typeset output.
+%\end{itemize}
+%
+%So (where we use visible spaces ``\verb*! !'' to demonstrate the point):
+%\begin{itemize}
+%\item ``x\cs{odinalnum\{2\}}\verb*! !\texttt{x}'' will be typeset to ``x\ordinalnum{2}\textvisiblespace x'', while
+%\item ``x\cs{storeodinalnum\{mylabel\}\{2\}}\verb*! !\texttt{x}'' will be typeset to ``xx''.
+%\end{itemize}
+%
+%The reason for this design choice is that the commands like like \cs{ordinal} or \cs{numbestring} are usually
+%inserted in the flow of text, and one usually does not want subsequent spaces gobbled, while the commands like
+%\cs{storeordinalnum} or \cs{storenumberstring} usually stands on their own line, and one usually does not want
+%the tailing end-of-line to produce an extra-space.
+%
+%\subsection{Macro naming conventions}
+%\label{sec:macro-naming}
+%
+%Macros that refer to upper-casing have upper case only in the main part of their name. That is to say the
+%words ``store'', ``string'' or ``num'' are not upper-cased for instance in \cs{storeORDINALstringnum},
+%\cs{storeOrdinalstringnum} or in \cs{NUMBERstringnum}.
+%
+%Furthermore, when upper-casing all the number letters is considered, the main part of the name is:
+%\begin{itemize}
+%\item all in upper-case when it consist of a single word that is not composed of a prefix+radix, for instance
+% ``ORDINAL'' or ``NUMBER'', and
+%\item with the prefix all in upper-case, and only the first letter of the radix in upper-case for words that
+% consist of a prefix+radix, for instance ``HEXADecimal'' or ``AAAlph'' because they can be considered as a
+% prefix+radix construct ``hexa+decimal'' or ``aa+alph''.
+%\end{itemize}
+%
+%Observance of this rule is the reason why macros \cs{Hexadecimal} and \cs{Hexadecimalnum} were respectively
+%renamed as \cs{HEXADecimal} and \cs{HEXADecimalnum} from v3.06.
+%
+%
%\section{Acknowledgements}
%
-%I would like to thank all the people who have provided translations.
+%I would like to thank all the people who have provided translations and made bug reports.
%
%\section{Troubleshooting}
%
@@ -895,6 +951,7 @@
%
%% Local Variables:
%% coding: utf-8
+%% compile-command: "make -C ../dist fmtcount.pdf"
%% End:
%
%\StopEventually{}
@@ -3558,7 +3615,7 @@ z\'ero%
% German definitions (thank you to K. H. Fricke for supplying
% this information)
% \begin{macrocode}
-\ProvidesFCLanguage{german}[2016/01/12]%
+\ProvidesFCLanguage{german}[2018/06/17]%
% \end{macrocode}
% Define macro that converts a number or count register (first
% argument) to an ordinal, and stores the result in the
@@ -4043,13 +4100,16 @@ z\'ero%
}%
\global\let\@@numberunderhundredthgerman\@@numberunderhundredthgerman
% \end{macrocode}
+%\changes{3.06}{2018/06/17}{Use \cs{@orgargctr} counter in order to fix bug
+%\href{https://github.com/nlct/fmtcount/issues/33}{\#33}.}
% \begin{macrocode}
\newcommand*\@@ordinalstringgerman[2]{%
-\ifnum#1>99999\relax
+\@orgargctr=#1\relax
+\ifnum\@orgargctr>99999\relax
\PackageError{fmtcount}{Out of range}%
{This macro only works for values less than 100000}%
\else
- \ifnum#1<0\relax
+ \ifnum\@orgargctr<0\relax
\PackageError{fmtcount}{Negative numbers not permitted}%
{This macro does not work for negative numbers, however
you can try typing "minus" first, and then pass the modulus of
@@ -4057,7 +4117,7 @@ z\'ero%
\fi
\fi
\def#2{}%
-\@strctr=#1\relax \divide\@strctr by 1000\relax
+\@strctr=\@orgargctr\divide\@strctr by 1000\relax
\ifnum\@strctr>1\relax
% \end{macrocode}
% \#1 is $\geq 2000$, \cs{@strctr} now contains the number of thousands
@@ -4066,7 +4126,7 @@ z\'ero%
% \end{macrocode}
% is that it, or is there more?
% \begin{macrocode}
- \@tmpstrctr=#1\relax \@FCmodulo{\@tmpstrctr}{1000}%
+ \@tmpstrctr=\@orgargctr\@FCmodulo{\@tmpstrctr}{1000}%
\ifnum\@tmpstrctr=0\relax
\eappto#2{\@thousandth}%
\else
@@ -4077,14 +4137,14 @@ z\'ero%
% \#1 lies in range [1000,1999]
% \begin{macrocode}
\ifnum\@strctr=1\relax
- \ifnum#1=1000\relax
+ \ifnum\@orgargctr=1000\relax
\eappto#2{\@thousandth}%
\else
\eappto#2{\eintausend}%
\fi
\fi
\fi
-\@strctr=#1\relax
+\@strctr=\@orgargctr
\@FCmodulo{\@strctr}{1000}%
\divide\@strctr by 100\relax
\ifnum\@strctr>1\relax
@@ -4092,7 +4152,7 @@ z\'ero%
% now dealing with number in range [200,999]
% is that it, or is there more?
% \begin{macrocode}
- \@tmpstrctr=#1\relax \@FCmodulo{\@tmpstrctr}{100}%
+ \@tmpstrctr=\@orgargctr \@FCmodulo{\@tmpstrctr}{100}%
\ifnum\@tmpstrctr=0\relax
\ifnum\@strctr=1\relax
\eappto#2{\@hundredth}%
@@ -4108,11 +4168,11 @@ z\'ero%
% dealing with number in range [100,199]
% is that it, or is there more?
% \begin{macrocode}
- \@tmpstrctr=#1\relax \@FCmodulo{\@tmpstrctr}{100}%
+ \@tmpstrctr=\@orgargctr \@FCmodulo{\@tmpstrctr}{100}%
\ifnum\@tmpstrctr=0\relax
\eappto#2{\@hundredth}%
\else
- \ifnum#1>1000\relax
+ \ifnum\@orgargctr>1000\relax
\appto#2{einhundert}%
\else
\eappto#2{\einhundert}%
@@ -4120,9 +4180,9 @@ z\'ero%
\fi
\fi
\fi
-\@strctr=#1\relax
+\@strctr=\@orgargctr
\@FCmodulo{\@strctr}{100}%
-\ifthenelse{\@strctr=0 \and #1>0}{}{%
+\ifthenelse{\@strctr=0 \and \@orgargctr>0 }{}{%
\@@numberunderhundredthgerman{\@strctr}{#2}%
}%
}%
@@ -7420,7 +7480,7 @@ this number}%
% This section deals with the code for |fmtcount.sty|
% \begin{macrocode}
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{fmtcount}[2017/12/24 v3.05]
+\ProvidesPackage{fmtcount}[2020/01/30 v3.06]
\RequirePackage{ifthen}
% \end{macrocode}
% \changes{3.01}{2014/12/03}{Use \styfmt{xkeyval} instead of \styfmt{keyval}, so that we do not get in trouble
@@ -7975,7 +8035,7 @@ italian}
\let\octalnum=\@octal
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\@@hexadecimalnum}
+%\begin{macro}{\@@hexadecimal}
% Converts number from 0 to 15 into lowercase hexadecimal notation.
% \begin{macrocode}
\newcommand*{\@@hexadecimal}[1]{%
@@ -7988,34 +8048,13 @@ italian}
% Converts a decimal number to a lowercase hexadecimal number,
% and displays it.
%\changes{3.02}{2016/01/08}{Made robust using \texttt{etoolbox} \cs{newrobustcmd}}
+%\changes{3.06}{2018/06/27}{Rename \cs{Hexadecimalnum} to \cs{HEXADecimalnum} and \cs{Hexadecimal} to
+% \cs{HEXADecimal} and factorize the code between \cs{HEXADecimalnum} and \cs{hexadecimalnum}.}
% \begin{macrocode}
-\newrobustcmd*{\@hexadecimal}[1]{%
- \@DT@padzeroestrue
- \@DT@loopN=\@vpt
- \@strctr=\@DT@loopN
- \whiledo{\@strctr<\c@padzeroesN}{0\advance\@strctr by \@ne}%
- \@strctr=65536\relax
- \@DT@X=#1\relax
- \loop
- \@DT@modctr=\@DT@X
- \divide\@DT@modctr by \@strctr
- \ifthenelse{\boolean{@DT@padzeroes}
- \and \(\@DT@modctr=0\)
- \and \(\@DT@loopN>\c@padzeroesN\)}
- {}{\@@hexadecimal\@DT@modctr}%
- \ifnum\@DT@modctr=0\else\@DT@padzeroesfalse\fi
- \multiply\@DT@modctr by \@strctr
- \advance\@DT@X by -\@DT@modctr
- \divide\@strctr by 16\relax
- \advance\@DT@loopN by \m@ne
- \ifnum\@strctr>\@ne
- \repeat
- \@@hexadecimal\@DT@X
-}
-\let\hexadecimalnum=\@hexadecimal
+\newrobustcmd*{\hexadecimalnum}{\@hexadecimalengine\@@hexadecimal}
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\@@Hexadecimalnum}
+%\begin{macro}{\@@Hexadecimal}
% Converts number from 0 to 15 into uppercase hexadecimal notation.
% \begin{macrocode}
\newcommand*{\@@Hexadecimal}[1]{%
@@ -8024,24 +8063,27 @@ italian}
}
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\Hexadecimalnum}
+%\begin{macro}{\HEXADecimalnum}
% Uppercase hexadecimal
%\changes{3.02}{2016/01/08}{Made robust using \texttt{etoolbox} \cs{newrobustcmd}}
+%\changes{3.06}{2018/06/27}{Rename \cs{Hexadecimalnum} to \cs{HEXADecimalnum} and \cs{Hexadecimal} to
+% \cs{HEXADecimal} and factorize the code between \cs{HEXADecimalnum} and \cs{hexadecimalnum}.}
% \begin{macrocode}
-\newrobustcmd*{\@Hexadecimal}[1]{%
+\newrobustcmd*{\HEXADecimalnum}{\@hexadecimalengine\@@Hexadecimal}
+\newcommand*{\@hexadecimalengine}[2]{%
\@DT@padzeroestrue
- \@DT@loopN=5\relax
+ \@DT@loopN=\@vpt
\@strctr=\@DT@loopN
\whiledo{\@strctr<\c@padzeroesN}{0\advance\@strctr by \@ne}%
\@strctr=65536\relax
- \@DT@X=#1\relax
+ \@DT@X=#2\relax
\loop
\@DT@modctr=\@DT@X
\divide\@DT@modctr by \@strctr
\ifthenelse{\boolean{@DT@padzeroes}
\and \(\@DT@modctr=0\)
- \and \(\@DT@loopN>\c@padzeroesN\)}%
- {}{\@@Hexadecimal\@DT@modctr}%
+ \and \(\@DT@loopN>\c@padzeroesN\)}
+ {}{#1\@DT@modctr}%
\ifnum\@DT@modctr=0\else\@DT@padzeroesfalse\fi
\multiply\@DT@modctr by \@strctr
\advance\@DT@X by -\@DT@modctr
@@ -8049,10 +8091,13 @@ italian}
\advance\@DT@loopN by \m@ne
\ifnum\@strctr>\@ne
\repeat
- \@@Hexadecimal\@DT@X
+ #1\@DT@X
}
-
-\let\Hexadecimalnum=\@Hexadecimal
+\def\Hexadecimalnum{%
+ \PackageWarning{fmtcount}{\string\Hexadecimalnum\space is deprecated, use \string\HEXADecimalnum\space
+ instead. The \string\Hexadecimalnum\space control sequence name is confusing as it can mislead in thinking
+ that only the 1st letter is upper-cased.}%
+ \HEXADecimalnum}
% \end{macrocode}
%\end{macro}
%\begin{macro}{\aaalphnum}
@@ -9155,12 +9200,12 @@ italian}
% compatibily with \texttt{glossaries}.}
% \begin{macrocode}
\providecommand*{\hexadecimal}[1]{%
- \@hexadecimal{\expandafter\expandafter\expandafter
+ \hexadecimalnum{\expandafter\expandafter\expandafter
\the\value{#1}}%
}
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\Hexadecimal}
+%\begin{macro}{\HEXADecimal}
% As above, but in upper case.
% \changes{3.02}{2016/01/08}{Suppress useless \cs{expandafter}'s and
% and use \cs{value} instead tweaking with \cs{csname}. Do not use any
@@ -9171,10 +9216,18 @@ italian}
% supposed to fully expand its argument, and place 3 \cs{expandafter}'s before \cs{the}\cs{value} for
% compatibily with \texttt{glossaries}.}
% \begin{macrocode}
-\providecommand*{\Hexadecimal}[1]{%
- \@Hexadecimal{\expandafter\expandafter\expandafter
+\providecommand*{\HEXADecimal}[1]{%
+ \HEXADecimalnum{\expandafter\expandafter\expandafter
\the\value{#1}}%
}
+\newrobustcmd*\FC@Hexadecimal@warning{%
+ \PackageWarning{fmtcount}{\string\Hexadecimal\space is deprecated, use \string\HEXADecimal\space
+ instead. The \string\Hexadecimal\space control sequence name is confusing as it can mislead in thinking
+ that only the 1st letter is upper-cased.}%
+}
+\def\Hexadecimal{%
+ \FC@Hexadecimal@warning
+ \HEXADecimal}
% \end{macrocode}
%\end{macro}
%\begin{macro}{\octal}