LaTeX forum ⇒ Graphics, Figures & TablesIssue with wrapped Figure

Information and discussion about graphics, figures & tables in LaTeX documents.
andreamizzi
Posts: 1
Joined: Sat Mar 23, 2013 1:35 pm

Issue with wrapped Figure

Postby andreamizzi » Sat Mar 23, 2013 1:41 pm

Hello,

I'm trying to use this macro for wrapping text around a figure.
  1. \newcommand{\figuremacroN}[3]{
  2. \begin{wrapfigure}{l}{0.5\textwidth}
  3. \centering
  4. \includegraphics[width=0.48\textwidth]{#1}
  5. \caption[#2]{{\small\textbf{#2} - #3}}
  6. \label{#1}
  7. \end{wrapfigure}
  8. }


  1. \figuremacroN{Figure3}{Comparison A and B}{\label{file1_figure3}They are different}


Instead of wrapping the figure it prints "l0.5" left of the figure in the PDF and not the caption (see attachment). What am I doing wrong?

Thanks for your help!
Attachments
wrapfigureerror.png
wrapfigureerror.png (154.05 KiB) Viewed 875 times
Last edited by localghost on Sat Mar 23, 2013 2:01 pm, edited 1 time in total.
Reason: Source code has to be tagged as such to keep a post clear and legible (see Board Rules).

Link:
BBcode:
HTML:
Hide post links
Show post links

User avatar
cgnieder
Site Moderator
Posts: 1948
Joined: Sat Apr 16, 2011 7:27 pm
Location: Germany
Contact:

Postby cgnieder » Sun Mar 24, 2013 3:38 pm

Hi andreamizzi,

Welcome to the LaTeX community!

Could you please complete your code snippet into a complete (i.e. compilable) Infominimal working example and possibly attach a graphic file to your post so we can test and reproduce the erroneous behavior?

Regards
Clemens
------------------------------
New German Q&A site about TeX: http://texwelt.de/wissen

Link:
BBcode:
HTML:
Hide post links
Show post links


Return to “Graphics, Figures & Tables”

Who is online

Users browsing this forum: No registered users and 2 guests