2

I want to add point in the left margin like shown on the image below.

Image

Points should be defined at the same line of each item. They would appear in the margin without changing anything else in the document (so no modification in spacing or in marging width).

How to do that ? I tested multiple solution but each time I got modification in spacing.

Please note that I don't want a package for creating questions. Only something to add thing in the left margin.

Thanks.

6
  • 1
    exsheets or xsim can probaly do this. Without more information, the question is a bit broad.
    – Johannes_B
    May 3, 2018 at 5:01
  • Example with screenshot
    – Johannes_B
    May 3, 2018 at 5:03
  • I added information to my post, I don't want a package allowing to create exam which also allowing to show point in margin. I search for a command that I can add to my current document (and who could also work for differents documents who aren't exam).
    – Matheod
    May 3, 2018 at 5:05
  • tikz, esopic can always do something like that.
    – Johannes_B
    May 3, 2018 at 5:13
  • While looking at the exsheets package documentation, I found some text in the margin, and after looking in the documentation source and doing some research I discovered the marginpar command. \reversemarginpar\marginpar{\hspace{1cm}1pt} do exactly what I want
    – Matheod
    May 3, 2018 at 5:16

2 Answers 2

1

A way is using the \marginnote conmand in marginnote package (that enhances the marginpar command of LaTeX). TikZ is also can be used for customizing.

From a Willie's comment in this topic: Note that \reversemarginpar is a command that, when issued, forces all \marginpars created after to be put on the opposite side of normal (that is, on the left instead of right for single sided documents, and on the inside edge as opposed to the outside edge for double sided documents)

enter image description here

%https://www.overleaf.com/learn/latex/Margin_notes
% https://tex.stackexchange.com/questions/491013/how-do-i-toggle-the-normal-reverse-marginpar
\documentclass[]{article}
\usepackage{lipsum,tikz}
\usepackage{marginnote}

\begin{document}

\noindent{\bfseries Problem 1.} 
\reversemarginpar
\marginnote{\color{red}1 point}
\lipsum[1]  
\vspace*{1cm}

\noindent{\bfseries Problem 2.} 
%\reversemarginpar
\marginnote{\tikz\node[fill=yellow]{1.5 point};}
\lipsum[2]
\vspace*{1cm}

\normalmarginpar\marginnote{\tikz\path (0,-2) node[below,blue,text width=2.5cm]{Back to the right of the paragraph};}
\lipsum[3]
\end{document}
0
\reversemarginpar\marginpar{\hspace{1cm}1pt}
1
  • Perhaps this answer could contain a little explanation and where you'd put it?
    – CJBrew
    Mar 28, 2019 at 11:07

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .