Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I want to make a double-sided problem booklet that contains several questions. Each question has a distinct number and may have zero or more figures. Each figure has a caption and floats on the outer margin. The following figure illustrates what I want to have.

enter image description here

Is there a document class or package to do this out of the box? If the answer is NO, then how to create such a problem booklet?

share|improve this question
    
Marginpar can be a "floating object" with some packages/customizasiont. I can't look into that now as I have to leave, but this is a consideration. –  tohecz Apr 24 '12 at 14:09
    
tufte class`! –  Harish Kumar Apr 24 '12 at 14:38

1 Answer 1

up vote 15 down vote accepted

As tohecz mentions in his comment, you can use \marginpar for your purpose; using \captionof (from the caption or capt-of packages) you can provide the captions.

\documentclass[twoside]{article}
\usepackage[outermargin=2cm,innermargin=5cm,marginparwidth=3cm,marginparsep=20pt]{geometry}
\usepackage[demo]{graphicx}
\usepackage{marginnote}
\usepackage{caption}
\usepackage{lipsum}

\newcommand\MarginFig[4][width=\marginparwidth]{%
\marginpar{\includegraphics[#1]{#2}
\captionof{figure}{#3}
\label{#4}}
}

\reversemarginpar

\begin{document}
%\layout
text\MarginFig{name1}{description for figure one}{fig:test1} \lipsum[1-2]\MarginFig{name2}{description for figure one}{fig:test2}
\lipsum[1]\MarginFig[height=7cm,width=\marginparwidth]{name3}{description for figure three}{fig:test3}\lipsum[1-3]
text\MarginFig[height=7cm,width=\marginparwidth]{name4}{description for figure four}{fig:test4} \lipsum[1]\MarginFig{name5}{description for figure five}{fig:test5}\lipsum[2]\MarginFig{name6}{description for figure six}{fig:test6}\lipsum[1-3]

\end{document}

enter image description here

In the code above I used the \reversemarginpar command and the geometry package to customize the page layout in order to obtain the result shown in the original question (images in the left margin for odd-numbered pages and images in the right margin for even-numbered pages). Those settings are, of course, optional.

share|improve this answer
    
I think I don't need \reversemarginpar to meet the requirements in the question, i.e., all figures float on the outer margin. –  In PSTricks we trust Apr 24 '12 at 15:55
1  
@Moderator: OK; I wasn't sure if you needed it or not since your image suggested using the leftmargin for odd pages and the rightmargin for even pages. –  Gonzalo Medina Apr 24 '12 at 15:57
    
Sorry, is marginnote necessary in this case? –  In PSTricks we trust Sep 27 '13 at 6:20

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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