# Empty space in standalone document with textopo

The question is related to similar issues with standalone package: lots of empty space is added in addition to the desired figure. However, this time no empty paragraphs in source code. My MWE:

\documentclass[convert]{standalone}
\usepackage[english]{babel}
\usepackage{textopo}
\begin{document}
\begin{textopo}
\sequence{EIKKKLFWRAV[VAEFLAMTLFVFISIGSA]LGFNYPLERN}
\end{textopo}
\end{document}


Produces following png after running pdflatex -shell-escape -synctex=1 -interaction=nonstopmode mwe.tex

I suspect that the problem is in textopo package rather than standalone, however, I need confirmation from someone more experienced. And any workaround would be highly appreciated.

I would just use article and then crop externally eg using pdfcrop using

\documentclass{article}
\usepackage[english]{babel}
\usepackage{textopo}
\begin{document}
\pagestyle{empty}
\begin{textopo}
\sequence{EIKKKLFWRAV[VAEFLAMTLFVFISIGSA]LGFNYPLERN}
\end{textopo}
\end{document}


followed by applying pdfcrop (as installed with texlive 2012) produces

• Thank you, this combo seems like reasonable replacement for standalone class – lastpook May 22 '13 at 21:06

If I build the textopo environment in a box, the computed width is 5178.32596pt, which is 6 feet or 1.8 meters.

You get a more reasonable output if you use the varwidth option to standalone. There's still white space at the sides, though.

\documentclass[varwidth,convert]{standalone}
\usepackage{textopo}
\begin{document}
\begin{textopo}
\sequence{EIKKKLFWRAV[VAEFLAMTLFVFISIGSA]LGFNYPLERN}
\end{textopo}
\end{document}


• Thank you for answer, egreg. Yes, varwidth works fine with MWE. However, my real need includes much longer sequence argument and the output doesn't fit to the linewidth anymore. So eventually I'll need to manually adjust document width - exactly what I was trying to avoid using standalone class :) – lastpook May 22 '13 at 21:04
• @user28683 [preview,convert] give the same output like above. Note: "Tikz pstricks ...picture and similar environments are the main target of the standalone class".pdfcrop is another way. – texenthusiast May 22 '13 at 21:10