{minipage} is an environment providing a paragraph box which is a complete mini version of a page.

learn more… | top users | synonyms

34
votes
2answers
3k views

How to keep a constant baselineskip when using minipages (or \parboxes)?

When a minipage is used to box a text paragraph, the first line of the minipaged text and the last line of the previous text paragraph are closer than two consecutive lines in a standard text ...
19
votes
2answers
1k views

Print programs with its proper syntax

I have defined my own language whose syntax is very close to the one of Pascal. I would like to type the following program for instance. Many people use the packages algorithmicx or algorithm2e to ...
28
votes
4answers
2k views

Fit text into given box by adjusting the fontsize

I would like to fit text (potentially several paragraphs) into a box of given size. This should be done by adjusting the fontsize of the contained text. Clarification edit: The given dimensions are ...
4
votes
1answer
306 views

Is there a replacement for nccmath?

I noticed that the nccmath package is not mentioned in What packages do people load by default in LaTeX?. Since I have had several problems with minipages that all eventually led to nccmath related ...
30
votes
3answers
10k views

Understanding minipages - aligning at top

I would like to be able to align two minipage at the top, without worrying about what is in the minipage. I am aware of the optional [t] parameter, but still have some confusion as to how this all ...
19
votes
2answers
14k views

Aligning image and text on top, with minipages

I have an image (on the left) and a block of text (on the right), and I would like both to be aligned on their top. I am trying to use minipages for that: \documentclass{article} \begin{document} ...
11
votes
2answers
936 views

highlight lines in listings

