6

I want to delimit margin note area by a background color for all the document like in some nice books.

I tried with marginnote and todonote packages without success.

You are my last hope...

7

This is a job for the background and tikzpagenodes packages:

\documentclass{book}
\usepackage{tikzpagenodes}
\usepackage{background}
\usepackage{lipsum}

\backgroundsetup{
scale=1,
angle=0,
contents={\tikz[remember picture,overlay]\fill[red!30] (current page marginpar area.north west) rectangle (current page marginpar area.south east);
}}

\begin{document}
\lipsum[1-15]
\end{document}

enter image description here

The code needs two or three runs to stabilize.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.