summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2019-11-17 22:38:43 +0000
committerKarl Berry <karl@freefriends.org>2019-11-17 22:38:43 +0000
commit8a79552abe489b9b36d0986944dfc616595e63a4 (patch)
tree2ec6544e4c2edc1f083f193fbc09520abaca25c4 /Master/texmf-dist/tex/latex
parenta319b877e3db590613748f78848498aea73114dc (diff)
datetime2 (17nov19)
git-svn-id: svn://tug.org/texlive/trunk@52846 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex')
-rw-r--r--Master/texmf-dist/tex/latex/datetime2/datetime2-calc.sty2
-rw-r--r--Master/texmf-dist/tex/latex/datetime2/datetime2.sty49
2 files changed, 41 insertions, 10 deletions
diff --git a/Master/texmf-dist/tex/latex/datetime2/datetime2-calc.sty b/Master/texmf-dist/tex/latex/datetime2/datetime2-calc.sty
index 0760e5ce1f4..97d48f9bc51 100644
--- a/Master/texmf-dist/tex/latex/datetime2/datetime2-calc.sty
+++ b/Master/texmf-dist/tex/latex/datetime2/datetime2-calc.sty
@@ -39,7 +39,7 @@
%% Grave accent \` Left brace \{ Vertical bar \|
%% Right brace \} Tilde \~}
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{datetime2-calc}[2019/10/21 v1.5.4 (NLCT)]
+\ProvidesPackage{datetime2-calc}[2019/11/11 v1.5.5 (NLCT)]
\RequirePackage{pgfkeys}
\RequirePackage{pgfcalendar}
\newcount\@dtm@julianday
diff --git a/Master/texmf-dist/tex/latex/datetime2/datetime2.sty b/Master/texmf-dist/tex/latex/datetime2/datetime2.sty
index 48d95241b60..c6763902a55 100644
--- a/Master/texmf-dist/tex/latex/datetime2/datetime2.sty
+++ b/Master/texmf-dist/tex/latex/datetime2/datetime2.sty
@@ -39,7 +39,7 @@
%% Grave accent \` Left brace \{ Vertical bar \|
%% Right brace \} Tilde \~}
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{datetime2}[2019/10/21 v1.5.4 (NLCT) date and time formats]
+\ProvidesPackage{datetime2}[2019/11/11 v1.5.5 (NLCT) date and time formats]
\RequirePackage{tracklang}
\RequirePackage{etoolbox}
\RequirePackage{xkeyval}[2006/11/18]
@@ -185,12 +185,28 @@
\DeclareOptionX*{%
\ifcsundef{@tracklang@add@\CurrentOption}%
{%
- \PackageError{datetime2}{`\CurrentOption' is not a recognised dialect.
- \MessageBreak Perhaps you have misspelt it or the
- \MessageBreak named dialect may be unsupported or
- \MessageBreak perhaps you forgot to use the `style' key}%
- {Any options that aren't described in the manual are assumed
- \MessageBreak to be language or dialect names.}%
+ \ifundef\TrackIfKnownLanguage
+ {%
+ \PackageError{datetime2}{Unrecognised dialect `\CurrentOption'.
+ If you are using a valid ISO language code
+ please update tracklang.sty to at least v1.3.9}%
+ {Any options that aren't described in the manual are assumed
+ \MessageBreak to be language or dialect names.}%
+ }%
+ {%
+ \TrackIfKnownLanguage{\CurrentOption}%
+ {\renewcommand*{\DTMifcaseregional}[3]{#2}}%
+ {%
+ \PackageError{datetime2}{`\CurrentOption' is not a recognised dialect
+ \MessageBreak and doesn't contain a known language code.
+ \MessageBreak Perhaps you have misspelt it or the
+ \MessageBreak named dialect may be unsupported or
+ \MessageBreak perhaps you forgot the `<key>=' part
+ \MessageBreak for example, `style=\CurrentOption'}%
+ {Any options that aren't described in the manual are assumed
+ \MessageBreak to be language or dialect names.}%
+ }%
+ }%
}%
{%
\TrackPredefinedDialect{\CurrentOption}%
@@ -476,14 +492,29 @@
\number#1\dtm@yearmonthsep\DTMtwodigits{#2}\dtm@monthdaysep\DTMtwodigits{#3}%
}%
\newcommand*{\DTMDisplaydate}{\DTMdisplaydate}
-\newrobustcmd*{\DTMdate}[1]{%
+\newcommand*{\DTMfinaldot}{.}
+\newrobustcmd*{\DTMdate}{\@ifstar\@sDTMdate\@DTMdate}
+\newcommand*{\@DTMdate}[1]{%
\expandafter\@dtm@parsedate#1\@dtm@endparsedate
\DTMdisplaydate{\@dtm@year}{\@dtm@month}{\@dtm@day}{\@dtm@dow}%
}
-\newrobustcmd*{\DTMDate}[1]{%
+\newcommand*{\@sDTMdate}[1]{%
+ {%
+ \let\DTMfinaldot\empty
+ \@DTMdate{#1}%
+ }%
+}
+\newrobustcmd*{\DTMDate}{\@ifstar\@sDTMDate\@DTMDate}
+\newcommand*{\@DTMDate}[1]{%
\expandafter\@dtm@parsedate#1\@dtm@endparsedate
\DTMDisplaydate{\@dtm@year}{\@dtm@month}{\@dtm@day}{\@dtm@dow}%
}
+\newcommand*{\@sDTMDate}[1]{%
+ {%
+ \let\DTMfinaldot\empty
+ \@DTMDate{#1}%
+ }%
+}
\newcommand*{\DTMcurrenttime}{%
\DTMdisplaytime
{\@dtm@currenthour}%