% a bunch of empty space at the start of the frame.
\framed[offset=0mm,location=middle,strut=no,align=right,frame=off]{#1}
}
+
+% Define a \strikethrough command. For some reason, this does blue
+% strikethrough, sometime that still needs fixing. We add some offset,
+% since the strikethrough is just below the middle for some reason.
+\definetextbackground
+ [strikethrough]
+ [location=text,
+ alternative=4,
+ voffset=0.5mm,
+ background=,
+ frame=off]
+
+\def\setwidthof#1\to#2%
+{\bgroup
+\setbox\scratchbox\hbox{#1}%
+\expanded{\egroup\def\noexpand#2{\the\wd\scratchbox}}}
+
+% Allow \emph{foo} (and {\emph foo}, but that's not really needed).
+\definealternativestyle[emph][\em][]
+
+% Put a bit of space betwen paragraphs, to make them easier to distinguish.
+\setupwhitespace[small]
+
+% Only show three levels in the table of contents. Passing level= to
+% setupcombinedlist didn't seem to work, so we'll do it like this.
+\definecombinedlist [content][chapter,section,subsection]
+% Use the c alternative for the toc, which uses dots between the section
+% name and the page number.
+\setupcombinedlist [content][alternative=c]
+
+% vim: set sw=2 sts=2 expandtab: