{horizontal-alignment} is about aligning document elements horizontally, e.g. typesetting paragraphs using \centering or \raggedright or adjusting the horizontal position of several equation or table components. If your question is generally about (horizontal) white space, use {spacing} instead.

learn more… | top users | synonyms (6)

1
vote
1answer
905 views

Split node padding when using `align` in TikZ

Consider the following code: \documentclass{article} \usepackage{tikz} \usetikzlibrary{shapes,positioning,fit} \begin{document} \begin{tikzpicture} \node[draw, rectangle split, rectangle split ...
2
votes
2answers
938 views

Table of contents: section number and title overlapping

I have problem with creation of table contents. A part of my code: \documentclass[a4paper]{amsbook} \usepackage[cp1250]{inputenc} \usepackage{polski} \makeatletter ...
10
votes
1answer
3k views

Change alignment for individual table rows

Is it possible to change alignment for individual rows? Example: +------------+--------------+--------------+ | Left | Center | Right | +------------+--------------+--------------+ ...
4
votes
2answers
432 views

Tabstop-like alignment of text possible?

I'd like to format some text around a tabstop such that what is left from the tabstop is \flushright and the text that is right from the line is \flushright. The Tabstop is at a specific position, ...
11
votes
5answers
6k views

Align Note below table

My question concerns the "Note" below the table. This is my code: \begin{table} \begin{center} \caption{ Descriptive statistics of total sample based on modified data set}\label{table:descrtotal} ...
15
votes
4answers
843 views

How can I make (La)TeX prefer to fill centered lines

My thesis formatting requirements ask for multiline chapter and section titles to be a maximum of 4.5 inches wide with any subsequent lines being wrapped such that they are sucessively shorter, ...
2
votes
2answers
3k views

Vertical alignment with subfig and pstricks

I'm working with pstricks to add illustrations to a paper, as I found that it allows me to save much time compared to editing files with dia/xfig/visio/etc. and including pngs. But I'm having a few ...
4
votes
2answers
165 views

Align unrelated arrays

How can I align arrays like the ones below so that they start at the same distance from the left edge of the paper? \documentclass[a4paper,11pt]{article} \usepackage[utf8]{inputenc} \begin{document} ...
5
votes
1answer
1k views

Displaying two XML listings side by side.

I have two XML outputs from a program that I would like to include in a LaTeX document. I would like them to appear side-by-side each in its own box. So that a reader can compare the two outputs while ...
3
votes
1answer
434 views

I had a problem with spacing of tabular columns combined with \multicolumn. I found an inelegant solution. Perhaps someone knows of a better one?

Consider a table with several columns. Three consecutive columns are thin. These three thin columns have a long \multicolumn{c}{3}{??} heading over them. If nothing is done to specify how these should ...
3
votes
1answer
1k views

nomencl: left alignment for description text

Does anyone know how to left align the description text of abbrevations in a nomencl list of abbrevations. For example: I would like to left align the text "Kategorien- und Variablebezeichnungen" or ...
3
votes
1answer
193 views

Please help me to run this code in LateX!

\documentclass{article} \usepackage{array} \begin{document} \begin{tabular}{| >{\centering}p{2.5cm} | >{\centering}p{0.5cm} | >{\centering}p{2.5cm} |>{\centering}p{2.5cm} ...
3
votes
2answers
308 views

Figure with long list of predicates and conjunctions (\wedge)

I have a figure with a long list of predicates connected with \wedge, here is the code: \begin{figure}[h] \small{ $ Defined\_in(subject\_state, concrete\_subject) ...
1
vote
2answers
175 views

How to align some lines under tabular?

I am using tabular, and I would like to realize something like that: word1 word2 word3 word4 longerword5 word6 word7 word8 So word1,2,3,4,6,7,8 are well aligned, and I do not ...
5
votes
1answer
496 views

CurVe document class: alignment issue with subrubrics

I have the following issue with the alignment of subrubric titles in a résumé written with the CurVe class by Didier Verna. When the rubric & subrubric titles are aligned left via options in the ...
2
votes
1answer
333 views

How do I make the text in the following figure white and center the figure?

How do I make the text in the following figure white and center the figure? %% LyX 1.6.9 created this file. For more info, see http://www.lyx.org/. %% Do not edit unless you really know what you ...
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}
3
votes
1answer
584 views

How to make pgfplots to center a text in a xticklabel

In pgfplots I've used the text width option in the definition of xticklabel style and I wonder how to center the labels text?
2
votes
1answer
864 views

Format caption in figure

I have a question which concerns text formatting in captions and also in sections. For example when I type: \begin{figure} something \caption{this is some caption text and it probably may be quite ...
3
votes
1answer
104 views

alignment of symbols

I tried to align the equation and have some text on the equal sign. But it turns out that the equal sign that has text over it is no longer aligned to previous one anymore (I believe it is the text ...
9
votes
1answer
1k views

How to have a figure touch the edge of the page?

How can I position a figure (picture) so that it: is aligned on the left-hand side with the text (this is in two column page) touches (or exceeds) the right-hand side of the page? An example can ...
4
votes
1answer
1k views

Centering a gnuplot figure properly

I use gnuplot and its epslatex terminal. When I include a gnuplot-generated figure in my document and center it as usual, it often appears shifted right — because the labels on the left contribute to ...
3
votes
1answer
150 views

Wrong display when I have more than 9 chapters in ToC

I'm in a really bad situation with my ToC in the book that I write. Everything is fine until the 9th chapter. There's the "9", some space and then the name of the chapter. But on the 10th (or more) ...
1
vote
2answers
1k views

Centering an image and a two-column layout.

Here's what I'd like to do. Place a centered image, and then have two columns of text centered below it. I did the following: \begin{center} \includegraphics{image} \begin{multicols}{2} lots of text ...
1
vote
3answers
2k views

Center-align text in columns in tabular environment in multicol environment

I need the text in the second two columns to be center-aligned. I also need someone to please help me clean up this table. It looks ugly. Notice it is inside a multicolumn (2-column) environment, ...
2
votes
2answers
629 views

bibtex large spacing

I couldn't find a solution to my problem searching. Apologies if it has been asked before. My problem is: on a few of my bibliography entries, there are massive spaces in the text to pad out the ...
6
votes
2answers
1k views

Line break in the table item

I am creating table in LaTeX and I need to get the text to perform line break automaticaly when it's too long. And if possible, I'd like to get the text alignment to the left. Is it possible to handle ...
8
votes
1answer
749 views

Align siunitx numbers in a tabu table

The minimal example below gives me a strange offset in numbers with exponential numbers. I think tabu and siunitx are getting in each others way. Is anyone aware of a workaround? ...
8
votes
2answers
1k views

ragged2e: “newcommands” option produces “underfull \hbox” warnings

The ragged2e package provides the commands \Centering, \RaggedRight and \RaggedLeft for setting ragged text while allowing hyphenation. The package offers a newcommands option that sets the standard ...
2
votes
5answers
528 views

inline bracket, similar to a permutation and binomial, but aligned

I'm often experiencing instances, when I need to define a function on two sets in a domain. I'd like to create a command \newcommand{\func}[4]{...}, which makes an inline bracket, that shows how the ...
2
votes
1answer
1k views

Aligning bmatrix-matrices next to each other?

I have this code: \[ \begin{bmatrix} Pagerank&Sidnummer\\ 0.068945&2\\ 0.068945&3\\ 0.076517&1\\ 0.076517&4\\ 0.11536&7\\ 0.11536&8\\ ...
2
votes
1answer
823 views

Table Cell Alignment - Last Column 'Misbehaving' - Simultaneous Vertical and Horizontal Alignment Problems

I am going a little crazy with alignment in the tabular environment. In the following code I would like both the top-left cell 'Green Die', and the last cell in the 2nd row '6' to be aligned ...
7
votes
2answers
2k views

Centering a TikZ picture around an area

I often find myself in the following situation: A tikzpicture of mine consists of a main area and some outer material like text labels which are hardly symmetric around the main area. If such a ...
14
votes
3answers
978 views

Is there a way to measure the remaining space of a line of text?

I'd like to write the following: Some long paragraph of text \measureremainder{\whatsleft}\begin{mimipage}{\whatsleft} stuff \end{minipage} so that the minipage takes up exactly the remaining ...
2
votes
1answer
236 views

How can I build a box with multiple lines of content with two anchors?

I'm trying to create a macro \AST (or an environment, if that helps) that will let me typeset abstract syntax trees, in the following way: \AST{A}{\AST{B}{C\comma D}\comma E\comma \AST{F}{G}} should ...
2
votes
3answers
262 views

How to align some lines under {align*}

I usually use \begin{align*} and \end{align*} to align some texts. Here is a special case I would like to realize: abcdefghijklmn hijklmn opqrstuvwxyz hijklmn There are 2 rules: 1) I want to ...
2
votes
1answer
435 views

right-aligned table from csv

I have a csv file formatted like this one: "","head 1","head 2","head 3" "count 1","23","24","25" "percentage 1","23%","24%","25%" "count 2","53","54","55" "percentage 2","53%","54%","55%" I'm ...
5
votes
2answers
4k views

Left-alignment like Fleqn-option only for specific equations

I want to left-align some equations. (Note: I want to align the equations themselves, not code inside of the equations.) I have the following example code: \documentclass{scrartcl} ...
3
votes
4answers
1k views

How do I align a pgfplots graph?

I'm trying to draw a graph with the associated table of data using pgfplots. It works great, but the graph itself isn't aligned with the table. This is what it looks like: I don't like the ...
1
vote
2answers
943 views

Right Align Equation Number with hfill in Custom Environment

I have a couple of custom environments that I want to be able to use \hfill to right align the last column (similar to what {align} environment does with equation labels}. I attempted to use \hfill ...
1
vote
2answers
991 views

LaTeX table: line thickness varying and incorrect horizontal alignment

This LaTeX source ( http://pastebin.com/3HdpbQi5 ) yields two types of errors ( http://i.stack.imgur.com/4J87t.png ): The line thickness of the table borders in the primary header row varies and the ...
48
votes
3answers
13k views

Center figure that is wider than \textwidth

I have a figure that is wider than the \textwidth of my document. (I don't want to change the \textwidth.) As a result, the leftmost part of the figure is flush with the left margin, while the ...
18
votes
3answers
1k views

LaTeX word wrapping poorly

LaTeX is not word wrapping this anything close to sanely: \documentclass{article} \usepackage{graphicx} \usepackage{wrapfig} \usepackage{geometry} \usepackage{lipsum} \geometry{margin=1in} ...
2
votes
1answer
769 views

Aligning multiple tables

I have several tables I'd like to align, but it comes out messed up. I'm using revtex4 for my general layout (two column), and I have this: \begin{tabular}{|c||@{\hspace{12pt}} c ...
13
votes
2answers
9k views

\hfill after linebreak

I have a simple text. Right after the end of the text I use \hfill to get some words right aligned. \documentclass[11pt]{article} \begin{document} Lorem ipsum dolor sit amet, consetetur ...
5
votes
1answer
326 views

Test if text fits on one line

I have a boxed text that is justified, but I would like to make it centered if it takes only one line. Currently, once the text is rendered, I add a \filcenter as an option to my box macro, but I'm ...
1
vote
1answer
1k views

Figure caption indent problem

The last lines of my figure captions are indented too much or centered. I use floatrow package which usually doesn't conflict with LaTeX. Is it possible to fix this? My preambles are as follows: ...
3
votes
1answer
279 views

Problem with babel, ragged2e and parbox

I have the following code: \documentclass{minimal} \usepackage[french]{babel} \usepackage[newcommands]{ragged2e} \begin{document} \begin{center} \parbox{9cm}{ \textsc{ Jesus a dit~: \og ...
11
votes
2answers
7k views

How to force to center the table captions?

i want to center the table captions.
6
votes
2answers
822 views

Underfull hbox with \hbox to <dimen> but not with \halign

When using the \halign primitive, cells in the same column all have the same width. Hence, if one entry is very large (abcdefg below), the others will be stretched to the same size. If an entry ...