63
votes
Accepted
LuaLaTeX, TeXLive 2016, standalone: undefined control sequence
The fix is easy: add \RequirePackage{luatex85} as the very first line, a temporary workaround until standalone is updated. It should do no harm even after the update.
\RequirePackage{luatex85}
\...
Community wiki
44
votes
Accepted
What's the benefit of using {standalone} instead of {article}?
The main advantages, in my opinion, are:
You can readily compile your figure and make modifications without compiling the whole document.
You can include the standalone .tex file using the \...
29
votes
Accepted
Multiple pages with standalone
What I use is
\documentclass[multi=my,crop]{standalone}
After this, wrap every figure into \begin{my}…\end{my}.
26
votes
Accepted
Installing latex standalone in ubuntu for humans
The standalone latex package is included in the Ubuntu package texlive-latex-extra. You can install it through the terminal with the command:
sudo apt-get install texlive-latex-extra
or with any ...
25
votes
Accepted
The PNG image of a TikZ picture that is generated by the standalone document class has the wrong dimensions
Conceptually bitmaps do not have a size, they just have a number of pixels. As documented in the standalone manual the class tells convert to assume 300dpi which makes a high resolution image for ...
22
votes
Accepted
Standalone: class vs package
The standalone class is designed to create individual snippets of content whose size adapts to the content itself. This is implemented with the [crop=true] option, which is enabled by default. The [...
21
votes
Accepted
How does standalone crop?
Never read the documentation. Bad things happen. --- David Carlisle
Edit: [26/03/18]
Martin Scharrer just uploaded version 1.3 of standalone.cls to CTAN, which has the correct order of the border ...
20
votes
Accepted
What is best practice to set up Multi-file tex documents?
I think that the multifile howto is pretty easy, but as commented, it depends on what you want to achieve or how you organize your contents in the hard disk. Also, you must be aware that some package ...
19
votes
Accepted
Is my current workflow worth using or idiotic?
So as promised in the comments, here is my current setup for image-heavy documents using TikZ and similar (the below uses TikZ, circuitikz, includes SVGs, plots created with Python and possibly other ...
18
votes
LuaLaTeX, TeXLive 2016, standalone: undefined control sequence
The easiest way is to load luatex85 package. You probably will need to load it before documentclass, using RequirePackage
The longer story is that luatex now no longer defines many primitives with ...
18
votes
Accepted
How to control padding around standaloneframe content?
The standalone package by default crops the page to its contents. There is also a border option (also called margin, which I think is a better name) that allows you to put a white space margin around ...
14
votes
Accepted
Centering standalone tikz picture
Detecting the problem
By adding a \frame around the tikzpicture, you'll get a tight frame around the image that will show you what is really happening and where is the additional space; adding a ...
14
votes
Accepted
Standalone: document size
As the TeX Book says (p. 63)
From TeX's viewpoint, a single character from a font is a box [...]
The character shape need not fit inside the boundaries of its box.
Here we have such a situation: ...
13
votes
Accepted
Doesn't the verbatim environment work with the standalone class?
Try
\documentclass[preview]{standalone}% <-- added option "preview"
\begin{document}
\begin{verbatim}
Ciao
\end{verbatim}
\end{document}
This should work ...
Edit: Also work with option ...
12
votes
Image shifts when removing percent (%) signs with standalone class
This is a specific problem of standalone. You can look at What is the use of percent signs (%) at the end of lines? for understanding what follows.
By default, standalone typesets the text in the ...
12
votes
Accepted
Tikz image of normalizing flow
To nest figures, I use savebox as shown in this answer.
Update 1: Improved dash pattern closure around the circle with dash pattern.
Value found by do-it-yourself, and trial-and-error.
\draw[dash ...
12
votes
Tikz image of normalizing flow
With the great help from @AndréC, this is what I ended up with:
\documentclass[border=1cm,tikz]{standalone}
\usetikzlibrary{positioning}
\newcommand{\distro}[4][40]{
\begin{tikzpicture}[scale=.8]
...
11
votes
The PNG image of a TikZ picture that is generated by the standalone document class has the wrong dimensions
No. It does not. It depends how you measure it.
Measuring in MS Word:
Three different resolution images placed in Word:
When printed:
Measuring in LaTeX:
The Code:
\documentclass[]{...
11
votes
Accepted
TikZ in standalone not centering
It's the end of line after the \tikzstyle declaration. Move it before \begin{document}.
By the way, \tikzstyle is deprecated and I changed it to the currently preferred format.
\documentclass{...
11
votes
Accepted
How to ensure two standalone documents have same dimensions
The reason can be seen from this example:
\documentclass{standalone}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\draw [line width=1cm] (0,0) -- (1,0);
\draw [red] (0,0) -- (1,0);
\...
10
votes
Accepted
How to use standalone with multiple files?
You have to enclose each “page” in an environment:
\documentclass[multi,crop,border=2]{standalone}
\standaloneenv{my}
\begin{document}
\begin{my}
Test1
\end{my}
\begin{my}
Test2
\end{my}
\end{...
10
votes
Accepted
Find the coordinates of a point in a TikZ picture, with respect to the borders drawn by standalone package
The coordinate of the center of the node (at (0,0)) will stay the same. But you can extract the coordinates of the bounding box (which is identical with the output format if you use the standalone ...
9
votes
Errors using standalone package to create a table
I think the key here is to add the [varwidth=\maxdimen] class option to the preamble. It's similar to using minipage. I removed all the unnecessary clutter to keep it clear and simple, but you can add ...
9
votes
Accepted
tikz with standalone has border at left
This happens because there are paragraphs and other whitespace before the actual image.
If you move the \begin{document} to be right before \begin{tikzpicture}, the problem disappears because ...
9
votes
Accepted
Conversion by standalone fails when compiling using lualatex
That's because standalone is still using \write18 for shell escape. Just don't use standalone, it's broken in too many places (in my opinion).
You can trick standalone into thinking that traditional ...
9
votes
Accepted
LaTeX Table to Standalone?
I don't think that using a tabularx environment with two equally wide columns and some ensuing line-breaks in the first column generates a good layout. I'd go with a basic tabular environment, use l ...
8
votes
Accepted
Support for typesetting a table as stand-alone PDF
The abstract of documentation for package standalone notes:
The standalone bundle allows users to easily place picture environments
or other material in own source files and compile these on ...
8
votes
Accepted
chessboard + standalone
You can enlarge the right margin of the board (the default value is 1em):
\documentclass[]{standalone}
\usepackage{chessboard}
\usepackage{moreenum}
\begin{document}
\chessboard[%
setwhite={Qa1,...
8
votes
Accepted
Using standalone to combine multiple .tex into a single file
Use this master:
\documentclass{article}
\usepackage{standalone}
\title{My Book}
\author{Me}
\begin{document}
\maketitle
\input{Section1.tex}
\end{document}
and this Section1
\documentclass{article}...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
standalone × 663tikz-pgf × 180
pgfplots × 41
beamer × 30
pstricks × 28
crop × 24
subfiles × 23
graphics × 22
errors × 20
pdftex × 20
preview × 20
import × 19
png × 18
input × 17
tables × 16
xetex × 14
overleaf × 14
tikz-external × 14
luatex × 13
include × 13
spacing × 12
cross-referencing × 12
pdf × 11
margins × 11
conversion × 11