summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex/datetime/datetime-manual.html
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2009-11-19 01:22:32 +0000
committerKarl Berry <karl@freefriends.org>2009-11-19 01:22:32 +0000
commit985c15fd8ede8df9fa1f88aea533234471dc8be5 (patch)
tree5da4fd6cea3dbebba71f6ebd3d323d7328e45eb2 /Master/texmf-dist/doc/latex/datetime/datetime-manual.html
parent01d93d3639c9411877c1fcb7034fa3d4d36e3afe (diff)
datetime update (18nov09)
git-svn-id: svn://tug.org/texlive/trunk@16071 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex/datetime/datetime-manual.html')
-rw-r--r--Master/texmf-dist/doc/latex/datetime/datetime-manual.html210
1 files changed, 141 insertions, 69 deletions
diff --git a/Master/texmf-dist/doc/latex/datetime/datetime-manual.html b/Master/texmf-dist/doc/latex/datetime/datetime-manual.html
index 48ce608fd40..b1012d6df8c 100644
--- a/Master/texmf-dist/doc/latex/datetime/datetime-manual.html
+++ b/Master/texmf-dist/doc/latex/datetime/datetime-manual.html
@@ -7,9 +7,9 @@ original version by: Nikos Drakos, CBLU, University of Leeds
Jens Lippmann, Marek Rouchal, Martin Wilck and others -->
<HTML>
<HEAD>
-<TITLE>datetime.sty v2.55: Formatting Current Date and Time</TITLE>
-<META NAME="description" CONTENT="datetime.sty v2.55: Formatting Current Date and Time">
-<META NAME="keywords" CONTENT="manual">
+<TITLE>datetime.sty v2.56: Formatting Current Date and Time</TITLE>
+<META NAME="description" CONTENT="datetime.sty v2.56: Formatting Current Date and Time">
+<META NAME="keywords" CONTENT="datetime-manual">
<META NAME="resource-type" CONTENT="document">
<META NAME="distribution" CONTENT="global">
@@ -24,7 +24,7 @@ original version by: Nikos Drakos, CBLU, University of Leeds
<P>
- <H1 ALIGN="CENTER">datetime.sty v2.55: Formatting Current Date and
+ <H1 ALIGN="CENTER">datetime.sty v2.56: Formatting Current Date and
Time</H1>
<P ALIGN="CENTER"><STRONG>Nicola L. C. Talbot
<BR>
@@ -38,7 +38,7 @@ Norwich. NR4 7TJ.
United Kingdom.
<BR> <TT><A NAME="tex2html1"
HREF="http://theoval.cmp.uea.ac.uk/~nlct/">http://theoval.cmp.uea.ac.uk/~nlct/</A></TT></STRONG></P>
-<P ALIGN="CENTER"><STRONG>20 Aug 2007</STRONG></P>
+<P ALIGN="CENTER"><STRONG>16th November 2009</STRONG></P>
<BR>
<H2><A NAME="SECTION00010000000000000000">
@@ -48,29 +48,31 @@ Contents</A>
<UL>
<LI><A NAME="tex2html24"
- HREF="manual.html#SECTION00020000000000000000">Introduction</A>
+ HREF="datetime-manual.html#SECTION00020000000000000000">Introduction</A>
<LI><A NAME="tex2html25"
- HREF="manual.html#SECTION00030000000000000000">Date Declarations</A>
+ HREF="datetime-manual.html#SECTION00030000000000000000">Predefined Date Formats</A>
<LI><A NAME="tex2html26"
- HREF="manual.html#SECTION00040000000000000000">Time Commands</A>
+ HREF="datetime-manual.html#SECTION00040000000000000000">Time Commands</A>
<LI><A NAME="tex2html27"
- HREF="manual.html#SECTION00050000000000000000">Formating Dates</A>
+ HREF="datetime-manual.html#SECTION00050000000000000000">Formating Dates</A>
<LI><A NAME="tex2html28"
- HREF="manual.html#SECTION00060000000000000000">Defining New Date Formats</A>
+ HREF="datetime-manual.html#SECTION00060000000000000000">Defining New Date Formats</A>
<LI><A NAME="tex2html29"
- HREF="manual.html#SECTION00070000000000000000">Saving Dates</A>
+ HREF="datetime-manual.html#SECTION00070000000000000000">Saving Dates</A>
<LI><A NAME="tex2html30"
- HREF="manual.html#SECTION00080000000000000000">Predefined Names</A>
+ HREF="datetime-manual.html#SECTION00080000000000000000">Predefined Names</A>
<LI><A NAME="tex2html31"
- HREF="manual.html#SECTION00090000000000000000">Package Options</A>
+ HREF="datetime-manual.html#SECTION00090000000000000000">Package Options</A>
<LI><A NAME="tex2html32"
- HREF="manual.html#SECTION000100000000000000000">Multilingual Support</A>
+ HREF="datetime-manual.html#SECTION000100000000000000000">Multilingual Support</A>
<LI><A NAME="tex2html33"
- HREF="manual.html#SECTION000110000000000000000">Configuration File</A>
+ HREF="datetime-manual.html#SECTION000110000000000000000">Registers</A>
<LI><A NAME="tex2html34"
- HREF="manual.html#SECTION000120000000000000000">LaTeX2HTML styles</A>
+ HREF="datetime-manual.html#SECTION000120000000000000000">Configuration File</A>
<LI><A NAME="tex2html35"
- HREF="manual.html#SECTION000130000000000000000">Troubleshooting</A>
+ HREF="datetime-manual.html#SECTION000130000000000000000">LaTeX2HTML styles</A>
+<LI><A NAME="tex2html36"
+ HREF="datetime-manual.html#SECTION000140000000000000000">Troubleshooting</A>
</UL>
<!--End of Table of Contents-->
<H1><A NAME="SECTION00020000000000000000">
@@ -110,13 +112,22 @@ For example:
<P>
<H1><A NAME="SECTION00030000000000000000">
-Date Declarations</A>
+Predefined Date Formats</A>
</H1>
There are various declarations that change the effect of
<TT>&#092;today</TT>. The change can be localised by placing the
declaration within a group.
<P>
+ISO format:
+
+ The declaration <code>\yyyymmdddate</code> will redefine
+<code>\today</code> to produce
+ the current date displayed in the form 2000/03/08. (You can
+redefine <TT>&#092;dateseparator</TT> to <TT>-</TT> to change to
+2000-03-08.)
+
+<P>
<I>Day</I> <I>Month</I> <I>Year</I> formats:
<BR>
@@ -157,7 +168,7 @@ the package option <TT>nodayofweek</TT> is used. Note that
<code>\textdate</code> is defined for use with English, it won't
look right if it is used when another language has been
selected<A NAME="tex2html2"
- HREF="#foot411"><SUP>1</SUP></A>. If you want to define a similar command for
+ HREF="#foot456"><SUP>1</SUP></A>. If you want to define a similar command for
another language, you will first need to check that the
<TT>fmtcount</TT> package supports that language.
@@ -190,7 +201,7 @@ In addition, the declarations <code>\date</code><I>lang</I> are
available for all languages defined either by
calling <TT>babel</TT> prior to <TT>datetime</TT> or by
passing the language name as an option to <TT>datetime</TT>.
-See&nbsp;<A HREF="manual.html#sec:newdate">later</A>
+See&nbsp;<A HREF="datetime-manual.html#sec:newdate">later</A>
if you want to define your own customised date format.
<P>
@@ -211,15 +222,23 @@ Time Commands</A>
The current time is displayed using the command
<code>\currenttime</code>.
- The format can be changed using the declaration
+<P>
+A specific time can be displayed using
+the command <TT>&#092;formattime{</TT><EM>hour</EM><TT>}{</TT><EM>minute</EM><TT>}{</TT><EM>second</EM><TT>}</TT>, where
+<I>hour</I> is a number from&nbsp;0 to&nbsp;23, and <I>minute</I> and
+<I>second</I> are numbers from&nbsp;0 to&nbsp;59.
+
+<P>
+The format can be changed using the declaration
<TT>&#092;settimeformat{</TT><EM>style</EM><TT>}</TT>, where <I>style</I> is the name of the
-format<A NAME="tex2html3"
- HREF="#foot416"><SUP>2</SUP></A>. Available formats
-are:
+format. Predefined formats are:
<DL>
<DT><STRONG>xxivtime</STRONG></DT>
<DD>Twenty-four hour time in the form 22:28 (Default)
</DD>
+<DT><STRONG>hhmmsstime</STRONG></DT>
+<DD>Twenty-four hour time in the form 22:28:00
+</DD>
<DT><STRONG>ampmtime</STRONG></DT>
<DD>Twelve hour time in the form 10:28pm
</DD>
@@ -239,10 +258,11 @@ where <I>name</I> is the name of the new format (used in
<TT>&#092;settimeformat</TT>), and <I>format</I> is how to format the
time. Within <I>format</I> you can use the counters
<TT>HOUR</TT> (number of hours after midnight), <TT>MINUTE</TT>
-(number of minutes past the hour), <TT>HOURXII</TT> (number of
+(number of minutes past the hour), <TT>SECOND</TT> (number of
+seconds) <TT>HOURXII</TT> (number of
hours after midnight/midday), <TT>TOHOUR</TT> (the next hour) and
<TT>TOMINUTE</TT> (number of minutes to the next hour), and the
-corresponding commands: <TT>&#092;THEHOUR</TT>, <TT>&#092;THEMINUTE</TT>,
+corresponding commands: <TT>&#092;THEHOUR</TT>, <TT>&#092;THEMINUTE</TT>, <TT>&#092;THESECOND</TT>,
<TT>&#092;THEHOURXII</TT>, <TT>&#092;THETOHOUR</TT> and <TT>&#092;THETOMINUTE</TT>.
<P>
@@ -273,8 +293,8 @@ format defined above.
Formating Dates</A>
</H1>
- The command <code>\pdfdate</code><A NAME="tex2html4"
- HREF="#foot148"><SUP>3</SUP></A> prints the date in the format required for
+ The command <code>\pdfdate</code><A NAME="tex2html3"
+ HREF="#foot154"><SUP>2</SUP></A> prints the date in the format required for
PDF files, e.g. if the date is 1 May 2004 and time is
22:02, <code>\pdfdate</code> will print 20040501220200. The reason
this date format is separate from all the others is because the
@@ -290,6 +310,10 @@ Example:
/ModDate (D:\pdfdate)
}
</PRE>
+<B>Note</B> that PDFTeX introduced the new primitive
+<TT>&#092;pdfcreationdate</TT> in version 1.30.0, so <TT>&#092;pdfdate</TT> isn't
+required with newer versions of PDFTeX. (<TT>&#092;pdfcreationdate</TT>
+is better than <TT>&#092;pdfdate</TT> as it also stores the time zone.)
<P>
There are two commands that print the name of the current
@@ -306,7 +330,7 @@ example, <code>\monthname[6]</code> will produced the output: June.
<P>
The day of the week is computed using the algorithm documented at
- <TT><A NAME="tex2html5"
+ <TT><A NAME="tex2html4"
HREF="http://userpages.wittenburg.edu/bshelburne/Comp150/DayOfWeek.htm">http://userpages.wittenburg.edu/bshelburne/Comp150/DayOfWeek.htm</A></TT>.
This algorithm works for any date between 1<SUP>st</SUP>
Jan, 1901 and 31<SUP>st</SUP> Dec, 2099.
@@ -354,10 +378,10 @@ will only be added if <I>number</I> is 1, otherwise only
<P>
The macro
-<TT>&#092;formatdate{</TT><EM>day</EM><TT>}{</TT><EM>month</EM><TT>}{</TT><EM>year</EM><TT>}</TT><A NAME="tex2html6"
- HREF="#foot417"><SUP>4</SUP></A> formats the specified date according to
-the current format of <TT>&#092;today</TT><A NAME="tex2html7"
- HREF="#foot421"><SUP>5</SUP></A>.
+<TT>&#092;formatdate{</TT><EM>day</EM><TT>}{</TT><EM>month</EM><TT>}{</TT><EM>year</EM><TT>}</TT><A NAME="tex2html5"
+ HREF="#foot461"><SUP>3</SUP></A> formats the specified date according to
+the current format of <TT>&#092;today</TT><A NAME="tex2html6"
+ HREF="#foot465"><SUP>4</SUP></A>.
(Arguments must all be integers.) For example, in combination with
<code>\longdate</code>, the command
<PRE>
@@ -456,8 +480,8 @@ Saving Dates</A>
<P>
It is possible to save a date for later use using the command:
-<A NAME="tex2html8"
- HREF="#foot244"><SUP>6</SUP></A>
+<A NAME="tex2html7"
+ HREF="#foot255"><SUP>5</SUP></A>
<P>
<TT>&#092;newdate{</TT><EM>name</EM><TT>}{</TT><EM>day</EM><TT>}{</TT><EM>month</EM><TT>}{</TT><EM>year</EM><TT>}</TT>
@@ -558,6 +582,9 @@ The following options may be passed to this package:
<TR><TD ALIGN="LEFT"><TT></TD><TD ALIGN="LEFT">short </TT></TD>
<TD ALIGN="LEFT">make <TT>&#092;today</TT> produce short date</TD>
</TR>
+<TR><TD ALIGN="LEFT"><TT></TD><TD ALIGN="LEFT">yyyymmdd </TT></TD>
+<TD ALIGN="LEFT">make <TT>&#092;today</TT> produce YYYY/MM/DD date</TD>
+</TR>
<TR><TD ALIGN="LEFT"><TT></TD><TD ALIGN="LEFT">ddmmyyyy </TT></TD>
<TD ALIGN="LEFT">make <TT>&#092;today</TT> produce DD/MM/YYYY date</TD>
</TR>
@@ -605,6 +632,10 @@ text</TD>
<TR><TD ALIGN="LEFT"><TT></TD><TD ALIGN="LEFT">nodayofweek </TT></TD>
<TD ALIGN="LEFT">don't display the day of week.</TD>
</TR>
+<TR><TD ALIGN="LEFT"><TT></TD><TD ALIGN="LEFT">hhmmss </TT></TD>
+<TD ALIGN="LEFT">make <TT>&#092;currenttime</TT> produce <TT>hhmmsstime</TT>
+format</TD>
+</TR>
<TR><TD ALIGN="LEFT"><TT></TD><TD ALIGN="LEFT">24hr </TT></TD>
<TD ALIGN="LEFT">make <TT>&#092;currenttime</TT> produce <TT>xxivtime</TT>
format</TD>
@@ -622,8 +653,13 @@ format</TD>
day of week commands</TD>
</TR>
<TR><TD ALIGN="LEFT"><TT></TD><TD ALIGN="LEFT"></TT></TD>
-<TD ALIGN="LEFT">(useful if you only want the time commands or
-<code>\pdfdate</code>)</TD>
+<TD ALIGN="LEFT">(useful if you only want the time commands)</TD>
+</TR>
+<TR><TD ALIGN="LEFT"><TT></TD><TD ALIGN="LEFT">iso </TT></TD>
+<TD ALIGN="LEFT">as ddmmyyyy and hhmmss but also sets date separator to -</TD>
+</TR>
+<TR><TD ALIGN="LEFT"><TT></TD><TD ALIGN="LEFT"></TT></TD>
+<TD ALIGN="LEFT">and time separator to :</TD>
</TR>
</TABLE>
@@ -638,6 +674,13 @@ Multilingual Support</A>
</H1>
<P>
+If you use the <TT>ngerman</TT> package, you must use <TT>datetime</TT>'s
+<TT>ngerman</TT> package option if you want the date displayed
+in the same form as <TT>ngerman</TT>. You must also load <TT>ngerman</TT>
+<I>before</I> you load <TT>datetime</TT>. Similarly for the
+<TT>german</TT> package.
+
+<P>
If you want to use the <TT>babel</TT> package, you must load
it <I>before</I> you load the <TT>datetime</TT> package. This
is because the <TT>babel</TT> <TT>&#092;date</TT><I>lang</I> commands
@@ -655,6 +698,32 @@ languages that I know, or that other people have been able to supply
for me.
<P>
+As from v2.56, the package options supplied to <TT>datetime</TT>
+override <TT>babel</TT>'s date format. For example:
+<PRE>
+\usepackage[french,spanish]{babel}
+\usepackage[ddmmyyyy]{datetime}
+</PRE>
+will use ddmmyyyy date format regardless of language. Note that
+if you use a declaration instead of a package option, for
+example:
+<PRE>
+\usepackage[french,spanish]{babel}
+\usepackage{datetime}
+\ddmmyyyydate
+</PRE>
+the date format will be switched back to <TT>&#092;datefrench</TT> or
+<TT>&#092;datespanish</TT> whenever the language is set. You can use
+<P>
+<TT>&#092;setdefaultdate{</TT><EM>declaration</EM><TT>}</TT>
+<P>
+to always use <TT>{</TT><EM>declaration</EM><TT>}</TT> whenever the language
+is set. For example:
+<PRE>
+\setdefaultdate{\ddmmyyyydate}
+</PRE>
+
+<P>
The commands <TT>&#092;monthname</TT> and <TT>&#092;shortmonthname</TT>,
will produce the month name in the current language.
If you want the month name in a specific language, you
@@ -671,13 +740,13 @@ for further details.
<P>
There is currently only <I>limited</I> multilingual support for
<TT>&#092;dayofweekname</TT> and <TT>&#092;shortdayofweekname</TT> (just
-English, French, Portuguese, Spanish and German<A NAME="tex2html9"
- HREF="#foot358"><SUP>7</SUP></A>). You can add support
+English, French, Portuguese, Spanish and German<A NAME="tex2html8"
+ HREF="#foot394"><SUP>6</SUP></A>). You can add support
for other languages by defining the commands
<TT>&#092;dayofweeknameid</TT><I>lang</I> and
<TT>&#092;shortdayofweeknameid</TT><I>lang</I>. Note that these
commands only take <I>one</I> argument which should be
-a number from 1 to 7 indicating the day of the week.
+a number from&nbsp;1 to&nbsp;7 indicating the day of the week.
<P>
You can use the following as templates. Replace
@@ -713,6 +782,19 @@ If you want them added to future versions of
<P>
<H1><A NAME="SECTION000110000000000000000">
+Registers</A>
+</H1>
+
+<P>
+TeX provides <TT>&#092;day</TT>, <TT>&#092;month</TT>, <TT>&#092;year</TT> registers. In
+addition, <TT>datetime</TT> provides the registers:
+<TT>&#092;currenthour</TT>, <TT>&#092;currentminute</TT> and <TT>&#092;currentsecond</TT>.
+Note that old distributions of TeX will always have
+<TT>&#092;currentsecond</TT> set to zero.
+
+<P>
+
+<H1><A NAME="SECTION000120000000000000000">
Configuration File</A>
</H1>
@@ -747,7 +829,7 @@ use this format by default.
<P>
-<H1><A NAME="SECTION000120000000000000000">
+<H1><A NAME="SECTION000130000000000000000">
LaTeX2HTML styles</A>
</H1>
@@ -791,64 +873,54 @@ implemented.
<P>
-<H1><A NAME="SECTION000130000000000000000">
+<H1><A NAME="SECTION000140000000000000000">
Troubleshooting</A>
</H1>
<P>
There is a <TT>datetime</TT> FAQ available at:
-<TT><A NAME="tex2html10"
+<TT><A NAME="tex2html9"
HREF="http://theoval.cmp.uea.ac.uk/~nlct/latex/packages/faq/">http://theoval.cmp.uea.ac.uk/~nlct/latex/packages/faq/</A></TT>
<P>
<BR><HR><H4>Footnotes</H4>
<DL>
-<DT><A NAME="foot411">...
+<DT><A NAME="foot456">...
selected</A><A
- HREF="manual.html#tex2html2"><SUP>1</SUP></A></DT>
+ HREF="datetime-manual.html#tex2html2"><SUP>1</SUP></A></DT>
<DD>in fact, you may get an error from the
<TT>fmtcount</TT> package if you are using a language that it
doesn't support.
</DD>
-<DT><A NAME="foot416">...
-format</A><A
- HREF="manual.html#tex2html3"><SUP>2</SUP></A></DT>
-<DD>Note that the commands <TT>&#092;xxivtime</TT>, <TT>&#092;ampmtime</TT>
-and <TT>&#092;oclock</TT> are still available, <TT>&#092;settimeformat</TT> redefines
-<TT>&#092;currenttime</TT> to the command given by placing a backslash in front
-of <I>style</I>. So <TT>&#092;settimeformat{xxivtime}</TT> sets
-<TT>&#092;currenttime</TT> to <TT>&#092;xxivtime</TT> and so on.
-
-</DD>
-<DT><A NAME="foot148">... <code>\pdfdate</code></A><A
- HREF="manual.html#tex2html4"><SUP>3</SUP></A></DT>
+<DT><A NAME="foot154">... <code>\pdfdate</code></A><A
+ HREF="datetime-manual.html#tex2html3"><SUP>2</SUP></A></DT>
<DD>thanks to Ulrich Dirr for
asking about this
</DD>
-<DT><A NAME="foot417">...year</A><A
- HREF="manual.html#tex2html6"><SUP>4</SUP></A></DT>
+<DT><A NAME="foot461">...year</A><A
+ HREF="datetime-manual.html#tex2html5"><SUP>3</SUP></A></DT>
<DD>Note the
name change since version 1.1. The command name was changed from
<TT>&#092;thedate</TT> to <TT>&#092;formatdate</TT> to avoid a name clash when using the
<TT>seminar</TT> class file.
</DD>
-<DT><A NAME="foot421">...today</A><A
- HREF="manual.html#tex2html7"><SUP>5</SUP></A></DT>
+<DT><A NAME="foot465">...today</A><A
+ HREF="datetime-manual.html#tex2html6"><SUP>4</SUP></A></DT>
<DD>To be more precise,
<TT>&#092;today</TT> is defined to be
<TT>&#092;formatdate{<TT>&#092;day</TT>}{<TT>&#092;month</TT>}{<TT>&#092;year</TT>}</TT> where
<TT>&#092;longdate</TT> etc change the definition of <TT>&#092;formatdate</TT>
</DD>
-<DT><A NAME="foot244">... command:</A><A
- HREF="manual.html#tex2html8"><SUP>6</SUP></A></DT>
+<DT><A NAME="foot255">... command:</A><A
+ HREF="datetime-manual.html#tex2html7"><SUP>5</SUP></A></DT>
<DD>Thanks to Denis Bitouz&#233; for asking about this
</DD>
-<DT><A NAME="foot358">... German</A><A
- HREF="manual.html#tex2html9"><SUP>7</SUP></A></DT>
+<DT><A NAME="foot394">... German</A><A
+ HREF="datetime-manual.html#tex2html8"><SUP>6</SUP></A></DT>
<DD>thanks
to Uwe Bieling for supplying the German names
@@ -856,10 +928,10 @@ to Uwe Bieling for supplying the German names
</DL>
<BR><HR>
<ADDRESS>
-<A href=http://theoval.cmp.uea.ac.uk/~nlct/>Nicola L. C. Talbot</A>.
-<A HREF=http://www.cmp.uea.ac.uk/>School of Computing Sciences</A>.
-<A HREF=http://www.uea.ac.uk/>University of East Anglia.</A>
-Last Modified: 2007-08-20
+<A href="http://theoval.cmp.uea.ac.uk/~nlct/">Nicola L. C. Talbot</A>.
+<A HREF="http://www.cmp.uea.ac.uk/">School of Computing Sciences</A>.
+<A HREF="http://www.uea.ac.uk/">University of East Anglia.</A>
+Last Modified: 2009-11-17
</ADDRESS>
</BODY>
</HTML>