# Minipages and spacing between \paragraph

I am using \paragraph inside a minipage. Don't know why, but the usual space above \paragraph does not appear. Then I have a small minipage in the \paragraph. Now spacing between \paragraph is increased (maybe back to normal). Why is this happening, and how can I fix it? I would like \paragraph to behave the same as outside the minipage (no vertical space if at the top of the page, slightly elastic vertical space thereafter, don't need numbering).

\documentclass{article}

\begin{document}

\noindent
\begin{minipage}[t]{0.9\linewidth}
\paragraph{A} Blah
\paragraph{B} Blah
\paragraph{C} Blah
\newline
\begin{minipage}[t]{0.5\linewidth}
BLAH BLAH
\end{minipage}
\newline
More blah
\paragraph{D} Blah
\paragraph{E} Blah
\end{minipage}

\end{document}

• You are probably misusing \paragraph ;). Why do you want to use it here? It does not seem appropriate to start new sections within a minipage. \paragraph{} is for starting a new section, a sub-division of a sub-sub-section. It is not for starting a new paragraph. It just has a confusing name. To start a new paragraph, leave a blank line. (Or use \par but a blank line is better in most places.) – cfr Aug 3 '15 at 2:16
• I am using the minipage to get a bit of text of less width than the rest of the document, and I wanted the same sectioning and formatting within the minipage as elsewhere. – user27080 Aug 3 '15 at 2:29
• You want 5 sectional divisions on a single page? – cfr Aug 3 '15 at 2:57
• \newline is (almost) always wrong, and probably not what you want. You are getting the same formatting, by the way. A minipage is a small page so, just like for a regular page, vertical space is not needed at the top. But by the time you've given each \paragraph its title, is there much space left to say anything in each section? – cfr Aug 3 '15 at 3:01
• I made a simple example showing the problem I have encountered. There is no spaces between \paragraphs at first, and after the second minipage somehow there is a persistent space before each \paragraph. Doesn't seem logical to me. – user27080 Aug 3 '15 at 3:21

We can use \mbox{} in the beging of the minipage

\documentclass{article}

\begin{document}
\noindent
\begin{minipage}{0.9\linewidth}
\mbox{}
\paragraph{A} Blah
\paragraph{B} Blah
\paragraph{C} Blah
\newline
\begin{minipage}[t]{0.5\linewidth}
BLAH BLAH
\end{minipage}
\newline
More blah
\paragraph{D} Blah
\paragraph{E} Blah
\end{minipage}

\end{document}


An other solution is \parbox

\documentclass{article}

\begin{document}

\noindent
\parbox[t]{0.9\linewidth}{
\paragraph{A} Blah
\paragraph{B} Blah
\paragraph{C} Blah
\newline
\parbox[t]{0.5\linewidth}{
BLAH BLAH
}
\newline
More blah
\paragraph{D} Blah
\paragraph{E} Blah
}

\end{document}


You say you want a bit of text with less width than the rest of the document. If that's all you want, I'd suggest you try the addmargin environment:

\begin{addmargin}[4em]{1em}
foo bar


Usage is \begin{addmargin}[<left indentation>]{<indentation>}. There is a starred variant addmargin* where the optional parameter stands for the inner margin.

In order to use this environment, you must either use one of the KOMA script classes (texdoc scrguien) or \usepackage{scrextend}.

According to the KOMA user manual:

Similar to quote and quotation, the addmargin environment changes the margin. In contrast to the first two environments, with addmargin the user can set the width of the indentation. Besides this, this environment does not change the indentation of the first line nor the vertical spacing between paragraphs.

(see page 112)

\documentclass{article}
\usepackage{lipsum}
\usepackage{scrextend}

\begin{document}

\lipsum[1]

\lipsum[2]

• You might have said that before.... :) How much "stuff" do you want to put there? Is it more like a marginpar (some keywords and/or symbols) or more like a multi-column environment? Is the "stuff" linked to the main text and, if so, how tightly? – Philipp Imhof Aug 3 '15 at 8:18
• What about \usepackage{parcolumns} ? It has some limitations, but might get the job done. However, quick testing showed me that the use of \colchunk (in order to change the column deliberately), also changes the vertical spacing between paragraphs. – Philipp Imhof Aug 3 '15 at 9:31