I have code that i have included into my document using the texcode below \begin{minipage}{.48\textwidth} \centering \lstinputlisting[numbers=left,xleftmargin=2em,frame=single,framexleftmargin=2em, ...
4
votes
2answers
203 views

nccmath affecting minipage widths

It seems that nccmath is affecting the layout of minipages. In the MWE, you can see the left minipage is clearly not taking up 70% of the page as I wanted. I'm hoping that there is an easy fix for ...
6
votes
3answers
1k views

Caption issue when placing figure side by side

I placed 2 figures side by side using the minipage method from this post, and the figures look perfectly fine. However, the caption of the right figure stick out into the margin, why is that and how ...
17
votes
2answers
2k views

How to preserve the same parskip in minipage

I have following structure: \begin{document} Paragraph1. Paragraph2. \begin{minipage} Some paragraph1. Some paragraph2. \end{minipage} \end{document} How can I make the same spacing between ...
10
votes
1answer
5k views

lstlisting in two columns

I would like to have two listings, side by side. They have approximately the same length, therefore I don't care about how it's layed out if one part is longer. I tried \begin{minipage}{\textwidth} ...
18
votes
1answer
1k views

Why is \parskip zero inside a minipage?

This question was originally entitled "inconsistent paragraph spacing with \parskip inside minipage" as the MWE below shows. But I found the answer at How to preserve the same parskip in minipage, ...
7
votes
2answers
2k views

Why is text being placed beyond the specified line width?

I thought that I knew a few things, but looks like I have some basic misunderstanding on how TeX is supposed to typeset material. I thought that settings by the geometry package would force the text ...
5
votes
2answers
1k views

Alignment of item number in list containing a minipage

I would like to have the list number at the beginning of the item, and not centered as is the case for item (b) the example below. If I comment out the \usepackage{nccmath}, I get this, but then the ...
24
votes
2answers
56k views

How to use figure inside a minipage?

I'm trying to include an image, and keep it centered, and prevent from wrapping from the next page. The following code works for that: \begin{minipage}{\textwidth} \begin{center} Caption ...
12
votes
2answers
2k views

How to change symbol for footnote in minipage

\renewcommand method does not work \documentclass{article} \renewcommand{\thefootnote}{\arabic{footnote}} \begin{document} \begin{minipage}{1.3\textwidth} test this\footnote{abc} \end{minipage} ...
4
votes
2answers
631 views

What is the best way of arranging multiple minipages on a page?

I have been trying to use mini-pages to produce the equivalent of Office text-boxes. The idea is to have panels of different sizes on a page such as 4 equal sized or one wide followed by two long ...
1
vote
1answer
265 views

Minipage content overlaps with text before that if nccmath is used

It seems that if the nccmath package is included, then the text in the following minipage overlaps with the text before that if the minipage contains only display math. The \FixMinipageForNccmath ...
38
votes
3answers
17k views

\parbox vs. minipage: Differences in applicability

Lamport, LaTeX: A document preparation system, states on p. 104: There are two ways to make a parbox at a given point in the text: with the \parbox command and the minipage environment. They can ...
14
votes
3answers
18k views

side by side minipage figures

I have this code where the part marked A is the same as the part marked B except that .4 in A is .45 in B. Even though they are so similar the first one puts the images side by side with the ...
5
votes
1answer
2k views

Ruled Algorithms in columns/minipages

I'm using Benoit Guillon's algo styles for Lyx (at http://bgu.perso.libertysurf.fr/) in 2.0 to get nice algorithms ruled with line numbers. This is just a wrapper for the algorithm and algorithmic ...
10
votes
3answers
4k views

How can I create a two-column layout with different widths (and texts) for the two columns?

I want to create a document in which there are two separate columns of content. The column on the left is normal text, with sections, environments, etc. The column on the right is figures, all roughly ...
18
votes
1answer
4k views

Can I get a normal footnote in a minipage environment in LaTeX? How?

I need to use a minipage environment and I need a footnote in that minipage. I want the footnote to be numbered in the normal footnote sequence and to occur together with the rest of the footnotes in ...
13
votes
4answers
2k views

In beamer class, how do I remove the additional vertical space before an itemize environment?

On a beamer slide, I want to produce something like I use the following LaTeX code, which works well in LaTeX with the article class. \begin{minipage}[t]{1.4cm} Questions: \end{minipage}\nobreak ...
8
votes
2answers
2k views

Changing minipage vertical alignment in mid-line?

Please consider the following MWE: \documentclass{article} \usepackage{lipsum} \usepackage[showframe,showcrop]{geometry} \begin{document} \section{Section 1} aa \fbox{\begin{minipage}{100pt} Box 1 ...
5
votes
1answer
262 views

Improper symbol mark of footnote in minipage environment

I think that the footmisc package has predefined the sympol mark series, but in minipage environment they become invalid. See below \documentclass{book} \usepackage[symbol*,stable]{footmisc} ...
4
votes
1answer
415 views

How to adjust macro to respect current \linewidth?

I'm having issues with text going past the end of the specified \textwidth. I posted this question about why text was being placed beyond the specified line width. The MWE provided there produced ...
3
votes
1answer
88 views

Put two figures side by side

There are already several threads that deal with this: they suggest having one figure and putting putting minipages inside, or using the subcaption package and having subfigure environments. However, ...
13
votes
3answers
5k views

Minipage spanning across pages

I'm looking for a way to span minipages across pages in LaTeX. I have a collection of recipes (presented through the recipe environment provided by the cuisine package) that varies in length, from ...
6
votes
1answer
4k views

How to put two minipages side-by-side, which use 100 % of the text width?

In draft-mode a black marker indicates that the reserved space is too low. This also appears in the following example, but it shouldn't. How can I put two minipages exactly side-by-side? ...
5
votes
1answer
3k views

How can I control the horizontal space between minipages?

I'm trying to place two mini pages next to each other, one with text, one with an image. But my code has them spaced really far apart. How can I bring them together horizontally. I've tried \hspace ...
3
votes
1answer
9k views

Fix the height/length of a minipage

I have 2 columns in 1 slide. On the left hand, it is a tabbing inside a minipage in a framed. Some sentences are shown one by one by overlay, that results in the height/length of the whole minipage ...
16
votes
3answers
2k views

multicols not wrapping to 2nd column properly?

This question led to a new feature in a package: multicol I am having problem with multicol package, I created a sample demo to show it. When I put 3 minipages of certain height in the ...
5
votes
2answers
132 views

Three 'side to side' figures using minipage

I'm trying to set up a main figure containing three sub figures. The idea is to split them in such way that it shows a two columns figure where the second column is made out of two sub figures located ...
8
votes
2answers
2k views

How do I make one minipage the same size as another?

I'm writing a LaTeX document into which I want to put two boxes, in a row next to each other, which will contain varying length content. I want each box to be the same height, and that height needs ...
8
votes
2answers
3k views

Fitting and centering text (both!) in a constrained area

Is there a way to make text size and alignment automatically "best fit" on a page? So that a large amount of text will be constrained on the page in a small font, but a small amount of text can be of ...
6
votes
1answer
10k views

! LaTeX Error: Not in outer par mode

I am using an image within minipage and getting error message. ! LaTeX Error: Not in outer par mode. Below is minimal working example. \documentclass[11pt,table,a4paper]{article} ...
6
votes
3answers
1k views

Resuming a list started within a minipage

I have a minipage with a figure, and I want part (a) to be on the right of this figure (so part (a) is in a 2nd minipage), and the remaining parts (b), (c), etc to be below. The insights provided in ...
4
votes
1answer
400 views

Line numbering with Lineno within Minipage

I am trying to add line numbers to a reading passage. The issue is that I can't get them to display when I try to number lines within a minipage environment. Can anyone answer what seems to be a ...
4
votes
1answer
181 views

Minipages in macros for ConTeXt

In LaTex I build the following macro "kum" for translating arabic to german. The result are two minipages, left one with german, right one with arabic (the other two minipages were for design-issues). ...
3
votes
1answer
171 views

vertical spacing on enumitem

In the example below I want the enumerate list to essentially be ``inline'' with the word Example from the example environment. It works perfectly with text or enumerate* (inline list), but I cannot ...
1
vote
1answer
267 views

minted Environment Inside minipage Environment

I am having to use the minted environment inside a minipage environment quite often in my document. I wanted to write a new environment for doing this, but since minted isn't designed to be included ...
1
vote
2answers
995 views

How to change the position of the caption in a “narrow” and “minipage” environment?

I have some huge figures to include in Latex. Therefore I use the "minipage" and "narrow" environment to place it right at the desired position and to move it to the left until it looks centered. ...
11
votes
1answer
11k views

Align minipage to baseline of first or last line inside minipage?

The minipage environment has options for making the top, bottom, or center of the minipage box line up with the baseline of the surrounding text. Is there a way to make it line up to the baseline of ...
12
votes
1answer
1k views

Wrapfigure-Minipage Woes: How do I correctly typeset wrapped text boxes within a \parcolumns environment modified for a two-sided document?

This is a follow-up question concerning an experimental chapter layout I'm trying to implement for a novel I'm writing. So. My initial problem of finding a way to modify the innards of the parcolumns ...
9
votes
1answer
11k views

tables side-by-side using minipage

I'm trying to get three tables side by side using minipage. In spite of my horrific efforts my tables keep stacking on top of each other instead of standing beside what drives me mad. Can anybody spot ...
8
votes
4answers
3k views

Background image for minipage

I'd like to put a background image into a minipage, stretching exactly to the surrounding fbox. What's the best option to do that? (Searching the web, I only found solutions for backgrounding the ...
7
votes
2answers
5k views

\footnotemark and \footnotetext in minipage

The Tufte handout class give a neat layout that shows the footnote at the right hand side not bottom line. But, when I use the minipage with tufte-handout, and if the minipage has the footnote, the ...
2
votes
1answer
558 views

What width value corresponds to the Tufte fullwidth environment?

In Tufte-LaTeX, I'd like to manually create a full-width environment using minipage rather than the package's fullwidth environment. What width value should I supply to minipage to match that of the ...
8
votes
2answers
4k views

Minipage that allows page breaks?

Is there a minipage-like environment that allows pagebreaks? Everything I can find is about avoiding page breaks (which minipage does well) but I want to indent a whole section, which is convenient to ...