I'm trying to create a \tbd
(To Be Done) macro to add a todonote on a chapter/section/subsection/etc easily with the following properties.
- to have a useful list of todos with a simple macro call: the todolist entry should represent the place of the todo inside the structure of the document (in the chapter named "C" it should have "TBD: C", in section "S" inside "C" it should have "TBD: C/S")
- to avoid redundancy: I don't want to type the section title as a caption parameter each and every time. What if I want to change the title?
- to display TBD in the note only (this seems to be more elegant)
- preferred: keep the name of the command as
\section
(and others) (with the use of an optional argument maybe?) - preferred (but seems to be unlikely): without messing with the definition of
section
and friends - preferred (but seems to be really messy): with the todonote "pointing" at the title
Note: I've considered the possibility to put \tbd
inside the section command (\section{title\tbd}
) for the todonote
to point at the right place, but this seems to be more pain than gain. Especially if I want to use the title...
Something like this (the blue bordered things are on different pages):
Is there a macro/package for this or does any of you have a similar implementation?
Example is shown using a half (or less) solution. Can I list the current stack of chapter/section/etc somehow?
\documentclass{book}
\usepackage{todonotes}
\newcommand\treeloc{dummy} % this should be replaced
\newcommand\tbd{\todo[caption={TBD: \treeloc}]{TBD}}
\begin{document}
\chapter{C-1}
\section{S-1}\tbd
\section{S-2}
\chapter{C-2}\tbd
\section{S-1}
\section{S-2}
\subsection{SS-1}\tbd
\section{S-3}
\listoftodos
\end{document}
And \treeloc
should be changed for the todolist to have these instead of dummies:
- C-1/S-1
- C-2
- C-2/S-2/SS-1
I'm going to work on this, but I thought this was a nice question.
References (I'm considering to use):