{floats} is about the floating environments figure, table and other, custom-defined floats, and concerns issues such as positioning, labelling, captioning, indexing and listing of said floats. For questions specifically about formatting a float caption, consider using {captions}.

learn more… | top users | synonyms (2)

4
votes
2answers
1k views

Hypcap not working with custom figure environment

I'm trying to use caption with hypcap=true so that cross-reference hyperlinks will go to the figure instead of the figure caption. However, I'm using a multicol environment with a custom figure ...
4
votes
1answer
181 views

Getting floating objects in multicol environments

I am using multicol with 2 columns, and I would love to have my figures and tables to float, so that I don't have to manually mess around with the positioning anymore. I am aware of figure*, but I ...
4
votes
1answer
1k views

Undefined reference: autoref points to section instead of figure or table

Here is a minimum working example (an image 'test.png' needs to be in the working directory. I used this one.) % Created 2011-05-23 Mon 15:21 \documentclass[11pt]{article} \usepackage{graphicx} ...
4
votes
2answers
863 views

How to make equations, figures and theorems use the same numbering scheme

It was asked a while ago how to make equation use the same counter as a theorem for example and one solution was to make the theorem counter use the equation instead by using ...
4
votes
1answer
405 views

Want figure height to ignore side caption height

I use beside captions placed in a large margin area. Sometimes, the caption text is taller than the figure and this causes too much vertical space around the figure. I'd like the effective height of ...
3
votes
2answers
1k views

Why do eps images overlap the captions in subfigures?

I'm using the package subcaption within an scrreprt compiling with XeTeX/XeLaTeX. When using subfigures for 4 images in a grid view, the images are not centered and overlap the middle subcaptions. It ...
3
votes
1answer
2k views

Adding figure in framed or shaded environment

