summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2009-10-08 22:33:26 +0000
committerKarl Berry <karl@freefriends.org>2009-10-08 22:33:26 +0000
commit43f76defc822924473d9111705a67904cfd1276b (patch)
tree317933fa983e75ee54d175231513a7be6bfbf8c6 /Master/texmf-dist/doc/latex
parentb676d1c3d9ca7308407a66f16654586bc0259090 (diff)
getfiledate 1.0 (7oct09)
git-svn-id: svn://tug.org/texlive/trunk@15701 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex')
-rw-r--r--Master/texmf-dist/doc/latex/getfiledate/getfiledate-guide.pdfbin113045 -> 117059 bytes
-rw-r--r--Master/texmf-dist/doc/latex/getfiledate/getfiledate-guide.tex102
2 files changed, 75 insertions, 27 deletions
diff --git a/Master/texmf-dist/doc/latex/getfiledate/getfiledate-guide.pdf b/Master/texmf-dist/doc/latex/getfiledate/getfiledate-guide.pdf
index 6246098c406..ad75071b8cf 100644
--- a/Master/texmf-dist/doc/latex/getfiledate/getfiledate-guide.pdf
+++ b/Master/texmf-dist/doc/latex/getfiledate/getfiledate-guide.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/getfiledate/getfiledate-guide.tex b/Master/texmf-dist/doc/latex/getfiledate/getfiledate-guide.tex
index 634f2cf5500..147523a9e43 100644
--- a/Master/texmf-dist/doc/latex/getfiledate/getfiledate-guide.tex
+++ b/Master/texmf-dist/doc/latex/getfiledate/getfiledate-guide.tex
@@ -35,6 +35,7 @@
\new\def\styb#1{\TC{teal}{\texttt{#1}}}
\new\def\cmda#1{\stya{\string#1}}
\new\def\cmdb#1{\styb{\string#1}}
+\new\def\cmdc#1{\stya{#1\string\hsize}}
\def\ie{i.e.\xspace}
\newcounter{examplecnt}[section]
\new\def\example{%
@@ -91,7 +92,7 @@ or with options as in
\begin{gfdverbatim}
\usepackage[option=value]{getfiledate}
\end{gfdverbatim}
-The options include the filename for which you want to print the date of last modification. The options and their default values are described in section~\ref{sec:PackageOptions}. It is advisable to first load the package by \cmda{\usepackage\{getfiledate\}} and then use the macro \cmda{\getfiledate} to dynamically determine and print the date of last modification of the filename. This macro sets the various options.
+The options include the filename for which you want to print the date of last modification. The options and their default values are described in section~\ref{sec:PackageOptions}. It is advisable to first load the package by \cmda{\usepackage\{getfiledate\}} and then use the macro \cmda{\getfiledate} to dynamically determine and print the date of last modification of filenames. The \cmda{\getfiledate} macro sets the various options. The \cmdb{\documentclass} and \cmda{\usepackage\{getfiledate\}} options lists may, however, be used to set options that apply throughout the document.
\section{Package options\label{sec:PackageOptions}}
The package options are listed in Table~\ref{tab:Package-options} below.
@@ -103,10 +104,10 @@ The package options are listed in Table~\ref{tab:Package-options} below.
\begin{longtable}{m{3cm}m{3.5cm}m{\dimexpr\hsize-8cm}}
\caption{Package options\label{tab:Package-options}}\\
\rowcolor{green!55}
-\bfseries Option&\bfseries Default&\bfseries Meaning\\
+\bf Option & \bf Default & \bf Meaning\\
\endfirsthead
\multicolumn{3}{|l|}{\emph{Continued from last page}}\\
-\bfseries Option&\bfseries Default&\bfseries Meaning\\
+\bf Option & \bf Default & \bf Meaning\\
\endhead
\multicolumn{3}{|r|}{\emph{Continued on next page}}\\
\endfoot
@@ -123,12 +124,12 @@ The package options are listed in Table~\ref{tab:Package-options} below.
+datecolor+ & +blue+ & The color of filedate.\\
+inlinespace+ & +1em+ & The horizontal separation between the marker and the filedate.\\
+separator+ & +\textbullet+ & The marker between the filedate and filetime.\\
-+separatorcolor+ & +black+ & The color of the separator.\\
++sepcolor+ & +black+ & The color of the separator.\\
+framecolor+ & +black+ & The color of the boxrule for the boxedminipage.\\
+framesep+ & +3pt+ & The +\fboxsep+ for the boxedminipage.\\
+framerule+ & +0.4pt+ & The +\fboxrule+ for the boxedminipage.\\
+align+ & +justified+ & Alignment of the boxedminipage (possible values are \stya{center}, \stya{left}, \stya{right} and \stya{justified}).\\
-+putprefix+ & +false+ & The boolean switch for placing prefix and postfix before the filedate. If this option is not entered in the call to \cmda{\getfiledate}, no prefix and no postfix will be inserted (even if the user specifies prefix and postfix in the call to \cmda{\getfiledate}). This option has been necessitated by users who just want to get filedate without any prefix, postfix or filename.\\
++putprefix+ & +false+ & The boolean switch for placing prefix and postfix before the filedate. If this option is not entered in the call to \cmda{\getfiledate}, no prefix and no postfix will be inserted (even if the user specifies prefix and postfix in the call to \cmda{\getfiledate}). This option has been necessitated by users who just want to get filedate without any prefix, postfix or filename.\\
+notime+ & +false+ & The boolean switch for turning the display of time on or off.\\
+boxed+ & +false+ & The boolean switch for enclosing the filedate in a box. If the user simply enters this option without value, it will be assumed to be +true+. If it doesn't appear in the options list, its value is +false+.
\end{longtable}
@@ -156,16 +157,19 @@ The prefix and postfix can be turned off as follows:
which gives
-\small\getfiledate[putprefix=false]{misc-test1.tex}\normalsize
+\small
+\getfiledate[putprefix=false]{misc-test1.tex}
+\normalsize
\bigskip
If the user needs the prefix and postfix in subsequent calls to \cmda{\getfiledate}, he has to turn them on again---through \stya{putprefix} as follows. Once turned on, they remain in effect until switched off later.
+The setting
\begin{gfdverbatim}
\getfiledate[putprefix,marker={$\star$}]{dir/filename.ext}
\end{gfdverbatim}
-which gives
+gives
\small
\getfiledate[putprefix,marker={$\star$}]{misc-test1.tex}
@@ -175,14 +179,14 @@ which gives
The ability to change both the prefix and postfix automatically provides a +babel+ (\ie, multilingual) support. For example, if I want the postfix to be \cmdb{\mrule}, I can simply enter
\begin{gfdverbatim}
-\new\def\mrule{\rule[.5ex]{1cm}{2pt}}
+\new\def\mrule{\rule[.2ex]{.5cm}{3pt}}
\getfiledate[putprefix,marker={$\star$},
postfix=\mrule]{dir/filename.ext}
\end{gfdverbatim}
to get
-\new\def\mrule{\rule[.5ex]{1cm}{2pt}}
+\new\def\mrule{\rule[.2ex]{.5cm}{3pt}}
\small
\getfiledate[putprefix,marker={$\star$},postfix=\mrule]{misc-test1.tex}
\normalsize
@@ -209,37 +213,80 @@ The outcome of this is
]{misc-test1.tex}
\normalsize
-If you don't need the \stya{marker}, you can set \stya{marker=\{\}} as follows
+If you don't need the \stya{marker}, you can simply enter \stya{marker} without value as follows
+
\begin{gfdverbatim}
\getfiledate[head=\baselineskip,
foot=\baselineskip,width=.6\hsize,filenamecolor=xgreen10,
prefix=The date of final changes to file,
datecolor=orange,inlinespace=.5em,boxed=false,
- separator=$\spadesuit$,separatorcolor=green,
- |color(red)marker={}|color(xmagenta20),align=center
+ separator=$\spadesuit$,sepcolor=green,|color(red)marker|color(xmagenta20),align=center
]{misc-test1.tex}
\end{gfdverbatim}
+
to get
+
\getfiledate[head=\baselineskip,
foot=\baselineskip,width=.6\hsize,
prefix=The date of final changes to file,
- marker={},filenamecolor=xgreen10,datecolor=orange,
+ marker,filenamecolor=xgreen10,datecolor=orange,
inlinespace=.5em,align=center,boxed=false,
- separator=$\spadesuit$,separatorcolor=green
+ separator=$\spadesuit$,sepcolor=green
+]{misc-test1.tex}
+
+If you simply remove \stya{marker} from the key-value list, the \stya{marker} will retain the last value you assigned to it rather than the default value (which is nil).
+
+\example
+
+Unlike the case of the \stya{marker}, if you don't need the \stya{separator}, you would have to enter \stya{separator=\{\}} or simply \stya{separator=} as follows
+
+\begin{gfdverbatim}
+\getfiledate[head=\baselineskip,foot=\baselineskip,
+ width=.6\hsize,filenamecolor=xgreen10,
+ prefix=The date of final changes to file,
+ datecolor=orange,inlinespace=.5em,boxed=false,
+ |color(red)separator=,|color(xmagenta20)sepcolor=green,marker,align=center
]{misc-test1.tex}
-The same trick can be applied to other keys. If you simply remove \stya{marker} from the key-value list, the \stya{marker} will retain the last value you assigned to it rather than the default value (which is nil).
+\end{gfdverbatim}
-The user should note the following:
+to get
+\getfiledate[head=\baselineskip,
+ foot=\baselineskip,width=.6\hsize,
+ prefix=The date of final changes to file,
+ marker,filenamecolor=xgreen10,datecolor=orange,
+ inlinespace=.5em,align=center,boxed=false,
+ separator=,sepcolor=green
+]{misc-test1.tex}
+
+The same trick can be applied to some other keys. If you simply remove the \stya{separator} from the key-value list, the \stya{separator} will retain the last value you assigned to it rather than the default value (which is \cmda{\textbullet}). If in the subsequent calls to \cmda{\getfiledate}, you need the \stya{separator}, you would have to specify it or (to use the default value) simply enter \stya{separator} without value.
+
+\textbf{Notes}: The user should note the following:
\begin{itemize}
-\item The inclusion of the \stya{width} (\stya{=0.6\string\hsize}) in the above example. The \stya{width} will maintain this value until it is changed again, as in the following examples.
+\item The inclusion of the \stya{width} (\cmdc{0.6}) in the above example. The \stya{width} will maintain this value until it is changed again, as in the following examples.
+
+\item If you enter \stya{putprefix=false} and you want the outcome centered, you should remember to set the right \stya{width}. For example, the following will not be centered, simply because the value of \stya{width} is \cmdc{0.8}:
+
+ \begin{gfdverbatim}
+ \getfiledate[putprefix=false,align=center,
+ width=0.8\hsize,separator]{dir/filename.ext}
+ \end{gfdverbatim}
+
+ which gives
+
+ \getfiledate[putprefix=false,align=center,width=0.8\hsize,separator]{misc-test1.tex}
+
+ Setting \cmdc{width=.3} gives the desired result:
+
+ \getfiledate[putprefix=false,align=center,width=0.3\hsize,separator]{misc-test1.tex}
+
\item The assignment to keys can be localized by enclosing the \cmda{\getfiledate} command in a group (\eg, \cmdb{\bgroup} ... \cmdb{\egroup}).
\item The change of \stya{prefix} here. The default value of \stya{prefix} is \stya{The date of last modification of file}. The \stya{prefix} will maintain this value until it is changed in the next call (see the next example).
\item The ability to change the \stya{prefix} and \stya{postfix} provides a babel (\ie, multilingual) support, since the user can specify suitable values of these keys.
\item The use of the key-value \stya{align=center} above. The key \stya{align} can assume values of \stya{center}, \stya{left}, \stya{right}, and \stya{justified}. Any other value for \stya{align} will be rejected by the package.
-\item Some of the package options (\eg, \stya{notime}) can be submitted via the options list of \cmdb{\documentclass}.
+\item Some of the package options (\eg, \stya{putprefix}, \stya{notime}) can be submitted globally via the options list of \cmdb{\documentclass}.
\end{itemize}
\example
@@ -248,7 +295,7 @@ The example in this section was obtained with the following settings:
\getfiledate[head=0ex,foot=\baselineskip,
prefix,width=\hsize,markercolor=magenta,filenamecolor=red,
datecolor=violet,inlinespace=.5em,marker=$\triangleright$,
- separator=$\clubsuit$,separatorcolor=xbgreen1
+ separator=$\clubsuit$,sepcolor=xbgreen1
]{misc-test2.tex}
\end{gfdverbatim}
@@ -257,17 +304,17 @@ The outcome is:
foot=1ex,width=\hsize,prefix,
markercolor=magenta,filenamecolor=red,datecolor=violet,
inlinespace=.5em,marker=$\triangleright$,
- separator=$\clubsuit$,separatorcolor=red!55!green!65
+ separator=$\clubsuit$,sepcolor=red!55!green!65
]{misc-test2.tex}
Here we simply passed the \stya{prefix} without value so that its default value was used.
\example
The example in this section was obtained with the following settings:
\begin{gfdverbatim}
-\getfiledate[head=\baselineskip,foot=2\baselineskip,
+\getfiledate[head=\baselineskip,foot=\baselineskip,
markercolor=red!65,filenamecolor=blue,
datecolor=orange,inlinespace=.5em,marker={$\star$},
- separator=$\Diamond$,separatorcolor=red
+ separator=$\Diamond$,sepcolor=red
]{misc-test3.tex}
\end{gfdverbatim}
@@ -275,24 +322,25 @@ The outcome is:
\getfiledate[head=\baselineskip,
foot=\baselineskip,markercolor=red!65,filenamecolor=blue,
datecolor=orange,inlinespace=.5em,marker={$\star$},
- separator=$\Diamond$,separatorcolor=red
+ separator=$\Diamond$,sepcolor=red
]{misc-test3.tex}
\example
+
The example in this section was obtained with the following settings:
\begin{gfdverbatim}
\getfiledate[head=\baselineskip,foot=2ex,
- markercolor=cyan,filenamecolor=blue,datecolor=orange,
+ filenamecolor=blue,datecolor=orange,
inlinespace=.5em,marker={$\blacktriangleright$},
- markercolor=cyan,separator=$\heartsuit$,separatorcolor
-]{misc-test4.tex}|color(black) % Use default separatorcolor
+ markercolor=cyan,separator=$\heartsuit$,sepcolor
+]{misc-test4.tex}|color(black) % Use default sepcolor
\end{gfdverbatim}
The outcome is:
\getfiledate[head=\baselineskip,foot=2ex,
markercolor=cyan,filenamecolor=blue,datecolor=orange,
inlinespace=.5em,marker={$\blacktriangleright$},
- markercolor=cyan,separator=$\heartsuit$,separatorcolor
+ separator=$\heartsuit$,sepcolor
]{misc-test4.tex}
\example