I'm trying to use marginnote on document class book with twoside, but I can't see to get the margin notes strictly on the left. I don't want to be putting \reversemarginpar on all the odd pages. Can someone help me or direct me to help please.
Asked
Active
Viewed 2,502 times
23
lockstep
- 250,273
jorge aldana
- 231
-
Welcome to TeX.sx! It's always good to provide add a minimal working example (MWE) that illustrates your problem. That speeds up providing solutions since the community does not have to create their own from scratch. – Werner Sep 18 '12 at 20:48
-
Related: http://tex.stackexchange.com/questions/69595/marginnote-always-on-right-side-of-the-page – lockstep Sep 18 '12 at 20:50
1 Answers
19
You can use the etoolbox package to patch the \@mn@margintest command to set \if@tempswa to be always true and then issue a global \reversemarginpar:
\documentclass[twoside]{book}
\usepackage[centering,marginparwidth=2.5cm,paperheight=10cm]{geometry}
\usepackage{marginnote}
\usepackage{lipsum}
\usepackage{etoolbox}
\makeatletter
\patchcmd{\@mn@margintest}{\@tempswafalse}{\@tempswatrue}{}{}
\patchcmd{\@mn@margintest}{\@tempswafalse}{\@tempswatrue}{}{}
\reversemarginpar
\makeatother
\begin{document}
\lipsum[1]\marginnote{test test test test test}
\lipsum[1-2]\marginnote{test test test test test}
\lipsum[1-2]\marginnote{test test test test test}
\lipsum[1-2]\marginnote{test test test test test}
\lipsum[1-2]\marginnote{test test test test test}
\lipsum[1-2]
\end{document}

Gonzalo Medina
- 505,128
-
Gonzalo Medina, thank you so much!!!!!!!!!!!!!!! It works perfect! – jorge aldana Sep 22 '12 at 18:36
-
1If you want it on the right instead, leave off the
\reversemarginparin Gonzalo's answer. I'm mentioning this because it took me a bit to figure it out. Also it is much simpler than Gonzalo's answer to the same problem here. (This should be a comment, but I don't have have enough reputation.) – Jason Rute Apr 21 '13 at 04:10 -
3This solution has recently stopped working with an updated version of marginnote I think... – Bart Snapp Sep 07 '18 at 15:46
-