Undefined control sequence. \includegraphics
Its pretty obvious now, that this is a valid instruction in Latex. After googling I found out that:
- You need to add \usepackage{graphicx} in the preamble, for this instruction to work.
- You need to provide complete path of the image file
- Don't include the extension of the image. Latex will search for it automatically. Not sure the sequence, but, I believe its .png, then .gif, ...
My code:
\begin{figure}
\centering
\includegraphics[width=150mm]{/home/username/report/fuse}
\end{figure}
Another interesting thing was to use tables which can word wrap long lines without cropping the table. I couldn't find any working example of this online, so putting it here, for reference:
\begin{tabular}{|c|p{5cm}|p{5cm}|}
topic & long line 1 & long line 2 \\end{tabular}
6 comments:
The path to the image file does not necessarily have to be absolute; it can also be a path relative to the main latex source file.
Thanks for the table example. Saved my day! :)
thnx for the line wrapping example. was searching for it for last 3 days.
Yep, the word-wrapping code was great for me. Thanks!
Word wrapping good for me too! Cheers
Currently writing a masters thesis, I was so fustrated by word wrapping in tables! Thank you.
Post a Comment