{vertical-alignment} is about aligning document elements vertically, e.g. using \raggedbottom or \flushbottom or adjusting the vertical position of several equation or table components. If your question is generally about (vertical) white space, use {spacing} instead.

learn more… | top users | synonyms (2)

13
votes
1answer
2k views

Why does \vspace*{0pt} add vertical space?

I'm trying to format the title of the table of contents using the tocloft package. It inserts code that looks like the following. \par \vspace*{\cftbeforetoctitleskip}% % code to typeset ...
13
votes
1answer
1k views

Align marginpar with beginning of paragraph

Is there a way to align a marginpar with the beginning of a paragraph, without cluttering the text of the paragraph? If I do the following, the marginpar lines up with the last line of the first ...
12
votes
5answers
4k views

Vertical alignment of align* in enumerate

Related (but not the same): Align number from enumerate with equation Displaying an equation in a list Earlier today I asked a question about aligning equations in an enumerate environment ...
12
votes
4answers
20k views

Reduce space between enumerated items

Background A book with lots of images. All of the images are set to "here definitely" (as they must come after the text that introduces them). Problem The list types (enumerated and bullet) have ...
12
votes
3answers
5k views

Make two figures aligned at top

I am inserting two graphs (of different size) in the following way: \begin{figure}[H] \begin{center} \includegraphics[scale=0.5]{graph1.eps} \includegraphics[scale=0.3]{graph2.eps} ...
12
votes
2answers
474 views

Inconsistent behavior of boxes in amsmath's `gather`.

Recently I was working on a package (ytableau) and had a strange experience with the gather environment in amsmath. Namely, it screws with \vtop and, seemingly, with boxes that I reserve before ...
12
votes
2answers
3k views

How to make an exact vertically centered object in a page?

Note: the red lines have the same length. \documentclass{minimal} \usepackage[showframe,paperwidth=4cm,paperheight=4cm,margin=1cm]{geometry} \begin{document} % \vspace*{\fill}% \fbox{test}% ...
12
votes
4answers
940 views

Vertical double asterisk that aligns well with the double dagger

The LaTeX text footnote symbol sequence begins with ∗ † ‡ § ¶ ∥. I'd like to define a vertical double asterisk ⁑ (\textastdbl) so that I can insert it into the sequence: * ⁑ † ‡ § ¶ ∥ (note: actual ...
12
votes
3answers
4k views

Vertically align subfloats at the top while having subcaptions vertically aligned below the subfloats

I have a float with two subfloats: I want the circles to be vertically aligned from their top such as in the following figure. But I don't want the subcaptions to be placed above the subfloats but ...
12
votes
2answers
1k views

\addvspace can't replace \vspace

I want to replace \vspace with \addvspace in a command. When so doing, I get obtuse "something's wrong--perhaps a missing \item." errors. I'd appreciate an explanation of why this happens and how ...
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 ...
12
votes
1answer
66 views

Tight connection of \vbox es

I don't understand why TeX put a thin whitespace between my two vertical boxes: \documentclass{article} \begin{document} \vbox to 1cm {\rule{1cm}{1cm}} \vbox to 1cm {\rule{1cm}{1cm}} ...
12
votes
1answer
1k views

How can I set the vertical margin of my chapter headings?

I currently don't like the typesetting of a document. In my two sided document, I want that the chapter headings not have a vertical space before their appearance. The text on the second page should ...
11
votes
5answers
4k views

How to make a tikz node, top-aligned with the rest of the text?

If I write before-text \begin{minipage}[t]{5cm} line1\\line2\\line3\\ \end{minipage} after-text I get a box, whose top is aligned to the top of "before text". I would like to have the same, when ...
11
votes
4answers
1k views

How to vertically center a content spanning multiple rows without using nested tables?

I don't want to use nested tables. My current code produces the following result. And I want to get the following output. And the minimal working example: \documentclass{article} ...
11
votes
4answers
3k views

Spread bullet points across block in slide using beamer

