summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2009-04-02 18:41:54 +0000
committerKarl Berry <karl@freefriends.org>2009-04-02 18:41:54 +0000
commit5c628436fda45c9dcae5c2382445eb7d3395d1d6 (patch)
tree0be44bd8de77efeff373de91415e051a1ccc6b38 /Master
parent01fcf064ed469deec1daa3aecec26ab905dd50c2 (diff)
todonotes update (31mar09)
git-svn-id: svn://tug.org/texlive/trunk@12606 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rw-r--r--Master/texmf-dist/doc/latex/todonotes/todonotes.pdfbin193836 -> 198935 bytes
-rw-r--r--Master/texmf-dist/doc/latex/todonotes/todonotesexample.pdfbin28184 -> 28184 bytes
-rw-r--r--Master/texmf-dist/source/latex/todonotes/todonotes.dtx84
-rw-r--r--Master/texmf-dist/tex/latex/todonotes/todonotes.sty14
4 files changed, 91 insertions, 7 deletions
diff --git a/Master/texmf-dist/doc/latex/todonotes/todonotes.pdf b/Master/texmf-dist/doc/latex/todonotes/todonotes.pdf
index 85f77b4b847..79be4eadc1a 100644
--- a/Master/texmf-dist/doc/latex/todonotes/todonotes.pdf
+++ b/Master/texmf-dist/doc/latex/todonotes/todonotes.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/todonotes/todonotesexample.pdf b/Master/texmf-dist/doc/latex/todonotes/todonotesexample.pdf
index 1177970148d..2fc26c70514 100644
--- a/Master/texmf-dist/doc/latex/todonotes/todonotesexample.pdf
+++ b/Master/texmf-dist/doc/latex/todonotes/todonotesexample.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/todonotes/todonotes.dtx b/Master/texmf-dist/source/latex/todonotes/todonotes.dtx
index 3ab1952f8f1..8bf91f5b7d3 100644
--- a/Master/texmf-dist/source/latex/todonotes/todonotes.dtx
+++ b/Master/texmf-dist/source/latex/todonotes/todonotes.dtx
@@ -22,14 +22,14 @@
%<package>\NeedsTeXFormat{LaTeX2e}[1999/12/01]
%<package>\ProvidesPackage{todonotes}
%<*package>
- [2009/01/09 .dtx Todonotes source and documentation.]
+ [2009/03/31 .dtx Todonotes source and documentation.]
%</package>
%
%<*driver>
\documentclass{ltxdoc}
\usepackage{wrapfig}
\usepackage[colorlinks, linkcolor=black]{hyperref}
-\usepackage[colorinlistoftodos, shadow]{todonotes}[2009/01/09]
+\usepackage[colorinlistoftodos, shadow]{todonotes}[2009/03/31]
\usepackage{amsmath}
\usepackage{setspace}
\setcounter{tocdepth}{2}
@@ -46,7 +46,7 @@
%</driver>
% \fi
%
-% \CheckSum{398}
+% \CheckSum{412}
%
% \CharacterTable
% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
@@ -132,6 +132,10 @@
% \changes{0.8.2}{2009/02/04}{Italian translation by Gustavo
% Cevolani. Removed the dependence on the hyperref
% package.}
+% \changes{0.8.3}{2009/03/31}{Added a use case for linking to the
+% list of todos, idea from Andreas Plank. Introduced a
+% package option for listening to the draft option given
+% to the document class.}
%
% \GetFileInfo{todonotes.dtx}
%
@@ -222,6 +226,13 @@
% |\missingfigure|) are defined as macros with no effect, and thus
% all inserted notes are removed.
%
+% \DescribeMacro{obeyDraft}
+% When the option |obeyDraft| is given, the package checks
+% if the option |draft| is given (this option is usually given to
+% the documentclass). If the |draft| option is given, the
+% functionality of the package is enabled and otherwise the effect
+% of the package is disabled.
+%
% \DescribeMacro{danish, german, french}
% \DescribeMacro{spanish, catalan, italian}
% Use the danish or german translations of the text strings
@@ -713,6 +724,52 @@
% }
%
%
+%
+% \subsubsection{Link to list of todos}
+%
+% Using the |hyperref| package it is possible to add a link from
+% the inserted todonotes to the list of todos.
+% The example were supplied by Andreas Plank.
+% \begin{verbatim}
+% % Define a counter for the inserted todonotes.
+% \newcounter{todoListItems}
+% \newcommand{\todoTrans}[2][ ]{
+% % Increment counter
+% \addtocounter{todoListItems}{1}
+% \todo[%
+% caption={\protect\hypertarget{todo\thetodoListItems}{} Translation},
+% #1]
+% {
+% #2 \hfill
+% \hyperlink{todo\thetodoListItems}{$\uparrow$}
+% }
+% }
+% \end{verbatim}
+%
+% \newcounter{todoListItems}
+% \newcommand{\todoTrans}[2][ ]{
+% \addtocounter{todoListItems}{1}
+% \todo[
+% caption={\protect\hypertarget{todo\thetodoListItems}{} Translation},
+% #1]{
+% #2 \hfill
+% \hyperlink{todo\thetodoListItems}{$\uparrow$}
+% }
+% }
+%
+% The idea behind the code is to embed a |hypertarget| in each entry
+% in the list of todos. In the todonotes a link to the entry in the
+% list of todos is inserted as an arrow that points upwards.
+% Using the |\todoTrans| command like below, the following two notes
+% have been inserted.
+% \begin{verbatim}
+% \todoTrans{papirsflyver}
+% \todoTrans[inline]{damplokomotiv}
+% \end{verbatim}
+% \todoTrans{papirsflyver}
+% \todoTrans[inline]{damplokomotiv}
+%
+%
% \iffalse
% \StopEventually{\PrintChanges\PrintIndex}
% \fi
@@ -723,7 +780,7 @@
%
% Identifies the package and loads the packages dependences.
% \begin{macrocode}
-\ProvidesPackage{todonotes}[2009/01/09]
+\ProvidesPackage{todonotes}[2009/03/31]
\RequirePackage{ifthen}
\RequirePackage{xkeyval}
\RequirePackage{xcolor}
@@ -811,6 +868,13 @@
\newcounter{@todonotes@numberoftodonotes}
% \end{macrocode}
%
+% Toggle whether the package should obey the global draft option.
+% \begin{macrocode}
+\newif{\if@todonotes@obeyDraft}
+\DeclareOptionX{obeyDraft}{\@todonotes@obeyDrafttrue}
+\newif{\if@todonotes@isDraft}
+\DeclareOptionX{draft}{\@todonotes@isDrafttrue}
+% \end{macrocode}
% Make it possible to disable the functionality
% of the package. If this option is given, the
% commands |\todo{}| and |\listoftodos| are defined
@@ -897,7 +961,17 @@
% \begin{macrocode}
\ProcessOptionsX
% \end{macrocode}
-
+% If the |obeyDraft| is given, check whether the |draft|
+% option is given and enable or disable the functionality of this
+% package.
+% \begin{macrocode}
+\if@todonotes@obeyDraft
+ \@todonotes@disabledfalse
+ \if@todonotes@isDraft
+ \@todonotes@disabledtrue
+ \fi
+\fi
+% \end{macrocode}
% \subsection{Options for the todo command}
%
diff --git a/Master/texmf-dist/tex/latex/todonotes/todonotes.sty b/Master/texmf-dist/tex/latex/todonotes/todonotes.sty
index ac1a8f8da41..b825597f50c 100644
--- a/Master/texmf-dist/tex/latex/todonotes/todonotes.sty
+++ b/Master/texmf-dist/tex/latex/todonotes/todonotes.sty
@@ -22,9 +22,9 @@
%%
\NeedsTeXFormat{LaTeX2e}[1999/12/01]
\ProvidesPackage{todonotes}
- [2009/01/09 .dtx Todonotes source and documentation.]
+ [2009/03/31 .dtx Todonotes source and documentation.]
-\ProvidesPackage{todonotes}[2009/01/09]
+\ProvidesPackage{todonotes}[2009/03/31]
\RequirePackage{ifthen}
\RequirePackage{xkeyval}
\RequirePackage{xcolor}
@@ -94,6 +94,10 @@
\@todonotes@SetMissingFigureDown{mancante}%
}
\newcounter{@todonotes@numberoftodonotes}
+\newif{\if@todonotes@obeyDraft}
+\DeclareOptionX{obeyDraft}{\@todonotes@obeyDrafttrue}
+\newif{\if@todonotes@isDraft}
+\DeclareOptionX{draft}{\@todonotes@isDrafttrue}
\newif{\if@todonotes@disabled}
\DeclareOptionX{disable}{\@todonotes@disabledtrue}
\newif{\if@todonotes@colorinlistoftodos}
@@ -124,6 +128,12 @@
\define@key{todonotes.sty}%
{figwidth}{\renewcommand{\@todonotes@figwidth}{#1}}
\ProcessOptionsX
+\if@todonotes@obeyDraft
+\@todonotes@disabledfalse
+\if@todonotes@isDraft
+\@todonotes@disabledtrue
+\fi
+\fi
\newcommand{\@todonotes@currentlinecolor}{}%
\newcommand{\@todonotes@currentbackgroundcolor}{}%