# Position and scaling with graphicx package

In the good ol' days I drew figures with xfig and generated LaTeX source to directly include in my papers. But I now find powerpoint to be a faster drawing tool and sufficient for most of my needs. What's the best way to embed the resulting image in LaTex?

I current output to pdf, then include using the graphicx package. But the resulting scaling and positioning trial-and-error session is often extremely frustrating, and the documentation on the package is quite sparse and unhelpful. Is there a better way?

-

The best way, in my opinion, is to print your graphic from ppt/word/excel into a pdf. And with printing I mean using one of the free pdf-printers you can install. I know office2007 comes with a pdf save option, but I found that those pdfs behave strange, especially when it comes to crop the page.

After you extracted your graphic into a pdf, use the `pdfcrop` tool that should ship with your latex distribution. A simple command in the command promt:

``````pdfcrop filename.pdf
``````

will remove all the empty white around the graphic. For windows you need to have a perl interpreter installed. In case you haven't, you get a error message. Possible interpreters are active perl and strawberry perl

-
Perfect. I had no idea this `pdfcrop` tool existed (and in fact, it is not included in my LaTeX: pdfTeX 3.1415926-1.40.10-2.2 (TeX Live 2009), but I'm sure I can find it). –  Fixee Feb 25 '11 at 17:49

You won't find many friends of PowerPoint here; basically if that is your drawing program than the only method to get it into LaTeX documents is via an exported-and-included PDF.

But if you used `xfig` to generate LaTeX code (I'm guessing within the `picture` environment?) then you might appreciate `tikz`. It allows you to make (and thereby control) all your graphics with a TeX syntax. That or `pstricks` would probably be considered by most here to be "The LaTeX way" to do graphics.

-
@matthew-leingang is there any drawing interface to easily get figures in tikz or pstricks code? –  Mortimer Feb 25 '11 at 8:22
The only one I know of is Inkscape (think open source Adobe Illustrator) with the experimental inkscape2tikz plugin. Since Inkscape reads SVG this means you can use any program that exports SVG. –  Matthew Leingang Feb 25 '11 at 10:17
A simple `width=\textwidth` is then enough to get it right.