LaTeX forum ⇒ Graphics, Figures & TablesRemoving extra white Space around Figure

Information and discussion about graphics, figures & tables in LaTeX documents.
hbaromega
Posts: 48
Joined: Mon Mar 07, 2011 8:21 pm

Removing extra white Space around Figure

Postby hbaromega » Mon May 20, 2013 5:02 pm

We used to use clip format in normal documents with \includegraphics environment to get rid of the extra white space around a figure.

However, it does not work while using the beamer class. Could be there a way out?

Tags:

User avatar
tom
Posts: 73
Joined: Thu Apr 18, 2013 4:02 am

Postby tom » Tue May 28, 2013 11:30 am

I have no problems clipping a figure in beamer. Could you provide a MWE?

  1. \documentclass{beamer}
  2.  
  3. \begin{document}
  4. \begin{frame}{Clip image}
  5. \centering
  6. \includegraphics[trim=2cm 2cm 2cm 2cm,clip=true,width=5cm]{figure1}
  7. \end{frame}
  8. \end{document}

hbaromega
Posts: 48
Joined: Mon Mar 07, 2011 8:21 pm

Postby hbaromega » Thu Feb 12, 2015 3:38 pm

Actually trim doesn't have any control. It cuts some non-white part of one figure and height of two figures don't match (see my MWE).

Like I used to do in dvi, clip is supposed to automatically remove the unnecessary white spaces around the figure. My MWE is given below.

  1. \documentclass[xcolor=svgnames,10pt]{beamer}
  2. \usetheme{classic}
  3. \usepackage{graphicx}
  4.  
  5. \begin{document}
  6. \frame{
  7. \frametitle{Sample Title}
  8. \begin{tabular}{l l}
  9. %
  10. \begin{minipage}{0.5\textwidth}
  11. \begin{figure}
  12. \includegraphics[height=5cm,trim=.5cm .5cm .5cm .5cm,clip]{Fig1.png}
  13. \end{figure}
  14. \end{minipage}
  15. %
  16. \begin{minipage}{0.5\textwidth}
  17. \begin{figure}
  18. \includegraphics[height=5cm,trim=.5cm .5cm .5cm .5cm,clip]{Fig2.png}
  19. \end{figure}
  20. \end{minipage}
  21. \end{tabular}
  22. }
  23.  
  24. \end{document}
  25.  


Do you need me to attach figures?

Thanks.


Return to “Graphics, Figures & Tables”

Who is online

Users browsing this forum: No registered users and 40 guests