I'm using beamer to create some slides for a presentation. I've got a block containing a bulleted list. The list only has three items, and all three items are bunched up in a small block at the top of ...
11
votes
2answers
6k views

\flushbottom vs \raggedbottom

I use \documentclass{book}. If I use \flushbottom, I get messages of the sort Underfull \vbox (badness 10000) has occurred while \output is active []. See question. These messages disappear when I ...
11
votes
4answers
2k views

Aligning an enumeration item to the top of a tikzpicture

I've drawn a tree using pgf/tikz and am trying to place it in an enumerated list. A snippet of my complete code is as follows: \subsection*{Problem 2} \begin{enumerate}[1)] \item Max heap \item ...
11
votes
1answer
280 views

Consistent cover design regardless of inner pages

This is a series of books, the margins, page sizes are all identical. Depends on the content, the design of inner pages are slightly different, i.e. different type sizes, leading, etc. The question ...
11
votes
2answers
387 views

Center and yet align figures on opposite pages

This is an extension of the question "How to ensure that 2 couples of figures are on 2 facing pages?". I not only want to ensure that the figures are on facing pages but also that the one with the ...
11
votes
1answer
4k views

Adjusting vertical alignment of underbraces

Is there a way to align multiple underbraces so that they sit on the same horizontal line? For example, the following code \[ \biggl( \underbrace{0,1}_{A}, \underbrace{\frac{1}{2},\frac{1}{3}}_{B} ...
11
votes
1answer
195 views

Alignment rules

I find myself quite frequently in the need to check whether some elements on my page are aligned exactly as intended. As a result, I usually end up magnifying the output 400% and using a rule over my ...
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 ...
11
votes
1answer
370 views

Use of \@texttop and \@textbottom for vertical positioning

There are two macros defined in the LaTeX kernel named \@texttop and its opposite \@textbottom. The first is a bit of a mystery command in that in the source it is let to \relax. There is a note that ...
11
votes
3answers
12k views

Problem with Table Vertical Alignment

I want a table whose first column is aligned top, second column is aligned middle, and third column is aligned bottom; like this: I wrote the following code: \documentclass{article} ...
11
votes
1answer
7k views

How to center vertically content of the table?

I have this table: \usepackage{array} \newcolumntype{x}[1]{>{\centering\arraybackslash\hspace{0pt}}p{#1}} \begin{table}[ht]\footnotesize \centering \begin{tabular*}{0.95\textwidth ...
11
votes
3answers
3k views

How to vertically align headers/footers in fancyhdr package?

I'm using fancyhdrpackage for headings and footers. I have defined left-header as a big image, and I want to vertically align (to the top or to the center, the default is to the bottom) the text from ...
11
votes
1answer
396 views

Two-column layout with thick vertical rule in ConTeXt

Background I would like to add a thick rule centered between two columns. Example Code A minimum working example that illustrates the issue: \setupcolors[state=start] ...
11
votes
3answers
3k views

Line up captions on side by side figures

I want to place two (or more) figures with side by side. The figures are independent, so need separate captions, with no overall caption for the two. I know how to do this with minipages within a ...
10
votes
3answers
205 views

Aligning cases conditions from multiple nesting levels

\begin{dmath*} y_{ic}[n] = \begin{dcases} y_0 + x_0 - x_0 (1 - k_2)^n & k_1 = 0 \\ k_5 + \left( y_0 - k_5 \right) (1 - k_1)^n + \begin{dcases} ...
10
votes
3answers
197 views

Move tabular entry to bottom of row

How do I get the last column text to be at the bottom of the row? That is I want the XXX to be aligned with the line containing the arrow. I tried playing around with \multirow{3}{-3ex}{XXX}, but ...
10
votes
2answers
219 views

\pagebreak[number] only breaks with number = 4

I wanted to try out encouraging of pagebreak using \pagebreak[number]. As far for now it only breaks the page when I define \pagebreak[4] and only then (it won't work on any other circumstances). ...
10
votes
4answers
158 views

Vertical alignment of degree unit and other elements in table

I am trying to improve the appearance of the below table such that: The set union symbols \cup align vertically with the commas from the 2nd and last rows The middle column angle values are still ...
10
votes
2answers
1k views

Uneven text distribution with two-column layout

I am comfortable with creating basic LaTeX documents and making minor modifications to templates I can find online, but not much more. The Oxford Bioinformatics journal has an awesome template here ...
10
votes
3answers
137 views

How to correctly pad and align a displaystyle inline equation in a table

I've got the following code in a document and am at a loss trying to figure out how I can correctly pad the cells and/or align the equations correctly. \begin{table}[h] ...
10
votes
3answers
145 views

How to align the conditions in a hierarchical structure?

I know how to align the conditions on the left side of the conditions with either aligned, cases, or array if there is only one level. However, I can't figure out how to do so in a hierarchical ...
10
votes
1answer
788 views

Equations inside enumerate aligned on item's number

If I type \begin{enumerate} \item \begin{align*} eqn 1 eqn 2 \end{align*} \end{enumerate} the label will appear on the first lines and the equations will ...
10
votes
1answer
5k views

p,m and b columns in tables

I wonder why p columns are aligned at the bottom and b columns aligned at the top? created with this code: \begin{tabular}{|p{0.3\linewidth}|m{0.3\linewidth}|b{0.3\linewidth}|} \hline \centering ...
10
votes
2answers
1k views

How to put table and PNG next to each other in the same figure?

How can I put a table and a PNG (using \includegraphics) next to each other in the same figure, in the following way? +----+ +-----+ |png | |table| |png | |table| |png | ...
10
votes
1answer
324 views

How to vertically align underbraces

I am trying to balance underbraces in the equation below, how can I ensure that both underbraces at the same depth? \begin{equation} y = \underbrace{ \left [ x^2 + r^2 (a^2+\frac{a^{0.3}}{b}) ...
10
votes
2answers
446 views

Position margin notes relative to left margin in plain TeX

I want to add margin notes in the Tufte style to my Plain TeX document. (I'm using eplain, if that matters.) I know that if I were using LaTeX I could just use tufte-latex, but as a thorough ...
10
votes
2answers
303 views

Why is picture and matrix not drawn at the same height

I'm trying to put a adjacency matrix beneath a graph using subfloat. The graph is drawn with tikz. No matter what I do, the matrix is put below the graph as shown here: The code is here: ...
10
votes
4answers
182 views

A line of text with proper positioning but consuming no space?

Welcome to part 4 in a series of questions about me trying to improve my crazy layout! I'm using tabu to create a table with a central heading, and two small blocks of text on the left and right ...
10
votes
2answers
4k views

How can I vertically align a beamercolorbox?

I am trying to customize a beamer theme. In the footline, information such as author, title, date ... are in several beamercolorboxes. \hbox{% ...
10
votes
2answers
8k views

tikzpicture alignment and centering

I have several very similar images except some have some extra graphics that enlarge them slightly. This causes some pictures to be offset and not aligned visually when it's clear they should be. How ...
10
votes
2answers
327 views

Sideways text with rule as table label

I've been trying to achieve the following vertical sidebar effect in LaTeX for my resume, but turns out it's far more difficult than I thought (created easily in InDesign): I've tried everything ...
10
votes
1answer
157 views

How I can align a table with a figure from above?

I want to have a table and a figure plotted by \pgfplot in two column but have alignment from above: \documentclass[a4paper,10pt]{article} \usepackage[utf8x]{inputenc} ...
10
votes
2answers
345 views

equation, equation number and itemize bullet all on the same line

I think the following sample says it all. I need to get the item bullet in the right place on the same line as the equation, and have this followed by an normal equation number. Someone asked the ...
10
votes
2answers
620 views

Horizontal alignment within an equation using Tikz

I am trying to center horizontally the first terms of a system of equations inside the alignat environment. I don't know if Tikz is the right way to go, but as I might have to add some other ...
10
votes
1answer
1k views

How to align picture top left in a table?

is there a way to create a table with 2 columns, in the left column should be some text, in the right column should be a picture. The problem is - to align both to the left, top corner. The image ...