I ran into a weird problem with the \usepackage{datetime2}
(with datetime2-english
installed). When I run the following code
\documentclass{article}
\usepackage[UKenglish]{babel}
\usepackage[useregional=numeric]{datetime2}
\DTMlangsetup[en-GB]{datesep={\space\&,\&\space}}
\begin{document}
\today\\
\DTMdisplaydate{2000}{01}{01}{}
\end{document}
the date is typeset correctly in both cases (i.e. with the datesep intentionally set to weird values [' &,& '] for demonstration purposes). This shows me, that the en-GB-numeric style seems to be used correctly. Nevertheless, I get three errors
! Package datetime2 Error: Unknown style `en-GB-regional'
and nine warnings
Package datetime2 Warning: No date style `en-GB-regional' defined on input line[...]
The same is true for en-US
. However, in both cases there is absolutely no problem when I set useregional=text
. Am I doing something wrong or is this a bug?
\today
is redefined by babel and for\DTMdisplaydate
uses the default instead ofen-GB
. So both dates are then not in the format I want, and worse not even consistently formatted. In the datetime2 manual this is hinted at and there alsodatetime2
is always loaded afterbabel
– Manuel Weinkauf Apr 8 '15 at 13:54datetime2-en-GB.ldf
.\DTMsetstyle{en-GB-regional}
should be\DTMsetstyle{en-GB-numeric}
– Ulrike Fischer Apr 8 '15 at 13:55