答案1
根据的文档standalone
,该类提供以下选项:
border={〈length (left)〉 〈length (bottom)〉 〈length (right)〉 〈length (top)〉}
\documentclass[
border={0pt 0pt 0pt 1cm}
]{standalone}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\draw (0, 0) rectangle (4, 4);
\end{tikzpicture}
\end{document}