I am currently using the shaded environment from the framed package for large calculation digressions in my papers. \usepackage{framed} \newenvironment{digression}[1]{\begin{shaded} ...
3
votes
2answers
502 views

Tables as PDF images

Due to time constraints I'm considering cheating a little and importing some tables I've created in Excel into my latex document. I realise I can do this quite nicely as a 'figure' using something ...
3
votes
1answer
205 views

Figure refs stop working after I added a new counter

I was using the amspset document class for generating exam practice problems. I had wanted to add some referencing to the problems so I started a new counter like this (adapted from some Tex Exchange ...
3
votes
2answers
1k views

Make tikz picture floating

I'm inserting a tikz picture in my section headings with \titleformat (see this question) and I would like it to not affect the spaces in the headings. Right now, what I do is that I compensate the ...
3
votes
2answers
1k views

Table, Figure, and Listing prefixes

Background Using LyX and KOMA Script to author a technical manual. Problem The documents are strewn with the following references: \ref{fig:Example-Database-Type} When converted to PDF, this ...
2
votes
1answer
117 views

How to allow page break inside a float environment?

I'm using new float enviroment to show some examples in my document. This enviroment contains tcolorbox which provides a gray background. The main text in the enviroment is a mixture of plain text ...
2
votes
1answer
187 views

Automatically set the figure width depending on whether the layout is one or two column

I am wondering how do you usually deal with figure width when you are writing a paper. (use \linewidth, \textwidth ? others?) Maybe we can just define a "switch" and use it with ifelse package? ...
2
votes
0answers
136 views

Is there an alternative for \usepackage[nobottomtitles*]{titlesec}?

Is there an alternative for \usepackage[nobottomtitles*]{titlesec} as it messes up my automatic clearing of floatingfingure? \documentclass{article} \usepackage{mwe} \makeatletter ...
2
votes
1answer
1k views

Put figure text under images?

In LyX, how can I set a float that contain figure so that the caption is under the figure? By default the caption is always on the left side of figure.
2
votes
1answer
241 views

How to prevent figures from floating 'into' listings [closed]

I have a problem with floats and listings. Sometimes it happens that a listing is split over two pages and when a figure is near the listing it happens that the listing starts on the first page, on ...
2
votes
1answer
9k views

Table in LaTeX appearing in middle of next page

I've inserted a table in my LaTeX document and have used \center to horizontally align it to the centre of the page. However, it's appearing a page after where it should, is both horizontally and ...
1
vote
0answers
89 views

Single column figure leaves a blank in the other column?

I am writing in a double-column template (IEEE Conference Template). What has been bothering me is that once I have a figure/pseudocode/tikz in one column, sometimes it pushes the contents in the ...
1
vote
1answer
8k views

How to remove space after image caption? [duplicate]

I am writing one article in which i need to write one image and its caption. I found space after caption seems to be more than normal. \begin{figure}[!ht] \centering ...
1
vote
1answer
3k views

Subfigures placed horizontally

I want to place two or more figures on top of the two-column page next to each other (horizontally). However, for some reason I can't do this. This is the code that I use, it puts the second figure in ...
0
votes
1answer
51 views

wrapfig how to designate where the figure should come and of what size exactly

This is a general question. I find that the wrapfigure environment is very tricky. It depends on where you put it and if you add things to the top part you can make a good wrapfig bad. I would like ...
41
votes
1answer
49k views

Why is \newpage ignored sometimes ?

I have the following towards the end of an article. The bibliography is short (4 entries). What's happening is that on the very last page of document I get the chart and immediately afterwards the ...
19
votes
2answers
497 views

How to reference the page of a figure?

Is it possible to make a reference to the page where a figure is rendered? I would like to write something like see figure~\ref{figure-xyz} on page NN where NN will automatically be maintained by ...
15
votes
2answers
27k views

Image from \includegraphics showing up in wrong location?

I have the following situation: \subsection{Some subsection} Some text here... \\ \begin{figure} \caption{Raw} \includegraphics[scale=0.25]{raw.png} \end{figure} \begin{figure} ...
14
votes
3answers
6k views

How to include verbatim in a figure caption?

I would like to include verbatim in a caption of a figure. I only want part of it to be verbatim, not the entire caption. The simple approach does not work because verbatim is not allowed in arguments ...
21
votes
3answers
19k views

making a table fit on a page by moving it left

I have a table where the last columns fall off the page. Instead of making the text smaller I would like the table to not adhere to the margin of where it begins. I would like to move it to the left. ...
15
votes
3answers
13k views

How to rotate landscape table page in PDF?

Currently I am using \usepackage{rotating} \begin{sidewaystable} \begin{tabular}...\end{tabular} \end{sidewaystable} to typeset landscape tables, which works great. But I want to rotate that page ...
32
votes
4answers
55k views

Force LaTeX image to appear in the section in which it's declared [duplicate]

Possible Duplicates: How do I ensure that figures appear in the section they're associated with? Keeping tables/figures close to where they are mentioned How can I force an image in a ...
18
votes
2answers
2k views

Find optimal figure size to fit two images on one page

I often encounter a situation where I would like to fit two or three figures on one page. I define my figures as follows: \begin{figure}[htpb] \centering ...
18
votes
3answers
1k views

Photograph credits in LaTeX

Is there any convenient package/way to link photograph credits with a figure, and then generate a kind of \listoffigures? Have you any other solution than generating the .lof temporary file, and ...
14
votes
4answers
542 views

How to 3D rotate figures in display

I have a bunch of 2D figures which I like to use latex to display them in a row (side by side). Since the number of the figures is a lot I cannot show them all horizontally. For this I would like to ...
14
votes
2answers
2k views

How to put a PDF figure on top of another one

I have two PDF figures (charts) in a LaTeX document. As one of them is really simple, and I have some document space constraints, I was thinking of putting it in the upper right corner of the second ...
12
votes
1answer
9k views

How to float figure within multicol text

I have a simple two-column text, and want to place figures within the text. I used this code \documentclass{article} \usepackage{multicol} \usepackage{graphicx} \usepackage{caption} \begin{document} ...
9
votes
2answers
390 views

Table/Figure Layout

I'm interested in good practice for table (tabular) and figure layout, especially in good references. What do typographers have to say about this. Please provide references if you can. To focus the ...
9
votes
3answers
1k views

Tables do not align side by side

. . \usepackage{tabularx} \usepackage{multicol} \begin{table}[ht] \begin{minipage}[b]{0.5\linewidth}%\centering \begin{tabular}{|c|c|c|c|} \hline & One & Twp & Three \\ ...
8
votes
2answers
296 views

How to make a wrapper for the figure and table environments.

I am familiar with the newenvironment command, but I was wondering, how do I carry on the parameters that are used between [ ], i.e [bht!]? I want to make a newfig and a newtab environment that will ...
15
votes
2answers
220 views

Is there a way to determine if there is a float on a page?

I am busy developing some code to draw layouts. Part of the code overlays the layout as shown in the images below: The black arrows to the side of the images, denote the \topfraction and ...
12
votes
2answers
868 views

Gray box around figure with a separate gray box around caption

My university requires that all figures in a thesis follow this pattern: I'm very new to LaTeX, so far my best attempt has been this: \begin{SCfigure} \colorbox{darkgray}{ ...
12
votes
1answer
6k views

Table captions are always placed below

I have a problem with table captions in LaTeX. They appear always below the tables instead of above as required by my editor. I've read lots of documentation and everybody says that if you place the ...
11
votes
3answers
4k views

Avoid page breaks in \lstlistings

I'm trying to avoid page breaks in my lstlisting (seen in section 0.0.2) I know I can remedy this by floating my lstlisting, but it adds some unwanted white space (seen in section 0.0.1). Is ...
9
votes
2answers
10k views

Figures: What is the difference between using subfig or subfigure [duplicate]

I tend to use \subfloats[]{} in my figures when I want to list multiple labelled figures of similar content in one bigger picture. However, I see that some people use \subfigure. What is the ...
9
votes
2answers
22k views

Insert multiple figures in Latex

I need to insert 10 figures (in two columns- side by side) in LaTeX that will have one global caption, but also I need to name each figure (1a, 1b, 1c, ... ect.). So they will look like: 1a ...
9
votes
2answers
5k views

Vertical centering of figure in landscape environment

I am using the pdflscape package to insert landscape pages in my document. On one of these I would like to have a figure that is vertically centered on the page, but I can't find how to do it. MWE: ...
8
votes
2answers
5k views

Why is my table displayed at the top of the page?

I figure this must be a common issue but I could not find a solution. Here is my code: \documentclass{article} \begin{document} Text: This text should be above the table, but it is not. ...
7
votes
2answers
6k views

Table numbering mismatch in caption and in text

I have created 2 tables in my LaTeX document \begin{table}[hb] \centering \begin{tabular}{|c|c|r|} \hline ... not important... \end{tabular} \label{tab:2} \caption{Določanje prioritet mojstrov ...
6
votes
1answer
316 views

Continue long table beside on the same page

I have a datatable in a CSV file and print it with pgfplotstable. I can split long datatables by making pgfplotstable use longtable instead of tabular environment; so far so good. My problem is that ...
6
votes
1answer
195 views

How to insert custom text in place of figure

I would like to replace some figures in a document with a black frame of the same size as the figure, such as that which you get when using \includegraphics in draft mode. However, this places the ...
5
votes
2answers
3k views

\footnotetext on different page from \footnotemark

I was forced to use \footnotetext and \footnotemark on because I needed a footnote in a couple of captions. Of the three times this is done in the article: one works fine, the second appears on the ...
4
votes
1answer
718 views

Figures on left pages, text on right pages

I'm writing a thesis in the book document class and I'm using a lot of figures to explain the working method. If I use the method proposed in Figures on left pages, text on right ones with class book, ...
4
votes
1answer
6k views

Referencing figures doesn't work [duplicate]

Possible Duplicate: Where to put the \label on a figure environment? I'm having a problem with referencing figures in LaTeX. I have the following text: \begin{figure}[H] \center ...