%% %% This is file `todo.sty', %% generated with the docstrip utility. %% %% The original source files were: %% %% todo.dtx (with options: `package') %% %% Copyright 2002-10 Federico Garcia %% \NeedsTeXFormat{LaTeX2e}[1995/12/01] \ProvidesPackage{todo}[2010/03/31 v2.4142 To-do list (Federico Garcia)] \RequirePackage{amssymb} \newtoks\@todotoks\@todotoks{} \newif\if@todo\@todotrue \newcounter{todo}\setcounter{todo}{0} \newcommand*\todomark{To~do} \newcommand*\todoname{To do\dots} \newcommand\@todomark{} \let\@todohide\relax \let\todoformat\bfseries \DeclareOption{nothing}{\renewcommand*\@tododisplay[1]{}} \DeclareOption{hide}{\let\@todohide\@gobble \renewcommand*\@tododisplay[1]{% \PackageWarning{todo}{`hide' option used, ignoring \string\todo's}}} \DeclareOption{superscript}{\let\@tododisplay\textsuperscript} \DeclareOption{marginpar}{\renewcommand*\todoformat{\sffamily\raggedright\small}% \let\@tododisplay\marginpar} \DeclareOption*{\typeout{Unknown option (`\CurrentOption')}} \ExecuteOptions{superscript} \ProcessOptions \newcommand\todos{% \ifnum\c@todo>0 \@todohide{% \clearpage\section*{\todoname}\large% \begin{list}{$\Box$% \quad\arabic{todo}}{}% \usecounter{todo} \the\@todotoks \end{list}} \renewcommand*\todo{% \PackageWarning{todo}{All \string\todo\space commands are ignored after \string\todos}% \@ifnextchar*{\@todogobble}{\@todogobble*}}% \let\Todo\todo \renewenvironment{todoenv}{\PackageWarning{todo}{\string\todoenv\space after \string\todos\space not processed as a todo item}}{}% \renewcommand\todos{\PackageError{todo}{Second \string\todos\space ignored}% {I can only make one list of todo items. I'll be Ok if you press enter, but all \string\todo\space commands after the first \string\todos\space have been ignored.}}% \else \PackageWarning{todo}{Nothing \string\todo! I'm ignoring the \string\todos\space command}% \fi } \newcommand\@todogobble[1]{\@@todogobble} \newcommand\@@todogobble[2][\todomark]{\relax} \newcommand\todoitem[2]{% \item \label{todolbl:\thetodo}% (p.~\pageref{todopage:\thetodo}): {\todoformat\ifx#1\todomark\else#1 \fi}#2}% \newcommand\doneitem[2]{% \stepcounter{todo}% \item[\rlap{$\checkmark$}$\Box$\quad \arabic{todo}]\@nameuse{@done\the\c@todo}(p.~\pageref{todopage:\thetodo}): {\todoformat\ifx#1\todomark\else#1 \fi}#2} \newcommand\done[2][\relax]{% \ifx#2\todo\@todofalse\else \ifx#2\Todo\@todofalse\else \PackageWarning{Floating \string\done\space ignored.}% \fi\fi \@tempcnta\c@todo\advance\@tempcnta1 \@namedef{@done\the\@tempcnta}{#1 }#2% } \newcommand\@newtodo{\refstepcounter{todo}\label{todopage:\thetodo}} \newcommand*\todo{\@ifnextchar*{\@newtodo\@displaynothing}{% \@newtodo \if@todo \expandafter\@displaytodo \else \expandafter\@donetodo \fi}} \newcommand\Todo{\@ifnextchar*{% \PackageWarning{todo}{Starred \string\Todo* taken as\string\todo*}% \expandafter\todo}% {\@newtodo\@displayfulltodo}} \newenvironment{todoenv}{\@newtodo \global\@todotoks\expandafter{\the\@todotoks\relax\todoitem {}{{\itshape see text.}}}% \todoopen\todoenvformat}{\todoclose} \newcommand*\astodos[1]{\@tododisplay{{\todoformat #1}}} \newcommand*\todoopen{\astodos{\todomark\ begin}} \newcommand*\todoclose{\astodos{\todomark\ end \normalfont(\ref{todolbl:\thetodo})}}\newcommand\todoenvformat{} \newcommand\@displaytodo[2][\todomark]{% \@tododisplay{{\todoformat #1} (\ref{todolbl:\thetodo})}% \global\@todotoks\expandafter{\the\@todotoks\todoitem{#1}{#2}}% \@todotrue } \newcommand\@displaynothing[1]{\@@displaynothing} \newcommand\@@displaynothing[2][\todomark]{% \if@todo \global\@todotoks\expandafter{\the\@todotoks\todoitem{#1}{#2}}% \else \global\@todotoks\expandafter{\the\@todotoks\doneitem{#1}{#2}}% \fi \@todotrue } \newcommand\@displayfulltodo[2][\todomark]{% \if@todo \@tododisplay{{\todoformat #1} #2 (\ref{todolbl:\thetodo})}% \global\@todotoks\expandafter{\the\@todotoks\todoitem{#1}{#2}}% \else \global\@todotoks\expandafter{\the\@todotoks\doneitem{#1}{#2}}% \fi \@todotrue } \newcommand\@donetodo[2][\todomark]{% \global\@todotoks\expandafter{\the\@todotoks\doneitem{#1}{#2}}% \@todotrue } \endinput %% %% End of file `todo.sty'.