0

I am using the document class:\documentclass{standalone}. However, I am unable to use the commands \begin{figure} and \end{figure}. What package do I need to include to be able to use the commands \begin{figure} and \end{figure}.

  • 1
    why would you want a floating environment in standalone? That is a special class not for making documents. Almost any normal class will let you use floats, article, report, book, memoir, the koma classes, .... – David Carlisle Jun 07 '13 at 21:43
  • @DavidCarlisle Essentially, I want to enclose a tikzpicture in the figure environment, with caption. –  Jun 07 '13 at 21:44
  • But it doesn't make sense to put a float into standalone, you just want to do the tikzpicture then re-include it into a float in your real document so it can float. – David Carlisle Jun 07 '13 at 21:45
  • @DavidCarlisle The advantage with using standalone documentclass for a tikzpicture is it provides a pdf with no unnecessary white space, i.e., the pdf is completely filled with the picture generated by tikz, which makes it easier for me to include the image/picture in other files. If I were to use say article as a documentclass, then there are unnecessary white spaces, I need to contend with. (I can use tikz package under standalone documentclass to draw diagrams/pictures.) –  Jun 07 '13 at 21:47
  • @DavidCarlisle To reformulate the question: Can I add caption to a tikzpicture without using the figure environment, so that I can use it under the standalone documentclass? –  Jun 07 '13 at 21:49
  • @user17762 The standalone class is designed specifically for that purpose. You only need the figure environment in your document. See the manual for details. – percusse Jun 07 '13 at 21:53

0 Answers0