Information Technology Reference
In-Depth Information
and cannot be considered when placing a note. The first label is placed beside
the first site, and the following ones are placed below. Often it happens that a
lot of free space is wasted above the topmost label, while the bottommost label
is only partially visible (if at all), see Fig. 4a. Another disadvantage is that the
\marginpar method cannot be used inside floating environments such as tables
or algorithms. While the packages fixme and fixmetodonotes do not draw any
leaders, todonotes uses opo -leaders. With this leader style it is hard to match
a note to its corresponding site in the text when there are many comments in
a short piece of text. A similar problem occurs with the leader style used by
LibreOce; see Fig. 1.
Other Latex packages support annotations as metadata for PDF documents,
for example, pdfcomment [11]. The drawback of this package is that the user
needs a compatible PDF viewer and that the annotations cannot be printed
with the text. Packages such as easy-todo [14] don't place annotations in the
margins, but insert a marker into the text and list all comments at the end of
the document.
Our contribution. Our approach is different from all those listed above in that
we collect the comments for a whole page and then compute a good place-
ment for the labels. Of course, this computation needs more resources than
the ad-hoc placement of the existing packages. Additionally, our Latex pack-
age supports different leader types, which the user can select when loading the
package; see Section 2. We give several algorithms for non-uniform labels, most
of which are extensions of existing algorithms for the one-sided case; see Sec-
tion 3. We improve upon these basic algorithms by considering label clustering
and the two-sided case; see Section 4. We have implemented all of our algo-
rithms and have evaluated them experimentally; see Section 5. We conclude
with some open problems; see Section 6. The package is available on CTAN:
http://ctan.org/pkg/luatodonotes
2
Implementation
We have implemented the algorithms in Lua and have bundled them into a
Luatex package, which we call luatodonotes . The package requires the modern
Tex-processor Luatex [8], which allows us to embed Lua code inside our Tex
sources. This gives us access to a high-level programming language for imple-
menting our label-placement algorithms. From the user's point of view, this does
not change much. Luatex is part of every modern Tex installation, for example,
Tex Live. Assuming such an installation, the difference in usage is simply that
instead of calling ( pdf ) latex , the user calls lualatex .
Our package is based on the todonotes package (see Section 1). It is down-
ward compatible as it provides the same commands to the user as the original
package. Usage is quite simple: the user loads the package with the command
\usepackage{luatodonotes} and inserts a comment into the text with the
command \todo{comment text} .
 
Search WWH ::




Custom Search