Skip to main content
10 votes

marginnote always on right side of the page

Further to my comment a few days ago, if you are using the version of the marginnote package dated 2018/04/13 (or newer, at the time of writing), then you need to redefine \@mn@@@marginnote in a ...
rbrignall's user avatar
  • 1,574
10 votes

starting new paragraph with \marginpar that is correctly aligned

\documentclass[a4paper,11pt]{scrartcl} \usepackage[utf8]{inputenc} \newcommand{\introduce}[1]{\mbox{}\marginpar{#1}\emph{#1}} \begin{document} Bacon ipsum dolour sit amet porchetta beef turkey, ...
David Carlisle's user avatar
10 votes
Accepted

starting new paragraph with \marginpar that is correctly aligned

Add \leavevmode so the paragraph will be started anyhow. \documentclass[a4paper,11pt]{scrartcl} \usepackage[utf8]{inputenc} \newcommand{\introduce}[1]{% \leavevmode % if at the start of a ...
egreg's user avatar
  • 1.1m
8 votes

Tweak showlabels/showkeys - wrap the label

In order to split a long label without spaces, you can use the \seqsplit command from the seqsplit package. The following is an adaption of David's answer and also shows the necessity of wrapping long ...
Thorsten's user avatar
  • 332
7 votes

marginpar have changed,is it a bug?

The problem is that you are using \pagenumbering which resets the page number and so you have two pages with the number 1. This confuses mparhack (and hyperref wouldn't like it too). Give the ...
Ulrike Fischer's user avatar
7 votes
Accepted

Memoir citation in margin

Since it is quite tricky to create a \marginpar from within a superscript this approach uses the two-pass structure employed by \textcite. \documentclass[letterpaper,twoside,openany]{memoir} \...
moewe's user avatar
  • 178k
7 votes
Accepted

Caption in margin not properly positionned

Looking carefully to the provided images I suspected that the problem may be that the distance separating float and caption is not well adjusted and should be equal to \marginparsep. A quick search ...
Hafid Boukhoulda's user avatar
7 votes

Imitate Email-reply layout: Vertical line in left margin, except for responses

\documentclass{article} \usepackage[most]{tcolorbox} \tcbuselibrary{breakable} \tcbuselibrary{skins} \newtcolorbox{emailstart}[3][]{% standard jigsaw, opacityframe=0, opacityback=0, ...
Vinccool96's user avatar
7 votes
Accepted

top-aligned marginpar on wrong side (even/odd) after pagebreak

The problem is that when LaTeX constructs the margin note "III", it chooses side based on the page counter which still contains 1 (LaTeX usually collects more material than fits one page before ...
Sergei Golovan's user avatar
6 votes
Accepted

How to create simple comments in a margin next to the Document?

The simple answer is the command \marginpar{} or, for a bit more control, the package marginnote. Their usage is described here. The example in the question above was created with the following code: ...
dervonnebenaan's user avatar
6 votes
Accepted

Set heading in the margin to the left of text

Here are five examples of what can be done withe leftmargin shape: \documentclass[12pt,]{article} \usepackage[showframe, marginparwidth=60pt]{geometry} \usepackage[svgnames, table]{xcolor} \...
Bernard's user avatar
  • 273k
6 votes

Margin note automatic concatenation

Based on Davids idea a made up a version using \marginpar which has the advantage that 1. the notes are alway on the right side of the text and that the settings for margin pars (\marginparsep and \...
Tobi's user avatar
  • 56.8k
6 votes
Accepted

marginpar text alignment

This automates Ben Stern's answer using the KOMA Script test \ifthispageodd (through scrextend given the use of the book class) and defining an \alignedmarginpar which aligns right on left pages. \...
gusbrs's user avatar
  • 14k
6 votes

marginpar text alignment

There is an optional argument to \marginpar that allows to specify the left-side text. This allows to create the \alignedmarginpar solution from gusbrs' answer without the need for additional packages:...
Mr Tsjolder from codidact's user avatar
5 votes

Margin notes with the same behaviour as footnote?

I used the marginfix package (ctan-link) to fix the spacing of the sidenotes. Like the linked answer in the comments, it doesn't break sidenotes running of the page, but shifts them up to fit on the ...
Wiebke's user avatar
  • 933
5 votes
Accepted

Flipbook Image Placement within Komaclass scrbook

I would declare an own layer for the flipbook which can be added to the page styles scrheadings and plain.scrheadings. Then you can still use \ohead and \rohead for other contents. \documentclass{...
esdd's user avatar
  • 86.1k
5 votes

Why `parskip` package makes margin notes misaligned?

In your example you are missing one of the arguments of your \degree command: It has 5 mandatory arguments but are only giving 4. Beside this, it is normally better not to issue \marginnote in ...
Ulrike Fischer's user avatar
5 votes
Accepted

margins with landscape and page header

You can use \reversemarginpar inside the landscape environment: \documentclass[a4paper]{scrreprt} \usepackage{lipsum} \usepackage{pdflscape} \usepackage[headsepline]{scrlayer-scrpage} \pagestyle{...
Bernard's user avatar
  • 273k
5 votes
Accepted

Automatic positioning of marginpar (to avoid page overflow)

Does this code solve your problem? \documentclass{article} \usepackage{lipsum} \newcommand{\bmarginpar}[1]{\marginpar{\parbox[b]{\marginparwidth}{\tiny#1}}} \begin{document} \lipsum[1-5] \...
Bernard's user avatar
  • 273k
5 votes
Accepted

How are the command names on the side in CTAN docs typeset

The alignment is messed up because marginpar is being invoked in vertical mode. A \leavevmode remedies the issue. As to \ttfamily, it can just be added to the marginpar. \documentclass{article} \...
Steven B. Segletes's user avatar
4 votes
Accepted

qrcode in bibliography margin/bibliography entry with height of marginpar-content

You could wrap all entries with a QR code in a \parbox of fixed height: \documentclass[]{article} \begin{filecontents}{\jobname.bib} @misc{example1, title = {Example.com}, url = {http://...
samcarter_is_at_topanswers.xyz's user avatar
4 votes
Accepted

Footnote with number in margin

You can use the pair of commands \footnotemark and \footnotetext as follows: \documentclass{article} \newcommand{\marginfootnote}[1]{\marginpar{\footnotemark}\footnotetext{#1}} \begin{document} Can ...
Casper's user avatar
  • 246
4 votes
Accepted

Margin notes in an interlinear environment aligned with source text

Note: I do not have Arial or Calibri so I'm using libertine in the following example. You need marginnote release 1.2b from 22th April 2017 (or newer). Previous releases do not handle right-to-left ...
Schweinebacke's user avatar
4 votes

Align "bottom" of marginpar with "last" line of paragraph

Yes. Note that it pokes above the top of the text area. \documentclass{article} \begin{document} Some text some text some text some text some text some text some text some text some text some text ...
John Kormylo's user avatar
  • 81.1k
4 votes
Accepted

Place margin notes between columns (with twocolumn)

This does no checks on whether the notes will overprint, just swaps the side. \documentclass[landscape, twocolumn]{article} \usepackage{mwe} % only for blind text \usepackage{etoolbox} \setlength\...
David Carlisle's user avatar
4 votes

How to insert graphics into margins using memoir

What you must not do is try to use the figure environment which is a floating environment (marginal notes themselves are also floating envivonments). Just use, for example \includegraphics... or begin{...
Peter Wilson's user avatar
  • 28.3k
4 votes
Accepted

Avoid expansion of `\marginpar` argument

marginpars like floats and footnotes are fully typeset at the point they are entered, like \savebox they are placed on the page like \usebox which just copies a typeset formatted list, no expansion ...
David Carlisle's user avatar
4 votes
Accepted

Replace mathcal plus margin-note results in \reserved@a does not match definition

Undefining the \mathcal command is a bad hack, and you get punished for it. Change the alphabet with \SetMathAlphabet: \begin{filecontents}{\jobname.bib} @misc{example, author = {Example}, ...
Ulrike Fischer's user avatar
4 votes
Accepted

How to place two subfigures one above the other in the margin paragraph?

subcaption is what you need here. \documentclass[oneside,a4paper]{book} \usepackage{sidenotes} \usepackage{graphicx,lipsum,geometry} \usepackage{subcaption} %%% Page layout \geometry{% left=15mm, ...
JeT's user avatar
  • 3,652

Only top scored, non community-wiki answers of a minimum length are eligible