diff options
17 files changed, 1764 insertions, 1087 deletions
diff --git a/Master/texmf-dist/doc/latex/isodate/ChangeLog b/Master/texmf-dist/doc/latex/isodate/ChangeLog index 3d9722aff32..ec545224163 100644 --- a/Master/texmf-dist/doc/latex/isodate/ChangeLog +++ b/Master/texmf-dist/doc/latex/isodate/ChangeLog @@ -1,3 +1,12 @@ +2010/01/03 v2.30 Harald Harders (h.harders@tu-bs.de) + - Add a month-year format (omitting the day) + - Move defintion of language-independent formats into the main + style file + +2007/04/09 v2.29 Harald harders (h.harders@tu-bs.de) + - Allow to change the unbreakable spaces in the orig and + shortorig format + 2005/04/15 v2.28 Harald Harders (h.harders@tu-bs.de) - Add Italian language by Philip Ratcliffe. - Introduce option cleanlook for English date format. @@ -18,7 +27,7 @@ - Add option frenchb. 2004/11/19 v2.23 Harald Harders (h.harders@tu-bs.de) - - Avoid to use the \texttt{calc} package since it causes problems + - Avoid to use the calc package since it causes problems with many other packages. 2004/02/12 v2.22 Harald Harders (h.harders@tu-bs.de) diff --git a/Master/texmf-dist/doc/latex/isodate/README b/Master/texmf-dist/doc/latex/isodate/README index 656020c7509..cadad64377c 100644 --- a/Master/texmf-dist/doc/latex/isodate/README +++ b/Master/texmf-dist/doc/latex/isodate/README @@ -30,7 +30,7 @@ Version 2.0 was totally rewritten so that some incompatiblities may occur. The old version is still available as isodateo.sty (`o' for old). -Copyright 2000--2005 Harald Harders +Copyright 2000--2010 Harald Harders This program can be redistributed and/or modified under the terms of the LaTeX Project Public License Distributed from CTAN @@ -72,6 +72,6 @@ To do: first and second digits. -2005-02-17 +2010-01-03 Harald Harders h.harders@tu-bs.de diff --git a/Master/texmf-dist/doc/latex/isodate/isodate.pdf b/Master/texmf-dist/doc/latex/isodate/isodate.pdf Binary files differindex 1d6a2afd445..2bcd456c772 100644 --- a/Master/texmf-dist/doc/latex/isodate/isodate.pdf +++ b/Master/texmf-dist/doc/latex/isodate/isodate.pdf diff --git a/Master/texmf-dist/doc/latex/isodate/isodate.xml b/Master/texmf-dist/doc/latex/isodate/isodate.xml index 80f2a95797c..5b14f6a5e4e 100644 --- a/Master/texmf-dist/doc/latex/isodate/isodate.xml +++ b/Master/texmf-dist/doc/latex/isodate/isodate.xml @@ -1,7 +1,7 @@ <?xml version="1.0"?> <!DOCTYPE entry SYSTEM "../catalogue.dtd"> <entry id="isodate" - datestamp="2005/04/15" + datestamp="2010/01/03" modifier="h.harders@tu-bs.de"> <about> <name>isodate</name> @@ -12,7 +12,7 @@ </author> <license type="lppl"/> <version> - <number>2.28</number> + <number>2.30</number> </version> </about> <description> diff --git a/Master/texmf-dist/doc/latex/isodate/testdate.pdf b/Master/texmf-dist/doc/latex/isodate/testdate.pdf Binary files differindex 193cd75f042..46e0d425772 100644 --- a/Master/texmf-dist/doc/latex/isodate/testdate.pdf +++ b/Master/texmf-dist/doc/latex/isodate/testdate.pdf diff --git a/Master/texmf-dist/doc/latex/isodate/testdate.tex b/Master/texmf-dist/doc/latex/isodate/testdate.tex index 59daa5676b2..818ca4916b9 100644 --- a/Master/texmf-dist/doc/latex/isodate/testdate.tex +++ b/Master/texmf-dist/doc/latex/isodate/testdate.tex @@ -1,14 +1,20 @@ -\documentclass[spanish,swedish,norsk,italian,danish,french,USenglish,english,newzealand,naustrian,ngerman,a4paper,fleqn,11pt]{article} +\documentclass[spanish,swedish,norsk,italian,danish,french,USenglish,english,australian,newzealand,naustrian,ngerman,a4paper,fleqn,11pt]{article} \usepackage[T1]{fontenc} \usepackage{babel} -\usepackage[iso,cleanlook]{isodate} +%\usepackage[iso,cleanlook]{isodate} +\usepackage[iso,nocleanlook]{isodate} %\usepackage{ngerman} %\usepackage{bibgerm} %\shortyearsign{'} %\printyearoff +\printdayoff + +\overfullrule1mm \setlength{\parindent}{0mm} -\addtolength\textheight{4\baselineskip} +\addtolength\textheight{10\baselineskip} +\addtolength\topmargin{-4\baselineskip} +\addtolength\textwidth{6mm} \makeatletter \newcommand{\example}[2][]{% @@ -66,6 +72,16 @@ &TeXdate&``\TeXdate\daterange{1972-1-30}{2001-1-28}''\\ &back to normal&``\origdate\daterange{1972-1-30}{2001-1-28}''\\ \end{tabular}% + + {\origdate A very, very long line with a linebreak within the date to test + linebreak: \printdate{2007-04-09}} + + {\isospacebeforeyear{\ }% + \isospacebeforemonth{\ }% + \isospacebeforeday{\ }% + \origdate A very, very long line with a linebreak within the date to test + linebreak: \printdate{2007-04-09}} + }% } \makeatother @@ -78,7 +94,8 @@ \example{ngerman} \example{naustrian} \example{english} -\example{newzealand} +\example{australian} +%\example{newzealand} \example{USenglish} %\example{american} \example{french} diff --git a/Master/texmf-dist/source/latex/isodate/isodate.dtx b/Master/texmf-dist/source/latex/isodate/isodate.dtx index 6d657256e9b..8f280c8f35a 100644 --- a/Master/texmf-dist/source/latex/isodate/isodate.dtx +++ b/Master/texmf-dist/source/latex/isodate/isodate.dtx @@ -1,5 +1,5 @@ % \iffalse meta comment -% File: isodate.dtx Copyright (C) 2000--2005 Harald Harders +% File: isodate.dtx Copyright (C) 2000--2010 Harald Harders % \fi % % \iffalse @@ -44,13 +44,16 @@ \DoNotIndex{\begingroup,\endgroup,\begin,\end,\CurrentOption} \CodelineNumbered \RecordChanges -\CheckSum{2471} +\CheckSum{2493} \begin{document} \DocInput{isodate.dtx} \end{document} %</driver> % \fi % +% \changes{2.30}{2010/01/03}{Add a month-year format}% +% \changes{2.30}{2010/01/03}{Move defintion of language-independent +% formats into the main style file}% % \changes{2.26}{2005/03/10}{Support different input formats % containing slashes}% % \changes{2.23}{2004/11/19}{Avoid to use the \texttt{calc} package @@ -183,7 +186,7 @@ % change it locally inside a group; e.g., % \begin{verbatim} %\today, {\origdate\today}, \today\end{verbatim} -% leads to ``\today, {\origdate\today}, \today''. +% leads to `\today, {\origdate\today}, \today'. % % \DescribeMacro{\printyearoff}% % \DescribeMacro{\printyearon}% @@ -196,8 +199,14 @@ % An example: % \begin{verbatim} %\today, {\printyearoff\today}, \today\end{verbatim} -% leads to ``{\origdate\today, {\printyearoff\today}, \today}''. +% leads to `{\origdate\today, {\printyearoff\today}, \today}'. % +% \DescribeMacro{\printdayoff}% +% \DescribeMacro{\printdayon}% +% Likewise you can switch on or off printing the day using +% \cs{printdayon} and \cs{printdayoff}. +% Note that you still have to provide complete dates in the +% \cs{printdate} command, described in Section~\ref{sec:anydate} below. % % \subsection{Printing today's date} % @@ -206,6 +215,7 @@ % appearance is influenced by the current date format % % \subsection{Printing any date} +% \label{sec:anydate} % % \DescribeMacro{\printdate}% % The command \verb|\printdate{#1}| prints any date in the current @@ -224,10 +234,10 @@ %\printdateTeX{2000/12/24}\end{verbatim} % This command is useful for printing version information stored in a % macro. For example the version of this package is stored in -% the macro \verb|\filedate| (``\filedate''). To print it with the actual +% the macro \verb|\filedate| (`\filedate'). To print it with the actual % date format you can use the command \verb|\printdateTeX{\filedate}| -% which leads to e.g., ``\printdateTeX{\filedate}'' or -% {\origdate``\printdateTeX{\filedate}''}. +% which leads to e.g., `\printdateTeX{\filedate}' or +% {\origdate`\printdateTeX{\filedate}'}. % Another possibility is to switch the input format to |tex| using % \cs{dateinputformat}, described below. % @@ -263,12 +273,12 @@ % \subsection{Changing the ISO format} % % \DescribeMacro{\isodash}% -% The ISO norm says that the date format is ``yyyy-mm-dd'' or -% ``yyyymmdd'' \cite{iso8601a}. -% By default I use the hyphen ``-'' as separator. You can change this -% using the \verb|\isodash|\footnote{The name ``isodash'' is a little +% The ISO norm says that the date format is `yyyy-mm-dd' or +% `yyyymmdd' \cite{iso8601a}. +% By default I use the hyphen `-' as separator. You can change this +% using the \verb|\isodash|\footnote{The name `isodash' is a little % bit confusing and was chosen due to my limited knowledge in -% English. It should be named ``isoseparator'' or ``isosep''. But for +% English. It should be named `isoseparator' or `isosep'. But for % compatiblity reasons I will not change it.} command, e.g., % \begin{verbatim} %\printdate{24/12/2000}, @@ -276,11 +286,37 @@ %\printdate{24/12/2000}, %\isodash{}% %\printdate{24/12/2000}\end{verbatim} -% leads to ``2000-12-24, 2000--12--24, 20001224''. Or for example +% leads to `2000-12-24, 2000--12--24, 20001224'. Or for example % \begin{verbatim} %\isodash{$\cdot$} %\printdate{24/12/2000}\end{verbatim} -% leads to ``2000$\cdot$12$\cdot$24''. +% leads to `2000$\cdot$12$\cdot$24'. +% +% +% \subsection{Changing the original and short original format} +% +% \DescribeMacro{\isospacebeforeday}% +% \DescribeMacro{\isospacebeforemonth}% +% \DescribeMacro{\isospacebeforeyear}% +% +% By default, the original and short original format prints +% unbreakable spaces between the parts of the dates, e.g., +% `|19~May~2001|'. +% If you want to allow breakable spaces or other characters, you can +% redefine the spaces using \cs{isospacebeforeday}, +% \cs{isospacebeforemonth}, and \cs{isospacebeforeyear}: +% \begin{verbatim} +%\isospacebeforeyear{\ }\end{verbatim} +% leads to `|19~May\ 2001|'. Notice that the space is written as +% \verb*|\ | to ensure that the space is not getting lost under all +% circumstances. +% +% As the names imply, the spaces before the specified part (day, month, +% or year) is changed. For most formats, only \cs{isospacebeforemonth} +% and \cs{isospacebeforeyear} are relevant, while for US English, +% \cs{isospacebeforeday} and \cs{isospacebeforeyear} are used. +% +% This only effects the \verb|orig| and \verb|shortorig| formats. % % % \subsection{Changing the short original format} @@ -288,15 +324,15 @@ % \DescribeMacro{\shortyearsign}% % % The short original format normally prints the year with two digits, e.g., -% ``19th May 01''. +% `19th May 01'. % Some people want to add an additional sign before the year, e.g., -% ``19th May '01''. +% `19th May '01'. % This can be achieved by using the command \verb|\shortyearsign|, e.g., % \begin{verbatim} %\printdate{24/12/2000}, %\shortyearsign{'}% %\printdate{24/12/2000}\end{verbatim} -% leads to ``24 december 00, 24 december '00'' in English. +% leads to `24 december 00, 24 december '00' in English. % % This only effects the \verb|shortorig| format. The \verb|short| numerical % format stays unchanged. @@ -313,37 +349,44 @@ % is possible to change them. % \DescribeMacro{\daymonthsepgerman}% % \DescribeMacro{\monthyearsepgerman}% +% \DescribeMacro{\monthyearsepnodaygerman}% % You can change the spacing between the day and the month using the -% command \verb|\daymonthsepgerman|. Using the command -% \verb|\monthyearsepgerman| you can change the spacing between the +% command \cs{daymonthsepgerman}. Using the command +% \cs{monthyearsepgerman} you can change the spacing between the % month and the year for the long and the short format, e.g., % \begin{verbatim} %\daymonthsepgerman{\quad}% %\monthyearsepgerman{\qquad}{\quad}% %{\numdate\printdate{24.12.2000}}, {\shortdate\printdate{24.12.2000}}\end{verbatim} -% leads to ``24.\quad12.\qquad2000, 24.\quad12.\quad00''. +% leads to `24.\quad12.\qquad2000, 24.\quad12.\quad00'. +% +% The default values are `\cs{,}' for the separator between day and +% month resp.\ `\cs{,}' between month and year in the short format +% and `|~|' in the long format. % -% The default values are ``\cs{,}'' for the separator between day and -% month resp.\ ``\cs{,}'' between month and year in the short format -% and ``|~|'' in the long format. +% Likewise, \cs{monthyearsepnodaygerman} is used for defining the +% spacing between the month and the year when printing the day is +% switched off (using \cs{printdayoff}). +% The arguments are the same as for \cs{monthyearsepgerman}. +% Default is no space for long and short format. % % % \subsection{Changing the English format} % % \changes{2.28}{2005/04/15}{Introduce option cleanlook for English % date format}% -% By default, the English date format looks like ``24th December -% 2000''. +% By default, the English date format looks like `24th December +% 2000'. % During the last years, a change has occured in many documents -% towards ``24 December 2000''. -% This new format is called ``clean look''. +% towards `24 December 2000'. +% This new format is called `clean look'. % \DescribeMacro{\cleanlookdateon}% % \DescribeMacro{\cleanlookdateoff}% % Isodate's behaviour can be changed towards it using % \cs{cleanlookdateon} and \cs{cleanlookdateoff}. % This can also be done globally using the |cleanlook| package option. % -% At the moment, the ``clean look'' functionality only affects British +% At the moment, the `clean look' functionality only affects British % English. % If this trend also counts for different languages, please tell it me % that I can add support for them. @@ -367,7 +410,7 @@ % You may do similar things, e.g., % \begin{verbatim} %\numdate[Alph]\end{verbatim} -% prints the months with the command \cs{Alph}, ``A'', ``B'', \ldots{} +% prints the months with the command \cs{Alph}, `A', `B', \ldots{} % The day is printed with two digits since every call of \cs{numdate} % or \cs{shortdate} calls \cs{isotwodigitdaytrue} which switches % printing the day with two digits on. @@ -390,22 +433,22 @@ %\numdate[boldnum]% %\printdate{24.3.2000}}\end{verbatim} % leas to -% ``{\def\boldnum#1{\textbf{\twodigitarabic{#1}}}\ignorespaces +% `{\def\boldnum#1{\textbf{\twodigitarabic{#1}}}\ignorespaces % \numdate[boldnum]\ignorespaces -% \printdate{24.3.2000}}''. +% \printdate{24.3.2000}}'. % \DescribeMacro{\twodigitarabic} % Here, the \cs{twodigitarabic} command has been used that prints a % positive number with at least two digits.\footnote{This command is % also used for the numerical date formats.} % % If you, for example want a numerical date format with the day and -% month printed with the ``natural'' number of digits rather than with +% month printed with the `natural' number of digits rather than with % two digits, you may do it as follows: % \begin{verbatim} %{\numdate[arabic]\isotwodigitdayfalse %\printdate{1.2.2000}}\end{verbatim} -% which leads to ``{\numdate[arabic]\isotwodigitdayfalse -% \printdate{1.2.2000}}''. +% which leads to `{\numdate[arabic]\isotwodigitdayfalse +% \printdate{1.2.2000}}'. % % Using one of the other date formats reset the numerical format to % its standard settings with arabic numerals (with two digits), e.g., @@ -413,9 +456,9 @@ %{\numdate[Alph]\printdate{6.12.2000}; %\isodate\printdate{6.12.2000}; %\numdate\printdate{6.12.2000}}\end{verbatim} -% leads to ``{\numdate[Alph]\isotwodigitdayfalse\printdate{6.12.2000}; +% leads to `{\numdate[Alph]\isotwodigitdayfalse\printdate{6.12.2000}; % \isodate\printdate{6.12.2000}; -% \numdate\printdate{6.12.2000}}''. +% \numdate\printdate{6.12.2000}}'. % % \subsection{Switching the date input format} % @@ -518,8 +561,11 @@ % \verb|inputlatex|& \TeX\ date input format\\ % \verb|inputLaTeX|& \TeX\ date input format\\ % \hline -% \verb|cleanlook|&use ``clean look'' for English dates\\ -% \verb|nocleanlook|&don't use ``clean look'' for English dates\\ +% \verb|cleanlook|&use `clean look' for English dates\\ +% \verb|nocleanlook|&don't use `clean look' for English dates (default)\\ +% \hline +% \verb|printdayon|&print complete date including the day (default)\\ +% \verb|printdayoff|&omit the day in the date\\ % \hline % \end{tabular} % \end{minipage} @@ -602,7 +648,7 @@ % % \section{Licence} % -% Copyright 2000--2005 Harald Harders +% Copyright 2000--2010 Harald Harders % % This program can be redistributed and/or modified under the terms % of the LaTeX Project Public License Distributed from CTAN @@ -617,16 +663,15 @@ % \item The language definition files \verb|french.idf| and % \verb|german.idf| are not yet commented. % \item Isodate and draftcopy do not work together. +% \item Documentation of the code is partly poor. % \end{itemize} % % \section{Planned features and changes} % % \begin{itemize} -% \item Of course eliminate the errors. % \item Add other languages. % Please help me with this topic. I don't know the date formats in % other languages. -% \item Add a command that prints only the month and the year of a date. % \item Format short given years to four digits and calculate % reasonable first and second digits. % \end{itemize} @@ -659,8 +704,8 @@ %<italian>\ProvidesFile{italian.idf} %<norsk>\ProvidesFile{norsk.idf} %<swedish>\ProvidesFile{swedish.idf} -%<isodate> [2005/04/15 v2.28 Print dates with different formats (HH)] -%<language> [2005/04/15 v2.28 Language definitions for isodate package (HH)] +%<isodate> [2010/01/03 v2.30 Print dates with different formats (HH)] +%<language> [2010/01/03 v2.30 Language definitions for isodate package (HH)] % \end{macrocode} % The package: % \begin{macrocode} @@ -692,6 +737,12 @@ \DeclareOption{cleanlook}{\AtEndOfPackage{\cleanlookdateon}} \DeclareOption{nocleanlook}{\AtEndOfPackage{\cleanlookdateoff}} % \end{macrocode} +% \changes{2.30}{2010/01/03}{Add a month-year format}% +% Declare the options which decide wheather day is printed. +% \begin{macrocode} +\DeclareOption{printdayoff}{\AtEndOfPackage{\printdayoff}} +\DeclareOption{printdayon}{\AtEndOfPackage{\printdayon}} +% \end{macrocode} % \changes{2.26}{2005/03/10}{Support different input formats % containing slashes}% % Declare the options for the default date input format. @@ -743,7 +794,7 @@ % \end{macrocode} % Set default option to \verb|orig|. % \begin{macrocode} -\ExecuteOptions{orig,nocleanlook} +\ExecuteOptions{orig,nocleanlook,printdayon} % \end{macrocode} % Process the options. % \begin{macrocode} @@ -863,20 +914,20 @@ % \begin{macrocode} \DeclareRobustCommand*\dateinputformat[1]{% \ifthenelse{% - \equal{#1}{english}\or - \equal{#1}{british}\or + \equal{#1}{english}\OR + \equal{#1}{british}\OR \equal{#1}{UKenglish}}{% \def\iso@inputformat{english}% }{% \ifthenelse{% - \equal{#1}{american}\or + \equal{#1}{american}\OR \equal{#1}{USenglish}}{% \def\iso@inputformat{american}% }{% \ifthenelse{% - \equal{#1}{tex}\or - \equal{#1}{TeX}\or - \equal{#1}{latex}\or + \equal{#1}{tex}\OR + \equal{#1}{TeX}\OR + \equal{#1}{latex}\OR \equal{#1}{LaTeX}}{% \def\iso@inputformat{tex}% }{% @@ -1008,7 +1059,7 @@ % \end{macrocode} % \end{macro} % \begin{macro}{\isodash} -% Changes the dash in the ISO date format. The default is ``-''. +% Changes the dash in the ISO date format. The default is `-'. % \begin{macrocode} \def\iso@isodash{-}% \DeclareRobustCommand*\isodash[1]{\def\iso@isodash{#1}}% @@ -1024,7 +1075,7 @@ % \end{macro} % \begin{macro}{\isorangesign} % Defines the sign or word that is printed between the two dates in a -% date range. e.g., in English the default is ``~to~''. +% date range. e.g., in English the default is `~to~'. % \begin{macrocode} \def\iso@rangesign{\csname iso@rangesign@\iso@languagename\endcsname}% \DeclareRobustCommand*\isorangesign[1]{\def\iso@rangesign{#1}}% @@ -1043,12 +1094,25 @@ % \end{macrocode} % \end{macro} % \end{macro} +% \begin{macro}{\printdayoff} +% \begin{macro}{\printdayon} +% \changes{2.30}{2010/01/03}{Add a month-year format}% +% Switch on or off suppressing the day in date output. +% Default is not print the day. +% \begin{macrocode} +\newif\ifiso@doprintday +\DeclareRobustCommand*\printdayon{\iso@doprintdaytrue} +\DeclareRobustCommand*\printdayoff{\iso@doprintdayfalse} +\printdayon +% \end{macrocode} +% \end{macro} +% \end{macro} % \begin{macro}{\cleanlookdateoff} % \begin{macro}{\cleanlookdateon} % \changes{2.28}{2005/04/15}{Introduce option cleanlook for English % date format}% -% Switch on or off ``clean look'' for English dates. -% Default is not to use ``clean look''. +% Switch on or off `clean look' for English dates. +% Default is not to use `clean look'. % \begin{macrocode} \newif\ifiso@cleanlook \DeclareRobustCommand*\cleanlookdateon{\iso@cleanlooktrue} @@ -1057,6 +1121,24 @@ % \end{macrocode} % \end{macro} % \end{macro} +% \begin{macro}{\isospacebeforeday} +% \begin{macro}{\isospacebeforemonth} +% \begin{macro}{\isospacebeforeyear} +% \changes{2.29}{2007/04/09}{Allow to change the unbreakable spaces in +% the orig and shortorig format}% +% Change the spaces in the orig and short orig format. +% Default is |~| for all of them. +% \begin{macrocode} +\newcommand*\iso@daysep{~} +\newcommand*\iso@monthsep{~} +\newcommand*\iso@yearsep{~} +\DeclareRobustCommand*\isospacebeforeday[1]{\def\iso@daysep{#1}} +\DeclareRobustCommand*\isospacebeforemonth[1]{\def\iso@monthsep{#1}} +\DeclareRobustCommand*\isospacebeforeyear[1]{\def\iso@yearsep{#1}} +% \end{macrocode} +% \end{macro} +% \end{macro} +% \end{macro} % \begin{macro}{\iso@printdate} % Defines the command \verb|iso@printdate| which takes three arguments % (year, month, day) and prints the date by using the \cs{today} command. @@ -1099,25 +1181,25 @@ % \begin{macrocode} \edef\iso@date{#1}% % \end{macrocode} -% Count appearances of ``/'', ``-'', and ``.'' in the argument. +% Count appearances of `/', `-', and `.' in the argument. % \begin{macrocode} \SubStringsToCounter{iso@slash}{/}{\iso@date}% \SubStringsToCounter{iso@minus}{-}{\iso@date}% \SubStringsToCounter{iso@dot}{.}{\iso@date}% % \end{macrocode} -% If number of ``.'' in the argument is equal to 2 then the German +% If number of `.' in the argument is equal to 2 then the German % format \verb|dd.mm.yyyy| is used. % \begin{macrocode} \ifthenelse{\equal{\theiso@dot}{2}}{% \expandafter\iso@input@german\iso@date\@empty}{% % \end{macrocode} -% If number of ``-'' in the argument is equal to 2 then the ISO +% If number of `-' in the argument is equal to 2 then the ISO % format \verb|yyyy-mm-dd| is used. % \begin{macrocode} \ifthenelse{\equal{\theiso@minus}{2}}{% \expandafter\iso@input@iso\iso@date\@empty}{% % \end{macrocode} -% If number of ``/'' in the argument is equal to 2 then the British English +% If number of `/' in the argument is equal to 2 then the British English % format \verb|dd/mm/yyyy| is used. % \begin{macrocode} \ifthenelse{\equal{\theiso@slash}{2}}{% @@ -1180,11 +1262,11 @@ % \begin{macrocode} \edef\iso@date{#1}% % \end{macrocode} -% Count appearances of ``/'' in the argument. +% Count appearances of `/' in the argument. % \begin{macrocode} \SubStringsToCounter{iso@slash}{/}{\iso@date}% % \end{macrocode} -% If number of ``/'' in the argument is equal to 2 then the \LaTeX\ +% If number of `/' in the argument is equal to 2 then the \LaTeX\ % format \verb|yyyy/mm/dd| is used. % \begin{macrocode} \ifthenelse{\equal{\theiso@slash}{2}}{% @@ -1210,6 +1292,80 @@ \def\iso@input@TeX#1/#2/#3\@empty{\iso@printdate{#1}{#2}{#3}} % \end{macrocode} % \end{macro} +% \begin{macro}{\iso@printmonthday@int} +% ?????? +% \begin{macrocode} +\def\iso@printmonthday@int#1#2{% + \ifthenelse{\equal{\iso@dateformat}{iso}}{% + \iso@printmonth{#1}% + \ifiso@doprintday + \iso@isodash\iso@printday{#2}% + \fi + }{% + \ifthenelse{\equal{\iso@dateformat}{TeX}}{% + \iso@printmonth{#1}% + \ifiso@doprintday + /\iso@printday{#2}% + \fi + }{% + \PackageError{isodate.sty}{\csname iso@printmonthday\endcsname: + Invalid date format `\iso@dateformat'}{Internal error. Please + report to the package author.} + }% + }% +} +% \end{macrocode} +% \end{macro} +% \begin{macro}{\iso@printdate@int} +% ?????? +% \begin{macrocode} +\def\iso@printdate@int#1#2#3{% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{iso}}{% + \iso@yearfour{\number#1}\iso@isodash% + }{% + \ifthenelse{\equal{\iso@dateformat}{TeX}}{% + \iso@yearfour{\number#1}/% + }{% + \PackageError{isodate.sty}{\csname iso@printmonthday\endcsname: + Invalid date format `\iso@dateformat'}{Internal error. Please + report to the package author.} + }% + }% + \fi + \csname iso@printmonthday@int\endcsname{\number#2}{\number#3}% +} +% \end{macrocode} +% \end{macro} +% \begin{macro}{\iso@daterange@int} +% ?????? +% \begin{macrocode} +\def\iso@daterange@int#1#2#3#4#5#6{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + \iso@rangesign% + \ifthenelse{\equal{\number#1}{\number#4}}{% + \ifthenelse{\equal{\number#2}{\number#5}}{% + \ifiso@doprintday + \iso@printday{#6}% + \else + \iso@printmonthday@int{#5}{#6}% + \fi + }{% + \iso@printmonthday@int{#5}{#6}% + }% + }{% + \iso@printdate@int{#4}{#5}{#6}% + }% + }{% + \PackageError{isodate.sty}{\csname iso@printmonthday\endcsname: + Invalid date format `\iso@dateformat'}{Internal error. Please + report to the package author.} + }% +} +% \end{macrocode} +% \end{macro} % \begin{macro}{\daterange} % Prints a date range. % \begin{macrocode} @@ -1223,7 +1379,7 @@ \edef\iso@@date{#2}% \edef\iso@@@date{\iso@date,\iso@@date}% % \end{macrocode} -% Count appearances of ``/'', ``-'', and ``.'' in the arguments. +% Count appearances of `/', `-', and `.' in the arguments. % \begin{macrocode} \SubStringsToCounter{iso@slash}{/}{\iso@date}% \SubStringsToCounter{iso@minus}{-}{\iso@date}% @@ -1232,22 +1388,22 @@ \SubStringsToCounter{iso@@minus}{-}{\iso@@date}% \SubStringsToCounter{iso@@dot}{.}{\iso@@date}% % \end{macrocode} -% If number of ``.'' in both arguments is equal to 2 then the German +% If number of `.' in both arguments is equal to 2 then the German % format \verb|dd.mm.yyyy| is used. % \begin{macrocode} - \ifthenelse{\equal{\theiso@dot}{2}\and\equal{\theiso@@dot}{2}}{% + \ifthenelse{\equal{\theiso@dot}{2}\AND\equal{\theiso@@dot}{2}}{% \expandafter\iso@range@input@german\iso@@@date\@empty}{% % \end{macrocode} -% If number of ``-'' in both arguments is equal to 2 then the ISO +% If number of `-' in both arguments is equal to 2 then the ISO % format \verb|yyyy-mm-dd| is used. % \begin{macrocode} - \ifthenelse{\equal{\theiso@minus}{2}\and\equal{\theiso@@minus}{2}}{% + \ifthenelse{\equal{\theiso@minus}{2}\AND\equal{\theiso@@minus}{2}}{% \expandafter\iso@range@input@iso\iso@@@date\@empty}{% % \end{macrocode} -% If number of ``/'' in both arguments is equal to 2 then the British English +% If number of `/' in both arguments is equal to 2 then the British English % format \verb|dd/mm/yyyy| is used. % \begin{macrocode} - \ifthenelse{\equal{\theiso@slash}{2}\and% + \ifthenelse{\equal{\theiso@slash}{2}\AND \equal{\theiso@@slash}{2}}{% \expandafter\iso@range@input@english\iso@@@date\@empty}{% % \end{macrocode} @@ -1393,8 +1549,8 @@ } % \end{macrocode} % \end{macro} -% Define the counters for conting the appearances of ``.'', ``-'', and -% ''/'' in the arguments. +% Define the counters for conting the appearances of `.', `-', and +% '/' in the arguments. % \begin{macrocode} \newcounter{iso@slash} \newcounter{iso@minus} @@ -1408,7 +1564,7 @@ % babel.sty, german.sty, or ngerman.sty. % % If neither babel.sty nor german.sty nor ngerman.sty is loaded my -% computer returns ``nohyphenation'' when using \verb|\languagename|. +% computer returns `nohyphenation' when using \verb|\languagename|. % So this is the indication that none of the above packages is loaded. % \changes{2.01}{2000/08/24}{Handle case of not loaded language % package babel, german and ngerman} @@ -1430,7 +1586,7 @@ \typeout{isodate: ngerman.sty has been loaded}% }{}% % \end{macrocode} -% The language is not equal ``nohyphenation''. So one of the language +% The language is not equal `nohyphenation'. So one of the language % packages is loaded. Replace the internal language name % \verb|\iso@languagename| by the global language name \verb|\languagename|. % \begin{macrocode} @@ -1482,88 +1638,106 @@ % Prints the month and the day given as two arguments % (\verb|{mm}{dd}|) in the current date format. % \begin{macrocode} - \def\iso@printmonthday@danish#1#2{% +\def\iso@printmonthday@danish#1#2{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% % \end{macrocode} % Numeric and short date format: \verb|dd/mm/| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% -% \end{macrocode} -% ISO date format: \verb|-mm-dd| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \ifiso@printyear\iso@isodash\fi\iso@printmonth{#1}% - \iso@isodash\iso@printday{#2}}{% -% \end{macrocode} -% \LaTeX\ date format: \verb|/mm/dd| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear/\fi\iso@printmonth{#1}/\iso@printday{#2}}{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% % \end{macrocode} % Original date format: \verb|d. mmm| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#2}.~\begingroup - \edef\lmonth{#1}\def\month{\lmonth}% - \month@danish% - \endgroup - }{}}}}% - } + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \ifiso@doprintday + \iso@printday{#2}.\iso@monthsep + \fi + \begingroup + \edef\lmonth{#1}\def\month{\lmonth}% + \month@danish% + \endgroup + }{}% + }% + }% +} % \end{macrocode} % \end{macro} % \begin{macro}{\iso@printdate@danish} % Prints the date given as three arguments (\verb|{yyyy}{mm}{dd}|) in % the actual date format % \begin{macrocode} - \def\iso@printdate@danish#1#2#3{% +\def\iso@printdate@danish#1#2#3{% % \end{macrocode} % ISO or \LaTeX date format: \verb|yyyy\iso@printmonthday@danish| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}\or% - \equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear - \number#1% - \fi}{}% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% \iso@printmonthday@danish{\number#2}{\number#3}% \ifiso@printyear % \end{macrocode} +% ????? +% \begin{macrocode} + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% +% \end{macrocode} % numeric date format: \verb|\iso@printmonthday@danish yyyy| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{numeric}}{\iso@yearfour{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% % \end{macrocode} % original date format: \verb|\iso@printmonthday@danish~yyyy| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% % \end{macrocode} % short original date format: \verb|\iso@printmonthday@danish~yy| % \begin{macrocode} \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% % \end{macrocode} % short date format: \verb|\iso@printmonthday@danish yy| % \begin{macrocode} \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{% - }}}}% - \fi - } + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% +} % \end{macrocode} % \end{macro} % \begin{macro}{\iso@datedanish} % This command redefines the \cs{today} command to print in the % actual date format. % \begin{macrocode} - \def\iso@datedanish{% - \def\today{\iso@printdate@danish{\year}{\month}{\day}}}% +\def\iso@datedanish{% + \def\today{\iso@printdate@danish{\year}{\month}{\day}}}% % \end{macrocode} % \end{macro} % \begin{macro}{\iso@daterange@...} % Define date-range commands for dialects. % \begin{macrocode} - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@danish}% +\expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@danish}% % \end{macrocode} % \end{macro} % \begin{macro}{\iso@daterange@danish} @@ -1575,22 +1749,12 @@ % \end{macrocode} % ISO or \LaTeX\ date format. % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% % \end{macrocode} -% Print the start date. -% \begin{macrocode} - \csname iso@printdate@\iso@languagename\endcsname{% - #1}{#2}{#3}\iso@rangesign% -% \end{macrocode} -% If year and month are equal, only print the day of the end date. If -% only the year is equal, only print month and day of the end -% date. Otherwise print the whole end date. +% Call the appropriate international routine. % \begin{macrocode} - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@danish{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% }{% % \end{macrocode} % Numeric, short, or original date format. @@ -1601,27 +1765,33 @@ % \begin{macrocode} \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#3}.}{\iso@printday{#3}}% - }{\iso@printmonthday@danish{#2}{#3}}}{% - \begingroup - \printyearon - \csname iso@printdate@\iso@languagename\endcsname{% - #1}{#2}{#3}% - \endgroup}% + \ifiso@doprintday + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \iso@printday{#3}.% + }{% + \iso@printday{#3}% + }% + \else + \iso@printmonthday@danish{#2}{#3}% + \fi + }{% + \iso@printmonthday@danish{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + }% % \end{macrocode} % Print the end date. % \begin{macrocode} - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% - }{% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% }% } % \end{macrocode} % \end{macro} % \begin{macro}{\iso@rangesign@danish} -% Sets the word between start and end date in a date range to ``~til~''. +% Sets the word between start and end date in a date range to `~til~'. % \begin{macrocode} \expandafter\def\csname iso@rangesign@\CurrentOption\endcsname{~til~} % \end{macrocode} @@ -1675,10 +1845,10 @@ % % First handle British English. % \begin{macrocode} -\ifthenelse{\equal{\CurrentOption}{english}\or - \equal{\CurrentOption}{british}\or +\ifthenelse{\equal{\CurrentOption}{english}\OR + \equal{\CurrentOption}{british}\OR \equal{\CurrentOption}{UKenglish}}{% -\typeout{Define commands for English date format} + \typeout{Define commands for English date format} % \end{macrocode} % \begin{macro}{\day@english} % \changes{2.28}{2005/04/15}{Introduce option cleanlook for English @@ -1710,31 +1880,34 @@ % \end{macrocode} % Numeric and short date format: \verb|dd/mm/| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% -% \end{macrocode} -% ISO date format: \verb|mm-dd| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@printmonth{#1}\iso@isodash\iso@printday{#2}}{% -% \end{macrocode} -% \LaTeX\ date format: \verb|mm/dd| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@printmonth{#1}/\iso@printday{#2}}{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% % \end{macrocode} % Original date format: \verb|ddd mmm| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \begingroup - \edef\lday{#2}\def\day{\lday}% - \edef\lmonth{#1}\def\month{\lmonth}% - \day@english~\month@english% - \endgroup - }{}}}}% - } + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \begingroup + \edef\lday{#2}\def\day{\lday}% + \edef\lmonth{#1}\def\month{\lmonth}% + \ifiso@doprintday + \day@english\iso@monthsep\@empty + \fi + \month@english + \endgroup + }{}% + }% + }% + } % \end{macrocode} % \end{macro} % \begin{macro}{\iso@printdate@english} @@ -1742,39 +1915,49 @@ % the actual date format. % \begin{macrocode} \def\iso@printdate@english#1#2#3{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% % \end{macrocode} % ISO date format: \verb|yyyy-\iso@printmonthday@english| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \ifiso@printyear\iso@yearfour{\number#1}\iso@isodash\fi}{% -% \end{macrocode} -% \LaTeX\ date format: \verb|yyyy/\iso@printmonthday@english| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear\iso@yearfour{\number#1}/\fi}{}}% - \iso@printmonthday@english{\number#2}{\number#3}% + \iso@printmonthday@english{\number#2}{\number#3}% % \end{macrocode} % Numeric date format: \verb|\iso@printmonthday@english yyyy| % \begin{macrocode} - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{\iso@yearfour{\number#1}}{% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% % \end{macrocode} % Original date format: \verb|\iso@printmonthday@english~yyyy| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% % \end{macrocode} % Short original date format: \verb|\iso@printmonthday@english~yy| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% % \end{macrocode} % Short date format: \verb|\iso@printmonthday@english yy| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{% - }}}% - }% - \fi + \ifthenelse{\equal{\iso@dateformat}{short}}{% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% } % \end{macrocode} % \end{macro} @@ -1809,22 +1992,13 @@ % \end{macrocode} % ISO or \LaTeX\ date format. % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% % \end{macrocode} % Print the start date. % \begin{macrocode} - \csname iso@printdate@\iso@languagename\endcsname{% - #1}{#2}{#3}\iso@rangesign% -% \end{macrocode} -% If year and month are equal, only print the day of the end date. If -% only the year is equal, only print month and day of the end -% date. Otherwise print the whole end date. -% \begin{macrocode} - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@english{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% % \end{macrocode} % Numeric, short, or original date format. % @@ -1834,19 +2008,30 @@ % \begin{macrocode} \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \begingroup + \ifiso@doprintday + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \begingroup \edef\lday{#3}\def\day{\lday}% - \day@english\endgroup}{\iso@printday{#3}}% - }{\iso@printmonthday@english{#2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% + \day@english + \endgroup + }{% + \iso@printday{#3}% + }% + \else + \csname iso@printmonthday@\iso@languagename\endcsname{#2}{#3}% + \fi + }{% + \csname iso@printmonthday@\iso@languagename\endcsname{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + }% % \end{macrocode} % Print the end date. % \begin{macrocode} - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% - }{% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% }% } % \end{macrocode} @@ -1866,43 +2051,45 @@ % Second handle Australian and New Zealand. % \begin{macrocode} }{% - \ifthenelse{\equal{\CurrentOption}{australian}\or% + \ifthenelse{\equal{\CurrentOption}{australian}\OR \equal{\CurrentOption}{newzealand}}{% - \typeout{Define commands for Australian date format} + \typeout{Define commands for Australian date format} % \end{macrocode} % \begin{macro}{\iso@printmonthday@australian} % Prints the month and the day given as two arguments % (\verb|{mm}{dd}|) in the current date format. % \begin{macrocode} \def\iso@printmonthday@australian#1#2{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% % \end{macrocode} % Numeric and short date format: \verb|dd/mm/| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% -% \end{macrocode} -% ISO date format: \verb|mm-dd| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@printmonth{#1}\iso@isodash\iso@printday{#2}}{% -% \end{macrocode} -% \LaTeX\ date format: \verb|mm/dd| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@printmonth{#1}/\iso@printday{#2}}{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% % \end{macrocode} % Original date format: \verb|ddd mmm| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \begingroup -% \edef\lday{#2}\def\day{\lday}% - \edef\lmonth{#1}\def\month{\lmonth}% - \iso@printday{#2}~\month@english% - \endgroup - }{}}}}% - } + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \begingroup + \edef\lmonth{#1}\def\month{\lmonth}% + \ifiso@doprintday + \iso@printday{#2}\iso@monthsep\@empty + \fi + \month@english + \endgroup + }{}% + }% + }% + } % \end{macrocode} % \end{macro} % \begin{macro}{\iso@printdate@australian} @@ -1910,44 +2097,46 @@ % the actual date format. % \begin{macrocode} \def\iso@printdate@australian#1#2#3{% -% \end{macrocode} -% ISO date format: \verb|yyyy-\iso@printmonthday@australian| -% \begin{macrocode} - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@yearfour{\number#1}\iso@isodash}{% -% \end{macrocode} -% \LaTeX\ date format: \verb|yyyy/\iso@printmonthday@australian| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@yearfour{\number#1}/}{}% - }% - \fi - \iso@printmonthday@australian{\number#2}{\number#3}% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% + \iso@printmonthday@australian{\number#2}{\number#3}% % \end{macrocode} % Numeric date format: \verb|\iso@printmonthday@australian yyyy| % \begin{macrocode} - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{% - \iso@yearfour{\number#1}}{% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% % \end{macrocode} % Original date format: \verb|\iso@printmonthday@australian~yyyy| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{orig}}{% - ~\iso@yearfour{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% % \end{macrocode} % Short original date format: \verb|\iso@printmonthday@australian~yy| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% % \end{macrocode} % Short date format: \verb|\iso@printmonthday@australian yy| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{% - }}}% - }% - \fi + \ifthenelse{\equal{\iso@dateformat}{short}}{% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% } % \end{macrocode} % \end{macro} @@ -1968,8 +2157,8 @@ % \begin{macro}{\iso@daterange@...} % Define date-range commands for dialects of Australian. % \begin{macrocode} - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@australian}% + \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@australian}% % \end{macrocode} % \end{macro} % \begin{macro}{\iso@daterange@australian} @@ -1981,22 +2170,13 @@ % \end{macrocode} % ISO or \LaTeX\ date format. % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% % \end{macrocode} % Print the start date. % \begin{macrocode} - \csname iso@printdate@\iso@languagename\endcsname{% - #1}{#2}{#3}\iso@rangesign% -% \end{macrocode} -% If year and month are equal, only print the day of the end date. If -% only the year is equal, only print month and day of the end -% date. Otherwise print the whole end date. -% \begin{macrocode} - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@australian{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% % \end{macrocode} % Numeric, short, or original date format. % @@ -2006,18 +2186,22 @@ % \begin{macrocode} \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{% - \begingroup -% \edef\lday{#3}\def\day{\lday}% - \iso@printday{#3}\endgroup}{\iso@printday{#3}}% - }{\iso@printmonthday@australian{#2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% + \ifiso@doprintday + \iso@printday{#3}% + \else + \csname iso@printmonthday@\iso@languagename\endcsname{#2}{#3}% + \fi + }{% + \iso@printmonthday@australian{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + }% % \end{macrocode} % Print the end date. % \begin{macrocode} - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% - }{% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% }% } % \end{macrocode} @@ -2036,40 +2220,42 @@ % Third, handle American. % \begin{macrocode} }{% - \typeout{Define commands for American date format} + \typeout{Define commands for American date format} % \end{macrocode} % \begin{macro}{\iso@printmonthday@american} % Prints the month and the day given as two arguments % (\verb|{mm}{dd}|) in the current date format. % \begin{macrocode} \def\iso@printmonthday@american#1#2{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% % \end{macrocode} % Numeric and short date format: \verb|mm/dd/| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printmonth{#1}/\iso@printday{#2}\ifiso@printyear/\fi}{% -% \end{macrocode} -% ISO date format: \verb|mm-dd| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@printmonth{#1}\iso@isodash\iso@printday{#2}}{% -% \end{macrocode} -% \LaTeX\ date format: \verb|mm/dd| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@printmonth{#1}/\iso@printday{#2}}{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \iso@printmonth{#1}% + \ifiso@doprintday + /\iso@printday{#2}% + \fi + }{% % \end{macrocode} % Original date format: \verb|mmm d| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \begingroup% - \edef\lmonth{#1}% - \def\month{\lmonth}\month@english% - \endgroup - ~\iso@printday{#2}% - }{}}}% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \begingroup% + \edef\lmonth{#1}% + \def\month{\lmonth}% + \month@english% + \endgroup + \ifiso@doprintday + \iso@daysep\iso@printday{#2}% + \fi + }{}% + }% }% } % \end{macrocode} @@ -2079,42 +2265,48 @@ % the actual date format. % \begin{macrocode} \def\iso@printdate@american#1#2#3{% -% \end{macrocode} -% ISO date format: \verb|yyyy-\iso@printmonthday@american| -% \begin{macrocode} - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@yearfour{\number#1}\iso@isodash}{% -% \end{macrocode} -% \LaTeX\ date format: \verb|yyyy/\iso@printmonthday@american| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@yearfour{\number#1}/}{}}% - \fi - \iso@printmonthday@american{\number#2}{\number#3}% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% + \iso@printmonthday@american{\number#2}{\number#3}% % \end{macrocode} % Numeric date format: \verb|\iso@printmonthday@american yyyy| % \begin{macrocode} - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{% - \iso@yearfour{\number#1}}{% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% % \end{macrocode} % Original date format: \verb|\iso@printmonthday@american,~yyyy| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{orig}}{% - ,~\iso@yearfour{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \ifiso@doprintday,\fi + \iso@yearsep\iso@yearfour{\number#1}% + }{% % \end{macrocode} % Short original date format: \verb|\iso@printmonthday@american,~yyyy| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ,~\iso@twodigitsign\iso@yeartwo{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% + \ifiso@doprintday,\fi + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% % \end{macrocode} % Short date format: \verb|\iso@printmonthday@american yy| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{}}}% - }% - \fi + \ifthenelse{\equal{\iso@dateformat}{short}}{% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% } % \end{macrocode} % \end{macro} @@ -2135,8 +2327,8 @@ % \begin{macro}{\iso@daterange@...} % Define date-range commands for dialects of American. % \begin{macrocode} - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@american}% + \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@american}% % \end{macrocode} % \end{macro} % \begin{macro}{\iso@daterange@american} @@ -2148,23 +2340,13 @@ % \end{macrocode} % ISO or \LaTeX\ date format. % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% % \end{macrocode} % Print the start date. % \begin{macrocode} - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% - \iso@rangesign% -% \end{macrocode} -% If year and month are equal, only print the day of the end date. If -% only the year is equal, only print month and day of the end -% date. Otherwise print the whole end date. -% \begin{macrocode} - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@american{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% % \end{macrocode} % Original date format. % @@ -2172,22 +2354,34 @@ % only the year is equal, print \verb|mmm1 d1 to mmm2 d2, yyyy|. % Otherwise print the whole start and end date. % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{orig}\or + \ifthenelse{\equal{\iso@dateformat}{orig}\OR \equal{\iso@dateformat}{shortorig}}{% \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \iso@printmonthday@american{#2}{#3}\iso@rangesign% - \iso@printday{#6},~% + \iso@printmonthday@american{#2}{#3}% + \iso@rangesign + \ifiso@doprintday + \iso@printday{#6},\iso@yearsep\@empty + \else + \iso@printmonthday@american{#5}{#6}\iso@yearsep\@empty + \fi \ifthenelse{\equal{\iso@dateformat}{orig}}{% - \number#4}{\iso@twodigitsign\iso@yeartwo{\number#4}}% + \iso@yearfour{\number#4}% }{% - \iso@printmonthday@american{#2}{#3}\iso@rangesign% + \iso@twodigitsign\iso@yeartwo{\number#4}% + }% + }{% + \iso@printmonthday@american{#2}{#3}% + \iso@rangesign \csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}}}{% + #4}{#5}{#6}% + }% + }{% \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% \iso@rangesign% - \csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}}}{% + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% + }% + }{% % \end{macrocode} % Numeric or short date format. % @@ -2195,13 +2389,16 @@ % Otherwise print the whole end date. % \begin{macrocode} \ifthenelse{\equal{\number#1}{\number#4}}{% - \iso@printmonthday@american{#2}{#3}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% + \iso@printmonthday@american{#2}{#3}% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + }% % \end{macrocode} % Print the end date. % \begin{macrocode} - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}}% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% + }% }% } % \end{macrocode} @@ -2221,7 +2418,7 @@ } % \end{macrocode} % \begin{macro}{\iso@rangesign@...} -% Sets the word between start and end date in a date range to ``~to''. +% Sets the word between start and end date in a date range to `~to'. % \begin{macrocode} \expandafter\def\csname iso@rangesign@\CurrentOption\endcsname{~to~} % \end{macrocode} @@ -2273,38 +2470,62 @@ % \end{macrocode} % \begin{macrocode} \def\iso@printmonthday@french#1#2{% - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \ifiso@printyear\iso@isodash\fi\iso@printmonth{#1}% - \iso@isodash\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear/\fi\iso@printmonth{#1}/\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \begingroup - \edef\lday{#2}\edef\day{\lday}% - \edef\lmonth{#1}\def\month{\lmonth}% - \number\day\ifnum1=\day \noexpand\ier\fi~\month@french% - \endgroup - }{}}}}% - } + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \begingroup + \edef\lday{#2}\edef\day{\lday}% + \edef\lmonth{#1}\def\month{\lmonth}% + \ifiso@doprintday + \number\day\ifnum1=\day \noexpand\ier\fi\iso@monthsep + \fi + \month@french + \endgroup + }{}% + }% + }% +} % \end{macrocode} % \begin{macrocode} \def\iso@printdate@french#1#2#3{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% - \equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear\iso@yearfour{\number#1}\fi}{}% - \iso@printmonthday@french{\number#2}{\number#3}% - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{}}}}% - \fi + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% + \iso@printmonthday@french{\number#2}{\number#3}% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{short}}{% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% } % \end{macrocode} % \begin{macrocode} @@ -2314,35 +2535,41 @@ % \begin{macro}{\iso@daterange@...} % Define date-range commands for dialects. % \begin{macrocode} - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@french}% +\expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@french}% % \end{macrocode} % \end{macro} % \begin{macrocode} \def\iso@daterange@french#1#2#3#4#5#6{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% - \iso@rangesign% - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@french{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% % \end{macrocode} % \begin{macrocode} \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{% - \begingroup + \ifiso@doprintday + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \begingroup \edef\lday{#3}\edef\day{\lday}% \number\day\ifnum1=\day \noexpand\ier\fi - \endgroup}{\iso@printday{#3}}% - }{\iso@printmonthday@french{#2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% -}{% + \endgroup + }{% + \iso@printday{#3}% + }% + \else + \csname iso@printmonthday@\iso@languagename\endcsname{#2}{#3}% + \fi + }{% + \iso@printmonthday@french{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% }% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% + }% } % \end{macrocode} % \begin{macrocode} @@ -2393,6 +2620,8 @@ \def\iso@dmsepgerman{\,}% \def\iso@mylongsepgerman{~}% \def\iso@myshortsepgerman{\,}% +\def\iso@mylongsepnodaygerman{}% +\def\iso@myshortsepnodaygerman{}% % \end{macrocode} % \begin{macro}{\daymonthsepgerman} % Change space between day and month in numeric date formats for the @@ -2409,6 +2638,9 @@ \DeclareRobustCommand*\monthyearsepgerman[2]{% \def\iso@mylongsepgerman{#1}% \def\iso@myshortsepgerman{#2}} +\DeclareRobustCommand*\monthyearsepnodaygerman[2]{% + \def\iso@mylongsepnodaygerman{#1}% + \def\iso@myshortsepnodaygerman{#2}} % \end{macrocode} % \end{macro} % \changes{2.02}{2000/10/03}{Changed the umlauts to normal \TeX\ commands to @@ -2424,64 +2656,97 @@ % \end{macrocode} % \begin{macrocode} \@namedef{iso@printmonthday@\CurrentOption}#1#2{% - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}.\iso@dmsepgerman\iso@printmonth{#1}.}{% - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@printmonth{#1}\iso@isodash\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@printmonth{#1}/\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#2}.~\begingroup - \edef\lmonth{#1}% - \def\month{\lmonth}\csname month@\iso@languagename\endcsname% - \endgroup - }{}}}}% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}.\iso@dmsepgerman + \fi + \iso@printmonth{#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \ifiso@doprintday + \iso@printday{#2}.\iso@monthsep\@empty + \fi + \begingroup + \edef\lmonth{#1}% + \def\month{\lmonth}\csname month@\iso@languagename\endcsname% + \endgroup + }{}% + }% + }% } % \end{macrocode} % \begin{macrocode} \@namedef{iso@printdate@\CurrentOption}#1#2#3{% - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@yearfour{\number#1}\iso@isodash}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@yearfour{\number#1}/}{}}% - \fi - \csname iso@printmonthday@\iso@languagename\endcsname{% - \number#2}{\number#3}% - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{% - \iso@mylongsepgerman\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@myshortsepgerman\iso@yeartwo{\number#1}}{}}}}% - \fi + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% + \csname iso@printmonthday@\iso@languagename\endcsname{% + \number#2}{\number#3}% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + \ifiso@doprintday.\else/\fi + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \ifiso@doprintday + \iso@mylongsepgerman\@empty + \else + \iso@mylongsepnodaygerman\@empty + \fi + \iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@myshortsepgerman\@empty + \else + \iso@myshortsepnodaygerman\@empty + \fi + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% } % \end{macrocode} % \begin{macrocode} \@namedef{iso@daterange@\CurrentOption}#1#2#3#4#5#6{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% - \iso@rangesign% - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\csname iso@printmonthday@\iso@languagename\endcsname{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% % \end{macrocode} % \begin{macrocode} \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{% - \iso@printday{#3}}{\iso@printday{#3}}.% - }{\csname iso@printmonthday@\iso@languagename\endcsname{% - #2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% + \ifiso@doprintday + \iso@printday{#3}.% + \else + \csname iso@printmonthday@\iso@languagename\endcsname{#2}{#3}% + \fi + }{% + \csname iso@printmonthday@\iso@languagename\endcsname{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + }% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% }% } % \end{macrocode} @@ -2595,38 +2860,63 @@ % \end{macrocode} % \begin{macrocode} \def\iso@printmonthday@italian#1#2{% - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \ifiso@printyear\iso@isodash\fi\iso@printmonth{#1}% - \iso@isodash\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear/\fi\iso@printmonth{#1}/\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \begingroup - \edef\lday{#2}\edef\day{\lday}% - \edef\lmonth{#1}\def\month{\lmonth}% - \number\day\ifnum1=\day \noexpand\textordmasculine\fi~\month@italian% - \endgroup - }{}}}}% - } + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \begingroup + \edef\lday{#2}\edef\day{\lday}% + \edef\lmonth{#1}\def\month{\lmonth}% + \ifiso@doprintday + \number\day\ifnum1=\day \noexpand\textordmasculine\fi + \iso@monthsep + \fi + \month@italian + \endgroup + }{}% + }% + }% +} % \end{macrocode} % \begin{macrocode} \def\iso@printdate@italian#1#2#3{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear\iso@yearfour{\number#1}\fi}{}% - \iso@printmonthday@italian{\number#2}{\number#3}% - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{}}}}% - \fi + \iso@printdate@int{#1}{#2}{#3}% + }{% + \iso@printmonthday@italian{\number#2}{\number#3}% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{short}}{% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% } % \end{macrocode} % \begin{macrocode} @@ -2636,35 +2926,41 @@ % \begin{macro}{\iso@daterange@...} % Define date-range commands for dialects. % \begin{macrocode} - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@italian}% +\expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@italian}% % \end{macrocode} % \end{macro} % \begin{macrocode} \def\iso@daterange@italian#1#2#3#4#5#6{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% - \iso@rangesign% - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@italian{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% % \end{macrocode} % \begin{macrocode} \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{% - \begingroup + \ifiso@doprintday + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \begingroup \edef\lday{#3}\edef\day{\lday}% \number\day\ifnum1=\day \noexpand\textordmasculine\fi - \endgroup}{\iso@printday{#3}}% - }{\iso@printmonthday@italian{#2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% -}{% + \endgroup + }{% + \iso@printday{#3}% + }% + \else + \iso@printmonthday@italian{#2}{#3}% + \fi + }{% + \iso@printmonthday@italian{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% }% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% + }% } % \end{macrocode} % \begin{macrocode} @@ -2718,86 +3014,103 @@ % Prints the month and the day given as two arguments % (\verb|{mm}{dd}|) in the current date format. % \begin{macrocode} - \def\iso@printmonthday@norsk#1#2{% +\def\iso@printmonthday@norsk#1#2{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% % \end{macrocode} % Numeric and short date format: \verb|dd/mm/| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% -% \end{macrocode} -% ISO date format: \verb|-mm-dd| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \ifiso@printyear\iso@isodash\fi - \iso@printmonth{#1}\iso@isodash\iso@printday{#2}}{% -% \end{macrocode} -% \LaTeX\ date format: \verb|/mm/dd| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear/\fi\iso@printmonth{#1}/\iso@printday{#2}}{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% % \end{macrocode} % Original date format: \verb|d. mmm| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#2}.~\begingroup - \edef\lmonth{#1}\def\month{\lmonth}% - \month@norsk% - \endgroup - }{}}}}% - } + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \ifiso@doprintday + \iso@printday{#2}.\iso@monthsep + \fi + \begingroup + \edef\lmonth{#1}\def\month{\lmonth}% + \month@norsk% + \endgroup + }{}% + }% + }% +} % \end{macrocode} % \end{macro} % \begin{macro}{\iso@printdate@norsk} % Prints the date given as three arguments (\verb|{yyyy}{mm}{dd}|) in % the actual date format % \begin{macrocode} - \def\iso@printdate@norsk#1#2#3{% +\def\iso@printdate@norsk#1#2#3{% % \end{macrocode} % ISO or \LaTeX date format: \verb|yyyy\iso@printmonthday@norsk| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}\or% - \equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear\iso@yearfour{\number#1}\fi}{}% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% \iso@printmonthday@norsk{\number#2}{\number#3}% % \end{macrocode} % numeric date format: \verb|\iso@printmonthday@norsk yyyy| % \begin{macrocode} \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{\iso@yearfour{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% % \end{macrocode} % original date format: \verb|\iso@printmonthday@norsk~yyyy| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% % \end{macrocode} % short original date format: \verb|\iso@printmonthday@norsk~yyyy| % \begin{macrocode} \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% % \end{macrocode} % short date format: \verb|\iso@printmonthday@norsk yy| % \begin{macrocode} \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{% - }}}}% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% \fi - } + }% +} % \end{macrocode} % \end{macro} % \begin{macro}{\iso@datenorsk} % This command redefines the \cs{today} command to print in the % actual date format. % \begin{macrocode} - \def\iso@datenorsk{% - \def\today{\iso@printdate@norsk{\year}{\month}{\day}}}% +\def\iso@datenorsk{% + \def\today{\iso@printdate@norsk{\year}{\month}{\day}}}% % \end{macrocode} % \end{macro} % \begin{macro}{\iso@daterange@...} % Define date-range commands for dialects. % \begin{macrocode} - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@norsk}% +\expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@norsk}% % \end{macrocode} % \end{macro} % \begin{macro}{\iso@daterange@norsk} @@ -2809,22 +3122,10 @@ % \end{macrocode} % ISO or \LaTeX\ date format. % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% -% \end{macrocode} -% Print the start date. -% \begin{macrocode} - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% - \iso@rangesign% -% \end{macrocode} -% If year and month are equal, only print the day of the end date. If -% only the year is equal, only print month and day of the end -% date. Otherwise print the whole end date. -% \begin{macrocode} - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@norsk{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% % \end{macrocode} % Numeric, short, or original date format. % @@ -2834,23 +3135,33 @@ % \begin{macrocode} \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#3}.}{\iso@printday{#3}}% - }{\iso@printmonthday@norsk{#2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% + \ifiso@doprintday + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \iso@printday{#3}.% + }{% + \iso@printday{#3}% + }% + \else + \iso@printmonthday@norsk{#2}{#3}% + \fi + }{% + \iso@printmonthday@norsk{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + }% % \end{macrocode} % Print the end date. % \begin{macrocode} - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% - }{% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% }% } % \end{macrocode} % \end{macro} % \begin{macro}{\iso@rangesign@norsk} -% Sets the word between start and end date in a date range to ``~til~''. +% Sets the word between start and end date in a date range to `~til~'. % \begin{macrocode} \expandafter\def\csname iso@rangesign@\CurrentOption\endcsname{~til~} % \end{macrocode} @@ -2908,86 +3219,103 @@ % Prints the month and the day given as two arguments % (\verb|{mm}{dd}|) in the current date format. % \begin{macrocode} - \def\iso@printmonthday@swedish#1#2{% +\def\iso@printmonthday@swedish#1#2{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% % \end{macrocode} % Numeric and short date format: \verb|dd/mm/| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% -% \end{macrocode} -% ISO date format: \verb|-mm-dd| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \ifiso@printyear\iso@isodash\fi\iso@printmonth{#1}% - \iso@isodash\iso@printday{#2}}{% -% \end{macrocode} -% \LaTeX\ date format: \verb|/mm/dd| -% \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear/\fi\iso@printmonth{#1}/\iso@printday{#2}}{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% % \end{macrocode} % Original date format: \verb|d. mmm| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#2}.~\begingroup - \edef\lmonth{#1}\def\month{\lmonth}% - \month@swedish% - \endgroup - }{}}}}% - } + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \ifiso@doprintday + \iso@printday{#2}.\iso@monthsep + \fi + \begingroup + \edef\lmonth{#1}\def\month{\lmonth}% + \month@swedish% + \endgroup + }{}% + }% + }% +} % \end{macrocode} % \end{macro} % \begin{macro}{\iso@printdate@swedish} % Prints the date given as three arguments (\verb|{yyyy}{mm}{dd}|) in % the actual date format % \begin{macrocode} - \def\iso@printdate@swedish#1#2#3{% +\def\iso@printdate@swedish#1#2#3{% % \end{macrocode} % ISO or \LaTeX date format: \verb|yyyy\iso@printmonthday@swedish| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}\or% - \equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear\iso@yearfour{\number#1}\fi}{}% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% \iso@printmonthday@swedish{\number#2}{\number#3}% % \end{macrocode} % numeric date format: \verb|\iso@printmonthday@swedish yyyy| % \begin{macrocode} \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{\iso@yearfour{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% % \end{macrocode} % original date format: \verb|\iso@printmonthday@swedish~yyyy| % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% % \end{macrocode} % short original date format: \verb|\iso@printmonthday@swedish~yy| % \begin{macrocode} \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% % \end{macrocode} % short date format: \verb|\iso@printmonthday@swedish yy| % \begin{macrocode} \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{% - }}}}% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% \fi - } + }% +} % \end{macrocode} % \end{macro} % \begin{macro}{\iso@dateswedish} % This command redefines the \cs{today} command to print in the % actual date format. % \begin{macrocode} - \def\iso@dateswedish{% - \def\today{\iso@printdate@swedish{\year}{\month}{\day}}}% +\def\iso@dateswedish{% + \def\today{\iso@printdate@swedish{\year}{\month}{\day}}}% % \end{macrocode} % \end{macro} % \begin{macro}{\iso@daterange@...} % Define date-range commands for dialects. % \begin{macrocode} - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@swedish}% +\expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@swedish}% % \end{macrocode} % \end{macro} % \begin{macro}{\iso@daterange@swedish} @@ -2999,22 +3327,10 @@ % \end{macrocode} % ISO or \LaTeX\ date format. % \begin{macrocode} - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% -% \end{macrocode} -% Print the start date. -% \begin{macrocode} - \csname iso@printdate@\iso@languagename\endcsname{% - #1}{#2}{#3}\iso@rangesign% -% \end{macrocode} -% If year and month are equal, only print the day of the end date. If -% only the year is equal, only print month and day of the end -% date. Otherwise print the whole end date. -% \begin{macrocode} - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@swedish{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% % \end{macrocode} % Numeric, short, or original date format. % @@ -3024,24 +3340,33 @@ % \begin{macrocode} \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#3}.}{\iso@printday{#3}}% - }{\iso@printmonthday@swedish{#2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{% - #1}{#2}{#3}}% + \ifiso@doprintday + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \iso@printday{#3}.% + }{% + \iso@printday{#3}% + }% + \else + \iso@printmonthday@swedish{#2}{#3}% + \fi + }{% + \iso@printmonthday@swedish{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + }% % \end{macrocode} % Print the end date. % \begin{macrocode} - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% -}{% - }% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% + }% } % \end{macrocode} % \end{macro} % \begin{macro}{\iso@rangesign@swedish} -% Sets the word between start and end date in a date range to ``~till~''. +% Sets the word between start and end date in a date range to `~till~'. % \begin{macrocode} \expandafter\def\csname iso@rangesign@\CurrentOption\endcsname{~till~} % \end{macrocode} diff --git a/Master/texmf-dist/source/latex/isodate/isodate.ins b/Master/texmf-dist/source/latex/isodate/isodate.ins index 81aff73ea62..f9b1dfa823c 100644 --- a/Master/texmf-dist/source/latex/isodate/isodate.ins +++ b/Master/texmf-dist/source/latex/isodate/isodate.ins @@ -4,7 +4,7 @@ isodate package - Copyright 2000--2005 Harald Harders + Copyright 2000--2010 Harald Harders This program can be redistributed and/or modified under the terms of the LaTeX Project Public License Distributed from CTAN diff --git a/Master/texmf-dist/tex/latex/isodate/danish.idf b/Master/texmf-dist/tex/latex/isodate/danish.idf index bcf1a2bc9a4..9d06fdefda7 100644 --- a/Master/texmf-dist/tex/latex/isodate/danish.idf +++ b/Master/texmf-dist/tex/latex/isodate/danish.idf @@ -8,7 +8,7 @@ %% %% isodate package %% -%% Copyright 2000--2005 Harald Harders +%% Copyright 2000--2010 Harald Harders %% %% This program can be redistributed and/or modified under the terms %% of the LaTeX Project Public License Distributed from CTAN @@ -18,74 +18,96 @@ %% h.harders@tu-bs.de %% \ProvidesFile{danish.idf} - [2005/04/15 v2.28 Language definitions for isodate package (HH)] + [2010/01/03 v2.30 Language definitions for isodate package (HH)] \let\iso@languageloaded\active \typeout{Define commands for Danish date format} \def\month@danish{\ifcase\month\or januar\or februar\or marts\or april\or maj\or juni\or juli\or august\or september\or oktober\or november\or december\fi} - \def\iso@printmonthday@danish#1#2{% - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \ifiso@printyear\iso@isodash\fi\iso@printmonth{#1}% - \iso@isodash\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear/\fi\iso@printmonth{#1}/\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#2}.~\begingroup - \edef\lmonth{#1}\def\month{\lmonth}% - \month@danish% - \endgroup - }{}}}}% - } - \def\iso@printdate@danish#1#2#3{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% - \equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear - \number#1% - \fi}{}% +\def\iso@printmonthday@danish#1#2{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \ifiso@doprintday + \iso@printday{#2}.\iso@monthsep + \fi + \begingroup + \edef\lmonth{#1}\def\month{\lmonth}% + \month@danish% + \endgroup + }{}% + }% + }% +} +\def\iso@printdate@danish#1#2#3{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% \iso@printmonthday@danish{\number#2}{\number#3}% \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{% - }}}}% - \fi - } - \def\iso@datedanish{% - \def\today{\iso@printdate@danish{\year}{\month}{\day}}}% - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@danish}% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% +} +\def\iso@datedanish{% + \def\today{\iso@printdate@danish{\year}{\month}{\day}}}% +\expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@danish}% \def\iso@daterange@danish#1#2#3#4#5#6{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \csname iso@printdate@\iso@languagename\endcsname{% - #1}{#2}{#3}\iso@rangesign% - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@danish{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% }{% \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#3}.}{\iso@printday{#3}}% - }{\iso@printmonthday@danish{#2}{#3}}}{% - \begingroup - \printyearon - \csname iso@printdate@\iso@languagename\endcsname{% - #1}{#2}{#3}% - \endgroup}% - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% - }{% + \ifiso@doprintday + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \iso@printday{#3}.% + }{% + \iso@printday{#3}% + }% + \else + \iso@printmonthday@danish{#2}{#3}% + \fi + }{% + \iso@printmonthday@danish{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + }% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% }% } \expandafter\def\csname iso@rangesign@\CurrentOption\endcsname{~til~} diff --git a/Master/texmf-dist/tex/latex/isodate/english.idf b/Master/texmf-dist/tex/latex/isodate/english.idf index 204600fcf11..8383824ea23 100644 --- a/Master/texmf-dist/tex/latex/isodate/english.idf +++ b/Master/texmf-dist/tex/latex/isodate/english.idf @@ -8,7 +8,7 @@ %% %% isodate package %% -%% Copyright 2000--2005 Harald Harders +%% Copyright 2000--2010 Harald Harders %% %% This program can be redistributed and/or modified under the terms %% of the LaTeX Project Public License Distributed from CTAN @@ -18,15 +18,15 @@ %% h.harders@tu-bs.de %% \ProvidesFile{english.idf} - [2005/04/15 v2.28 Language definitions for isodate package (HH)] + [2010/01/03 v2.30 Language definitions for isodate package (HH)] \let\iso@languageloaded\active \def\month@english{\ifcase\month\or January\or February\or March\or April\or May\or June\or July\or August\or September\or October\or November\or December\fi} -\ifthenelse{\equal{\CurrentOption}{english}\or - \equal{\CurrentOption}{british}\or +\ifthenelse{\equal{\CurrentOption}{english}\OR + \equal{\CurrentOption}{british}\OR \equal{\CurrentOption}{UKenglish}}{% -\typeout{Define commands for English date format} + \typeout{Define commands for English date format} \def\day@english{% \ifiso@cleanlook \day @@ -43,38 +43,60 @@ \fi } \def\iso@printmonthday@english#1#2{% - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@printmonth{#1}\iso@isodash\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@printmonth{#1}/\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \begingroup - \edef\lday{#2}\def\day{\lday}% - \edef\lmonth{#1}\def\month{\lmonth}% - \day@english~\month@english% - \endgroup - }{}}}}% - } - \def\iso@printdate@english#1#2#3{% - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \ifiso@printyear\iso@yearfour{\number#1}\iso@isodash\fi}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear\iso@yearfour{\number#1}/\fi}{}}% - \iso@printmonthday@english{\number#2}{\number#3}% - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{% - }}}% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \begingroup + \edef\lday{#2}\def\day{\lday}% + \edef\lmonth{#1}\def\month{\lmonth}% + \ifiso@doprintday + \day@english\iso@monthsep\@empty + \fi + \month@english + \endgroup + }{}% }% - \fi + }% + } + \def\iso@printdate@english#1#2#3{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% + \iso@printmonthday@english{\number#2}{\number#3}% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{short}}{% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% } \def\iso@printdate@UKenglish{\iso@printdate@english} \def\iso@printdate@british{\iso@printdate@english} @@ -83,174 +105,229 @@ \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% \iso@daterange@english}% \def\iso@daterange@english#1#2#3#4#5#6{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \csname iso@printdate@\iso@languagename\endcsname{% - #1}{#2}{#3}\iso@rangesign% - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@english{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \begingroup + \ifiso@doprintday + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \begingroup \edef\lday{#3}\def\day{\lday}% - \day@english\endgroup}{\iso@printday{#3}}% - }{\iso@printmonthday@english{#2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% - }{% + \day@english + \endgroup + }{% + \iso@printday{#3}% + }% + \else + \csname iso@printmonthday@\iso@languagename\endcsname{#2}{#3}% + \fi + }{% + \csname iso@printmonthday@\iso@languagename\endcsname{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + }% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% }% } \def\iso@languagename{english}% }{% - \ifthenelse{\equal{\CurrentOption}{australian}\or% + \ifthenelse{\equal{\CurrentOption}{australian}\OR \equal{\CurrentOption}{newzealand}}{% - \typeout{Define commands for Australian date format} + \typeout{Define commands for Australian date format} \def\iso@printmonthday@australian#1#2{% - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@printmonth{#1}\iso@isodash\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@printmonth{#1}/\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \begingroup - \edef\lmonth{#1}\def\month{\lmonth}% - \iso@printday{#2}~\month@english% - \endgroup - }{}}}}% - } - \def\iso@printdate@australian#1#2#3{% - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@yearfour{\number#1}\iso@isodash}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@yearfour{\number#1}/}{}% - }% - \fi - \iso@printmonthday@australian{\number#2}{\number#3}% - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{% - \iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{% - ~\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{% - }}}% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \begingroup + \edef\lmonth{#1}\def\month{\lmonth}% + \ifiso@doprintday + \iso@printday{#2}\iso@monthsep\@empty + \fi + \month@english + \endgroup + }{}% }% - \fi + }% + } + \def\iso@printdate@australian#1#2#3{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% + \iso@printmonthday@australian{\number#2}{\number#3}% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{short}}{% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% } \def\iso@printdate@newzealand{\iso@printdate@australian} \def\iso@dateaustralian{% \def\today{\iso@printdate@australian{\year}{\month}{\day}}}% - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@australian}% + \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@australian}% \def\iso@daterange@australian#1#2#3#4#5#6{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \csname iso@printdate@\iso@languagename\endcsname{% - #1}{#2}{#3}\iso@rangesign% - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@australian{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{% - \begingroup - \iso@printday{#3}\endgroup}{\iso@printday{#3}}% - }{\iso@printmonthday@australian{#2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% - }{% + \ifiso@doprintday + \iso@printday{#3}% + \else + \csname iso@printmonthday@\iso@languagename\endcsname{#2}{#3}% + \fi + }{% + \iso@printmonthday@australian{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + }% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% }% } \def\iso@languagename{australian}% }{% - \typeout{Define commands for American date format} + \typeout{Define commands for American date format} \def\iso@printmonthday@american#1#2{% - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printmonth{#1}/\iso@printday{#2}\ifiso@printyear/\fi}{% - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@printmonth{#1}\iso@isodash\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@printmonth{#1}/\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \begingroup% - \edef\lmonth{#1}% - \def\month{\lmonth}\month@english% - \endgroup - ~\iso@printday{#2}% - }{}}}% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \iso@printmonth{#1}% + \ifiso@doprintday + /\iso@printday{#2}% + \fi + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \begingroup% + \edef\lmonth{#1}% + \def\month{\lmonth}% + \month@english% + \endgroup + \ifiso@doprintday + \iso@daysep\iso@printday{#2}% + \fi + }{}% + }% }% } \def\iso@printdate@american#1#2#3{% - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@yearfour{\number#1}\iso@isodash}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@yearfour{\number#1}/}{}}% - \fi - \iso@printmonthday@american{\number#2}{\number#3}% - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{% - \iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{% - ,~\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ,~\iso@twodigitsign\iso@yeartwo{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{}}}% - }% - \fi + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% + \iso@printmonthday@american{\number#2}{\number#3}% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \ifiso@doprintday,\fi + \iso@yearsep\iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% + \ifiso@doprintday,\fi + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{short}}{% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% } \def\iso@printdate@USenglish{\iso@printdate@american} \def\iso@dateamerican{% \def\today{\iso@printdate@american{\year}{\month}{\day}}}% - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@american}% + \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@american}% \def\iso@daterange@american#1#2#3#4#5#6{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% - \iso@rangesign% - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@american{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR \equal{\iso@dateformat}{shortorig}}{% \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \iso@printmonthday@american{#2}{#3}\iso@rangesign% - \iso@printday{#6},~% + \iso@printmonthday@american{#2}{#3}% + \iso@rangesign + \ifiso@doprintday + \iso@printday{#6},\iso@yearsep\@empty + \else + \iso@printmonthday@american{#5}{#6}\iso@yearsep\@empty + \fi \ifthenelse{\equal{\iso@dateformat}{orig}}{% - \number#4}{\iso@twodigitsign\iso@yeartwo{\number#4}}% + \iso@yearfour{\number#4}% }{% - \iso@printmonthday@american{#2}{#3}\iso@rangesign% + \iso@twodigitsign\iso@yeartwo{\number#4}% + }% + }{% + \iso@printmonthday@american{#2}{#3}% + \iso@rangesign \csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}}}{% + #4}{#5}{#6}% + }% + }{% \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% \iso@rangesign% - \csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}}}{% + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% + }% + }{% \ifthenelse{\equal{\number#1}{\number#4}}{% - \iso@printmonthday@american{#2}{#3}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}}% + \iso@printmonthday@american{#2}{#3}% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + }% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% + }% }% } \def\iso@languagename{american}% diff --git a/Master/texmf-dist/tex/latex/isodate/french.idf b/Master/texmf-dist/tex/latex/isodate/french.idf index 2a85daaf1bf..16f9108ae0b 100644 --- a/Master/texmf-dist/tex/latex/isodate/french.idf +++ b/Master/texmf-dist/tex/latex/isodate/french.idf @@ -8,7 +8,7 @@ %% %% isodate package %% -%% Copyright 2000--2005 Harald Harders +%% Copyright 2000--2010 Harald Harders %% %% This program can be redistributed and/or modified under the terms %% of the LaTeX Project Public License Distributed from CTAN @@ -18,7 +18,7 @@ %% h.harders@tu-bs.de %% \ProvidesFile{french.idf} - [2005/04/15 v2.28 Language definitions for isodate package (HH)] + [2010/01/03 v2.30 Language definitions for isodate package (HH)] \let\iso@languageloaded\active \typeout{Define commands for French date format} \def\month@french{\ifcase\month\or @@ -26,63 +26,93 @@ juillet\or ao\^ut\or septembre\or octobre\or novembre\or d\'ecembre\fi} \def\iso@printmonthday@french#1#2{% - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \ifiso@printyear\iso@isodash\fi\iso@printmonth{#1}% - \iso@isodash\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear/\fi\iso@printmonth{#1}/\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \begingroup - \edef\lday{#2}\edef\day{\lday}% - \edef\lmonth{#1}\def\month{\lmonth}% - \number\day\ifnum1=\day \noexpand\ier\fi~\month@french% - \endgroup - }{}}}}% - } + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \begingroup + \edef\lday{#2}\edef\day{\lday}% + \edef\lmonth{#1}\def\month{\lmonth}% + \ifiso@doprintday + \number\day\ifnum1=\day \noexpand\ier\fi\iso@monthsep + \fi + \month@french + \endgroup + }{}% + }% + }% +} \def\iso@printdate@french#1#2#3{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% - \equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear\iso@yearfour{\number#1}\fi}{}% - \iso@printmonthday@french{\number#2}{\number#3}% - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{}}}}% - \fi + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% + \iso@printmonthday@french{\number#2}{\number#3}% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{short}}{% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% } \def\iso@datefrench{% \def\today{\iso@printdate@french{\year}{\month}{\day}}}% - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@french}% +\expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@french}% \def\iso@daterange@french#1#2#3#4#5#6{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% - \iso@rangesign% - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@french{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{% - \begingroup + \ifiso@doprintday + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \begingroup \edef\lday{#3}\edef\day{\lday}% \number\day\ifnum1=\day \noexpand\ier\fi - \endgroup}{\iso@printday{#3}}% - }{\iso@printmonthday@french{#2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% -}{% + \endgroup + }{% + \iso@printday{#3}% + }% + \else + \csname iso@printmonthday@\iso@languagename\endcsname{#2}{#3}% + \fi + }{% + \iso@printmonthday@french{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% }% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% + }% } \expandafter\def\csname iso@rangesign@\CurrentOption\endcsname{~au~} \def\iso@languagename{french}% diff --git a/Master/texmf-dist/tex/latex/isodate/german.idf b/Master/texmf-dist/tex/latex/isodate/german.idf index a9c08a5bb41..cd9193425a7 100644 --- a/Master/texmf-dist/tex/latex/isodate/german.idf +++ b/Master/texmf-dist/tex/latex/isodate/german.idf @@ -8,7 +8,7 @@ %% %% isodate package %% -%% Copyright 2000--2005 Harald Harders +%% Copyright 2000--2010 Harald Harders %% %% This program can be redistributed and/or modified under the terms %% of the LaTeX Project Public License Distributed from CTAN @@ -18,16 +18,21 @@ %% h.harders@tu-bs.de %% \ProvidesFile{german.idf} - [2005/04/15 v2.28 Language definitions for isodate package (HH)] + [2010/01/03 v2.30 Language definitions for isodate package (HH)] \let\iso@languageloaded\active \typeout{Define commands for German date format (\CurrentOption)} \def\iso@dmsepgerman{\,}% \def\iso@mylongsepgerman{~}% \def\iso@myshortsepgerman{\,}% +\def\iso@mylongsepnodaygerman{}% +\def\iso@myshortsepnodaygerman{}% \DeclareRobustCommand*\daymonthsepgerman[1]{\def\iso@dmsepgerman{#1}} \DeclareRobustCommand*\monthyearsepgerman[2]{% \def\iso@mylongsepgerman{#1}% \def\iso@myshortsepgerman{#2}} +\DeclareRobustCommand*\monthyearsepnodaygerman[2]{% + \def\iso@mylongsepnodaygerman{#1}% + \def\iso@myshortsepnodaygerman{#2}} \def\month@german{\ifcase\month\or Januar\or Februar\or M\"arz\or April\or Mai\or Juni\or Juli\or August\or September\or Oktober\or November\or Dezember\fi} @@ -36,58 +41,91 @@ J\"anner\else \month@german\fi} \def\month@naustrian{\month@austrian} \@namedef{iso@printmonthday@\CurrentOption}#1#2{% - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}.\iso@dmsepgerman\iso@printmonth{#1}.}{% - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@printmonth{#1}\iso@isodash\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@printmonth{#1}/\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#2}.~\begingroup - \edef\lmonth{#1}% - \def\month{\lmonth}\csname month@\iso@languagename\endcsname% - \endgroup - }{}}}}% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}.\iso@dmsepgerman + \fi + \iso@printmonth{#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \ifiso@doprintday + \iso@printday{#2}.\iso@monthsep\@empty + \fi + \begingroup + \edef\lmonth{#1}% + \def\month{\lmonth}\csname month@\iso@languagename\endcsname% + \endgroup + }{}% + }% + }% } \@namedef{iso@printdate@\CurrentOption}#1#2#3{% - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \iso@yearfour{\number#1}\iso@isodash}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \iso@yearfour{\number#1}/}{}}% - \fi - \csname iso@printmonthday@\iso@languagename\endcsname{% - \number#2}{\number#3}% - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{% - \iso@mylongsepgerman\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@myshortsepgerman\iso@yeartwo{\number#1}}{}}}}% - \fi + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% + \csname iso@printmonthday@\iso@languagename\endcsname{% + \number#2}{\number#3}% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + \ifiso@doprintday.\else/\fi + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \ifiso@doprintday + \iso@mylongsepgerman\@empty + \else + \iso@mylongsepnodaygerman\@empty + \fi + \iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@myshortsepgerman\@empty + \else + \iso@myshortsepnodaygerman\@empty + \fi + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% } \@namedef{iso@daterange@\CurrentOption}#1#2#3#4#5#6{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% - \iso@rangesign% - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\csname iso@printmonthday@\iso@languagename\endcsname{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{% - \iso@printday{#3}}{\iso@printday{#3}}.% - }{\csname iso@printmonthday@\iso@languagename\endcsname{% - #2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% + \ifiso@doprintday + \iso@printday{#3}.% + \else + \csname iso@printmonthday@\iso@languagename\endcsname{#2}{#3}% + \fi + }{% + \csname iso@printmonthday@\iso@languagename\endcsname{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + }% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% }% } \expandafter\def\csname iso@rangesign@\CurrentOption\endcsname{~bis~} diff --git a/Master/texmf-dist/tex/latex/isodate/isodate.sty b/Master/texmf-dist/tex/latex/isodate/isodate.sty index 8d631358199..b37457a8da7 100644 --- a/Master/texmf-dist/tex/latex/isodate/isodate.sty +++ b/Master/texmf-dist/tex/latex/isodate/isodate.sty @@ -8,7 +8,7 @@ %% %% isodate package %% -%% Copyright 2000--2005 Harald Harders +%% Copyright 2000--2010 Harald Harders %% %% This program can be redistributed and/or modified under the terms %% of the LaTeX Project Public License Distributed from CTAN @@ -19,7 +19,7 @@ %% \NeedsTeXFormat{LaTeX2e} \ProvidesPackage{isodate} - [2005/04/15 v2.28 Print dates with different formats (HH)] + [2010/01/03 v2.30 Print dates with different formats (HH)] \RequirePackage{ifthen} \IfFileExists{substr.sty}{\RequirePackage{substr}% }{\PackageError{isodate.sty}{Package file substr.sty not found} @@ -40,6 +40,8 @@ \DeclareOption{shortroman}{\AtEndOfPackage{\shortromandate}} \DeclareOption{cleanlook}{\AtEndOfPackage{\cleanlookdateon}} \DeclareOption{nocleanlook}{\AtEndOfPackage{\cleanlookdateoff}} +\DeclareOption{printdayoff}{\AtEndOfPackage{\printdayoff}} +\DeclareOption{printdayon}{\AtEndOfPackage{\printdayon}} \DeclareOption{inputenglish}{\AtEndOfPackage{\dateinputformat{english}}} \DeclareOption{inputbritish}{\AtEndOfPackage{\dateinputformat{english}}} \DeclareOption{inputUKenglish}{\AtEndOfPackage{\dateinputformat{english}}} @@ -73,7 +75,7 @@ Isodate definition file \CurrentOption.idf not found}{% Maybe you misspelled the language option?}}% } -\ExecuteOptions{orig,nocleanlook} +\ExecuteOptions{orig,nocleanlook,printdayon} \ProcessOptions* \ifx\iso@languageloaded\@undefined \PackageError{isodate}{% @@ -119,20 +121,20 @@ \def\iso@dateformat{numeric} \DeclareRobustCommand*\dateinputformat[1]{% \ifthenelse{% - \equal{#1}{english}\or - \equal{#1}{british}\or + \equal{#1}{english}\OR + \equal{#1}{british}\OR \equal{#1}{UKenglish}}{% \def\iso@inputformat{english}% }{% \ifthenelse{% - \equal{#1}{american}\or + \equal{#1}{american}\OR \equal{#1}{USenglish}}{% \def\iso@inputformat{american}% }{% \ifthenelse{% - \equal{#1}{tex}\or - \equal{#1}{TeX}\or - \equal{#1}{latex}\or + \equal{#1}{tex}\OR + \equal{#1}{TeX}\OR + \equal{#1}{latex}\OR \equal{#1}{LaTeX}}{% \def\iso@inputformat{tex}% }{% @@ -200,10 +202,20 @@ \DeclareRobustCommand*\printyearon{\iso@printyeartrue} \DeclareRobustCommand*\printyearoff{\iso@printyearfalse} \printyearon +\newif\ifiso@doprintday +\DeclareRobustCommand*\printdayon{\iso@doprintdaytrue} +\DeclareRobustCommand*\printdayoff{\iso@doprintdayfalse} +\printdayon \newif\ifiso@cleanlook \DeclareRobustCommand*\cleanlookdateon{\iso@cleanlooktrue} \DeclareRobustCommand*\cleanlookdateoff{\iso@cleanlookfalse} \cleanlookdateoff +\newcommand*\iso@daysep{~} +\newcommand*\iso@monthsep{~} +\newcommand*\iso@yearsep{~} +\DeclareRobustCommand*\isospacebeforeday[1]{\def\iso@daysep{#1}} +\DeclareRobustCommand*\isospacebeforemonth[1]{\def\iso@monthsep{#1}} +\DeclareRobustCommand*\isospacebeforeyear[1]{\def\iso@yearsep{#1}} \newcommand*\iso@printdate[3]{% \begingroup% \@ifundefined{iso@printdate@\iso@languagename}{% @@ -266,6 +278,65 @@ \protect~ inside the argument.}% }} \def\iso@input@TeX#1/#2/#3\@empty{\iso@printdate{#1}{#2}{#3}} +\def\iso@printmonthday@int#1#2{% + \ifthenelse{\equal{\iso@dateformat}{iso}}{% + \iso@printmonth{#1}% + \ifiso@doprintday + \iso@isodash\iso@printday{#2}% + \fi + }{% + \ifthenelse{\equal{\iso@dateformat}{TeX}}{% + \iso@printmonth{#1}% + \ifiso@doprintday + /\iso@printday{#2}% + \fi + }{% + \PackageError{isodate.sty}{\csname iso@printmonthday\endcsname: + Invalid date format `\iso@dateformat'}{Internal error. Please + report to the package author.} + }% + }% +} +\def\iso@printdate@int#1#2#3{% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{iso}}{% + \iso@yearfour{\number#1}\iso@isodash% + }{% + \ifthenelse{\equal{\iso@dateformat}{TeX}}{% + \iso@yearfour{\number#1}/% + }{% + \PackageError{isodate.sty}{\csname iso@printmonthday\endcsname: + Invalid date format `\iso@dateformat'}{Internal error. Please + report to the package author.} + }% + }% + \fi + \csname iso@printmonthday@int\endcsname{\number#2}{\number#3}% +} +\def\iso@daterange@int#1#2#3#4#5#6{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + \iso@rangesign% + \ifthenelse{\equal{\number#1}{\number#4}}{% + \ifthenelse{\equal{\number#2}{\number#5}}{% + \ifiso@doprintday + \iso@printday{#6}% + \else + \iso@printmonthday@int{#5}{#6}% + \fi + }{% + \iso@printmonthday@int{#5}{#6}% + }% + }{% + \iso@printdate@int{#4}{#5}{#6}% + }% + }{% + \PackageError{isodate.sty}{\csname iso@printmonthday\endcsname: + Invalid date format `\iso@dateformat'}{Internal error. Please + report to the package author.} + }% +} \DeclareRobustCommand*\daterange[2]{% \edef\iso@date{#1}% \edef\iso@@date{#2}% @@ -276,11 +347,11 @@ \SubStringsToCounter{iso@@slash}{/}{\iso@@date}% \SubStringsToCounter{iso@@minus}{-}{\iso@@date}% \SubStringsToCounter{iso@@dot}{.}{\iso@@date}% - \ifthenelse{\equal{\theiso@dot}{2}\and\equal{\theiso@@dot}{2}}{% + \ifthenelse{\equal{\theiso@dot}{2}\AND\equal{\theiso@@dot}{2}}{% \expandafter\iso@range@input@german\iso@@@date\@empty}{% - \ifthenelse{\equal{\theiso@minus}{2}\and\equal{\theiso@@minus}{2}}{% + \ifthenelse{\equal{\theiso@minus}{2}\AND\equal{\theiso@@minus}{2}}{% \expandafter\iso@range@input@iso\iso@@@date\@empty}{% - \ifthenelse{\equal{\theiso@slash}{2}\and% + \ifthenelse{\equal{\theiso@slash}{2}\AND \equal{\theiso@@slash}{2}}{% \expandafter\iso@range@input@english\iso@@@date\@empty}{% ????\iso@isodash ??\iso@isodash ??% diff --git a/Master/texmf-dist/tex/latex/isodate/isodateo.sty b/Master/texmf-dist/tex/latex/isodate/isodateo.sty index cc9b9439608..36fbde7c868 100644 --- a/Master/texmf-dist/tex/latex/isodate/isodateo.sty +++ b/Master/texmf-dist/tex/latex/isodate/isodateo.sty @@ -8,7 +8,7 @@ %% %% isodate package %% -%% Copyright 2000--2005 Harald Harders +%% Copyright 2000--2010 Harald Harders %% %% This program can be redistributed and/or modified under the terms %% of the LaTeX Project Public License Distributed from CTAN diff --git a/Master/texmf-dist/tex/latex/isodate/italian.idf b/Master/texmf-dist/tex/latex/isodate/italian.idf index b010384eee2..0bd4fdd1dfc 100644 --- a/Master/texmf-dist/tex/latex/isodate/italian.idf +++ b/Master/texmf-dist/tex/latex/isodate/italian.idf @@ -8,7 +8,7 @@ %% %% isodate package %% -%% Copyright 2000--2005 Harald Harders +%% Copyright 2000--2010 Harald Harders %% %% This program can be redistributed and/or modified under the terms %% of the LaTeX Project Public License Distributed from CTAN @@ -18,7 +18,7 @@ %% h.harders@tu-bs.de %% \ProvidesFile{italian.idf} - [2005/04/15 v2.28 Language definitions for isodate package (HH)] + [2010/01/03 v2.30 Language definitions for isodate package (HH)] \let\iso@languageloaded\active \typeout{Define commands for Italian date format} \def\month@italian{\ifcase\month\or @@ -26,63 +26,94 @@ luglio\or agosto\or settembre\or ottobre\or novembre\or dicembre\fi} \def\iso@printmonthday@italian#1#2{% - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \ifiso@printyear\iso@isodash\fi\iso@printmonth{#1}% - \iso@isodash\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear/\fi\iso@printmonth{#1}/\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \begingroup - \edef\lday{#2}\edef\day{\lday}% - \edef\lmonth{#1}\def\month{\lmonth}% - \number\day\ifnum1=\day \noexpand\textordmasculine\fi~\month@italian% - \endgroup - }{}}}}% - } + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \begingroup + \edef\lday{#2}\edef\day{\lday}% + \edef\lmonth{#1}\def\month{\lmonth}% + \ifiso@doprintday + \number\day\ifnum1=\day \noexpand\textordmasculine\fi + \iso@monthsep + \fi + \month@italian + \endgroup + }{}% + }% + }% +} \def\iso@printdate@italian#1#2#3{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear\iso@yearfour{\number#1}\fi}{}% - \iso@printmonthday@italian{\number#2}{\number#3}% - \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{}}}}% - \fi + \iso@printdate@int{#1}{#2}{#3}% + }{% + \iso@printmonthday@italian{\number#2}{\number#3}% + \ifiso@printyear + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{short}}{% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% + \fi + }% } \def\iso@dateitalian{% \def\today{\iso@printdate@italian{\year}{\month}{\day}}}% - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@italian}% +\expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@italian}% \def\iso@daterange@italian#1#2#3#4#5#6{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% - \iso@rangesign% - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@italian{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{% - \begingroup + \ifiso@doprintday + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \begingroup \edef\lday{#3}\edef\day{\lday}% \number\day\ifnum1=\day \noexpand\textordmasculine\fi - \endgroup}{\iso@printday{#3}}% - }{\iso@printmonthday@italian{#2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% -}{% + \endgroup + }{% + \iso@printday{#3}% + }% + \else + \iso@printmonthday@italian{#2}{#3}% + \fi + }{% + \iso@printmonthday@italian{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% }% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% + }% } \expandafter\def\csname iso@rangesign@\CurrentOption\endcsname{~al~} \def\iso@languagename{italian}% diff --git a/Master/texmf-dist/tex/latex/isodate/norsk.idf b/Master/texmf-dist/tex/latex/isodate/norsk.idf index e41972bb4e9..f42ab156bc0 100644 --- a/Master/texmf-dist/tex/latex/isodate/norsk.idf +++ b/Master/texmf-dist/tex/latex/isodate/norsk.idf @@ -8,7 +8,7 @@ %% %% isodate package %% -%% Copyright 2000--2005 Harald Harders +%% Copyright 2000--2010 Harald Harders %% %% This program can be redistributed and/or modified under the terms %% of the LaTeX Project Public License Distributed from CTAN @@ -18,67 +18,96 @@ %% h.harders@tu-bs.de %% \ProvidesFile{norsk.idf} - [2005/04/15 v2.28 Language definitions for isodate package (HH)] + [2010/01/03 v2.30 Language definitions for isodate package (HH)] \let\iso@languageloaded\active \typeout{Define commands for Norwegian date format} \def\month@norsk{\ifcase\month\or januar\or februar\or mars\or april\or mai\or juni\or juli\or august\or september\or oktober\or november\or desember\fi} - \def\iso@printmonthday@norsk#1#2{% - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \ifiso@printyear\iso@isodash\fi - \iso@printmonth{#1}\iso@isodash\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear/\fi\iso@printmonth{#1}/\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#2}.~\begingroup - \edef\lmonth{#1}\def\month{\lmonth}% - \month@norsk% - \endgroup - }{}}}}% - } - \def\iso@printdate@norsk#1#2#3{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% - \equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear\iso@yearfour{\number#1}\fi}{}% +\def\iso@printmonthday@norsk#1#2{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \ifiso@doprintday + \iso@printday{#2}.\iso@monthsep + \fi + \begingroup + \edef\lmonth{#1}\def\month{\lmonth}% + \month@norsk% + \endgroup + }{}% + }% + }% +} +\def\iso@printdate@norsk#1#2#3{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% \iso@printmonthday@norsk{\number#2}{\number#3}% \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{% - }}}}% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% \fi - } - \def\iso@datenorsk{% - \def\today{\iso@printdate@norsk{\year}{\month}{\day}}}% - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@norsk}% + }% +} +\def\iso@datenorsk{% + \def\today{\iso@printdate@norsk{\year}{\month}{\day}}}% +\expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@norsk}% \def\iso@daterange@norsk#1#2#3#4#5#6{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% - \iso@rangesign% - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@norsk{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#3}.}{\iso@printday{#3}}% - }{\iso@printmonthday@norsk{#2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}}% - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% - }{% + \ifiso@doprintday + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \iso@printday{#3}.% + }{% + \iso@printday{#3}% + }% + \else + \iso@printmonthday@norsk{#2}{#3}% + \fi + }{% + \iso@printmonthday@norsk{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% + }% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% }% } \expandafter\def\csname iso@rangesign@\CurrentOption\endcsname{~til~} diff --git a/Master/texmf-dist/tex/latex/isodate/swedish.idf b/Master/texmf-dist/tex/latex/isodate/swedish.idf index bbef8a82240..d1a5280a903 100644 --- a/Master/texmf-dist/tex/latex/isodate/swedish.idf +++ b/Master/texmf-dist/tex/latex/isodate/swedish.idf @@ -8,7 +8,7 @@ %% %% isodate package %% -%% Copyright 2000--2005 Harald Harders +%% Copyright 2000--2010 Harald Harders %% %% This program can be redistributed and/or modified under the terms %% of the LaTeX Project Public License Distributed from CTAN @@ -18,69 +18,97 @@ %% h.harders@tu-bs.de %% \ProvidesFile{swedish.idf} - [2005/04/15 v2.28 Language definitions for isodate package (HH)] + [2010/01/03 v2.30 Language definitions for isodate package (HH)] \let\iso@languageloaded\active \typeout{Define commands for Swedish date format} \def\month@swedish{\ifcase\month\or januari\or februari\or mars\or april\or maj\or juni\or juli\or augusti\or september\or oktober\or november\or december\fi} - \def\iso@printmonthday@swedish#1#2{% - \ifthenelse{\equal{\iso@dateformat}{numeric}\or% - \equal{\iso@dateformat}{short}}{% - \iso@printday{#2}/\iso@printmonth{#1}\ifiso@printyear/\fi}{% - \ifthenelse{\equal{\iso@dateformat}{iso}}{% - \ifiso@printyear\iso@isodash\fi\iso@printmonth{#1}% - \iso@isodash\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear/\fi\iso@printmonth{#1}/\iso@printday{#2}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#2}.~\begingroup - \edef\lmonth{#1}\def\month{\lmonth}% - \month@swedish% - \endgroup - }{}}}}% - } - \def\iso@printdate@swedish#1#2#3{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% - \equal{\iso@dateformat}{TeX}}{% - \ifiso@printyear\iso@yearfour{\number#1}\fi}{}% +\def\iso@printmonthday@swedish#1#2{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printmonthday@int{#1}{#2}% + }{% + \ifthenelse{\equal{\iso@dateformat}{numeric}\OR + \equal{\iso@dateformat}{short}}{% + \ifiso@doprintday + \iso@printday{#2}/% + \fi + \iso@printmonth{#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \ifiso@doprintday + \iso@printday{#2}.\iso@monthsep + \fi + \begingroup + \edef\lmonth{#1}\def\month{\lmonth}% + \month@swedish% + \endgroup + }{}% + }% + }% +} +\def\iso@printdate@swedish#1#2#3{% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR + \equal{\iso@dateformat}{TeX}}{% + \iso@printdate@int{#1}{#2}{#3}% + }{% \iso@printmonthday@swedish{\number#2}{\number#3}% \ifiso@printyear - \ifthenelse{\equal{\iso@dateformat}{numeric}}{\iso@yearfour{\number#1}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}}{~\iso@yearfour{\number#1}}{% + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + }{% + /% + }% + \ifthenelse{\equal{\iso@dateformat}{numeric}}{% + \iso@yearfour{\number#1}% + }{% + \ifthenelse{\equal{\iso@dateformat}{orig}}{% + \iso@yearsep\iso@yearfour{\number#1}% + }{% \ifthenelse{\equal{\iso@dateformat}{shortorig}}{% - ~\iso@twodigitsign\iso@yeartwo{\number#1}}{% + \iso@yearsep\iso@twodigitsign\iso@yeartwo{\number#1}% + }{% \ifthenelse{\equal{\iso@dateformat}{short}}{% - \iso@yeartwo{\number#1}}{% - }}}}% + \iso@yeartwo{\number#1}% + }{}% + }% + }% + }% \fi - } - \def\iso@dateswedish{% - \def\today{\iso@printdate@swedish{\year}{\month}{\day}}}% - \expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% - \iso@daterange@swedish}% + }% +} +\def\iso@dateswedish{% + \def\today{\iso@printdate@swedish{\year}{\month}{\day}}}% +\expandafter\def\csname iso@daterange@\CurrentOption\endcsname{% + \iso@daterange@swedish}% \def\iso@daterange@swedish#1#2#3#4#5#6{% - \ifthenelse{\equal{\iso@dateformat}{iso}\or% + \ifthenelse{\equal{\iso@dateformat}{iso}\OR \equal{\iso@dateformat}{TeX}}{% - \csname iso@printdate@\iso@languagename\endcsname{% - #1}{#2}{#3}\iso@rangesign% - \ifthenelse{\equal{\number#1}{\number#4}}{% - \ifthenelse{\equal{\number#2}{\number#5}}{\iso@printday{#6}% - }{\iso@printmonthday@swedish{#5}{#6}}}{% - \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}}}{% + \iso@daterange@int{#1}{#2}{#3}{#4}{#5}{#6}% + }{% \ifthenelse{\equal{\number#1}{\number#4}}{% \ifthenelse{\equal{\number#2}{\number#5}}{% - \ifthenelse{\equal{\iso@dateformat}{orig}\or - \equal{\iso@dateformat}{shortorig}}{% - \iso@printday{#3}.}{\iso@printday{#3}}% - }{\iso@printmonthday@swedish{#2}{#3}}}{% - \csname iso@printdate@\iso@languagename\endcsname{% - #1}{#2}{#3}}% - \iso@rangesign\csname iso@printdate@\iso@languagename\endcsname{% - #4}{#5}{#6}% -}{% + \ifiso@doprintday + \ifthenelse{\equal{\iso@dateformat}{orig}\OR + \equal{\iso@dateformat}{shortorig}}{% + \iso@printday{#3}.% + }{% + \iso@printday{#3}% + }% + \else + \iso@printmonthday@swedish{#2}{#3}% + \fi + }{% + \iso@printmonthday@swedish{#2}{#3}% + }% + }{% + \csname iso@printdate@\iso@languagename\endcsname{#1}{#2}{#3}% }% + \iso@rangesign + \csname iso@printdate@\iso@languagename\endcsname{#4}{#5}{#6}% + }% } \expandafter\def\csname iso@rangesign@\CurrentOption\endcsname{~till~} \def\iso@languagename{swedish}% |