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

learn more… | top users | synonyms

31
votes
2answers
2k 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 ...
17
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
261 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 ...
18
votes
2answers
11k 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} ...
24
votes
3answers
8k 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 ...
11
votes
2answers
795 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, ...
16
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 ...
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 ...
4
votes
2answers
192 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 ...
21
votes
2answers
43k 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 ...
16
votes
1answer
820 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, ...
4
votes
2answers
531 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 ...
36
votes
3answers
15k 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 ...
9
votes
1answer
4k 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} ...
9
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
1answer
1k 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 ...
14
votes
1answer
4k views

Can I get a normal footnote in a minipage environement 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 ...
12
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 ...
3
votes
3answers
546 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 ...
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 ...
4
votes
1answer
397 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 ...
1
vote
1answer
228 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 ...
2
votes
1answer
7k 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 ...
15
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 ...
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 ...
7
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 ...
4
votes
1answer
308 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
140 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
150 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
213 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
690 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
9k 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
13k 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 ...
12
votes
1answer
989 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 ...
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 ...
12
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 ...
9
votes
1answer
9k 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 ...
7
votes
2answers
4k 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 ...
4
votes
1answer
2k 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? ...
6
votes
2answers
12k views

How to center the minipage?

The left margin is too wide if I set 1.5\textwidth: \begin{document} \noindent\begin{minipage}{1.5\textwidth} test \end{minipage} \end{document}
6
votes
1answer
3k views

Vertical alignment of tikzpicture with text?

I have some text, and a corresponding tikzpicture, both of which are to be part of a test question, and which are thus included as part of an \item in an enumerate environment. Like this: \item ...
5
votes
1answer
1k views

Minipage - space between two columns and aligning

Here is the deal. I want both of them starting from the very same line and perhaps increase the distance between them. I really cannot remember wheater s.th. chaged after adding ...
2
votes
1answer
470 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 ...
14
votes
2answers
21k views

How to split a frame (of beamer) into 2 parts (minipage) side by side?

I would like to split a frame into 2 parts side by side by minipage. But it seems that the following code puts one on top of the other: \begin{minipage}[t]{0.48\linewidth} left part ...
11
votes
2answers
292 views

How do I put card backs on my cards?

I have a a document that is making me sheets of cards. A stripped down, almost minimal example looks something like \documentclass{article} \usepackage[utf8]{inputenc} %Needed for input ...
8
votes
1answer
888 views

How to produce 5-up 3by5 index cards

I want to produce instructional 3by5 index cards. It's easy enough to produce the cards one per page, but I want to print five copies of the same car on a single sheet of 8.5by11 card stock, where it ...
6
votes
1answer
248 views

Dotted column sep in multicolomn minipage

I'm trying to typeset a table whose cells are divided into columns, and the columns are separated by dotted lines. This is for variable-length enumerations of (short) entries and planned to look ...