Generalincludegraphics

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
sinziana
Posts: 1
Joined: Wed Dec 05, 2007 2:44 pm

includegraphics

Post by sinziana »

Hello!

I am new user and I have a small problem with including images in my document.
I am using LEd as a text editor.

I am using
\begin{figure}[t]
\centering
\includegraphics{}
\caption{}
\label{fig:}
\end{figure}

and the problem is that \includegraphics is in italic (in other words the program does not recognize it as a valid command).

What can I do to fix this?

Sinziana

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

gmedina
Posts: 2313
Joined: Wed Jul 11, 2007 11:45 pm

includegraphics

Post by gmedina »

I don't know about your editor, but if \includegraphics is not recognized, maybe you forgot to load the graphicx package? Add in the preamble of your document (after \documentclass and before \begin{document})

Code: Select all

\usepackage{graphicx}
Addendum: now that I read your post once again, I notice that you are using

Code: Select all

\begin{figure}[t]
The more specifiers you use to indicate the placement of a floating object (in this case a figure), the better. Use [htb] instead of just [t]. If you want to "force" LaTeX to place the figure where you want and don't let it float at all, you can use an exclamation point before the position specifiers (i.e. something like [!ht] or [!th]).

This thread belongs to LaTeX->General
1,1,2,3,5,8,13,21,34,55,89,144,233,...
Post Reply