1

I wish to recreate the dotted-line "answer box" seen below. What is the simplest and easiest way to do this? I do not need any of the other functionality of the exam class, so I would rather not use that.

Example of dotted-line answer box

I would like the lines to be linewidth in length (so that the length of the lines depend on which level 1)a)i) of the question I'm at), and be 8 mm (0.3 in) apart. I would prefer to specify the number of lines, rather than the space they occupy, but am not averse to simply copy-and-pasting a command once per line required.

It would be a bonus if I could (occasionally) prefix the lines, so when asking for two answers I could have:

1: ...............

2: ...............

2

For this example I will use a simple list with \dotfill for the dotted lines.

\documentclass{article}

\begin{document}

\begin{enumerate}
    \item Question
    \begin{enumerate}
        \item SubQuestion \label{a}
        \item SubQuestion \label{b}
    \end{enumerate}
    \subitem \ref{a} \dotfill
    \subitem \dotfill
    \subitem \ref{b} \dotfill
\end{enumerate}

\end{document}

enter image description here

You could also define your own command \newcommand\mydotfill{\dotfill\vspace*{...}} to influence the space between the dotted lines.

1
  • 1
    I found that changing the textsize of the \dotfill will also have the desired effect, and looks a bit better (in my opinion). So, I would suggest \newcommand\mydotfill{\tiny\dotfill} or something similar. – sk8forether May 24 '17 at 15:29

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.