Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

When I pdflatex the text below it doesn't insert the picture, but writes the name of the file instead (pic).

And the geometry line gives the error

! LaTeX Error: Missing \begin{document}.

The picture I am using is at http://bayfiles.com/file/jIHB/oeWKYv/pic.pdf and the floatrow package from.

Question

Can anyone see what is wrong?

Text

\documentclass[a4paper]{article}
\pdfpagewidth=\paperwidth
\pdfpageheight=\paperheight
\usepackage{aeguill}
\pdfcompresslevel=9
\usepackage[pdftex,colorlinks]{hyperref}

\usepackage{a4}
\usepackage{fixltx2e}
\usepackage[danish]{babel}
\usepackage[latin1]{inputenc}
\usepackage[T1]{fontenc}

\usepackage[draft]{graphicx}
\usepackage{floatrow}

\usepackage{geometry}

\geometry{margin=10pt,paperwidth=\textwidth+20pt,paperheight=\textheight+20pt}

\begin{document}

The first paragraph.

\begin{figure}  
\includegraphics{pic}
\end{figure}

And the second.

\end{document}
share|improve this question
add comment

2 Answers

up vote 6 down vote accepted
\usepackage[draft]{graphicx}

Remove the draft option which just tells latex to print the file name and not include the image.

Add

 \usepackage{calc}

To allow infix + syntax in

\geometry{margin=10pt,paperwidth=\textwidth+20pt,paperheight=\textheight+20pt}
share|improve this answer
add comment

Without loading other packages as many as possible, use \geometry{margin=10pt,paperwidth=\dimexpr\textwidth+20pt\relax,paperheight=\dimexpr\textheight+20pt\relax}

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.