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.

Since the text in the figures are too small, it's better if I can enlarge them without putting each subfigure on a separate line. I can see only one way to do this is expand the figure to cover the spaces on the left and right side of the figure. Is there any way I can do this ? Here is the part of the page which contains the figure The figure And the code to generate it.

\begin{figure*}[!h!t]
\centering

\subfigure[Panda - Week 2]{
   \includegraphics[width=0.4\linewidth] {fig/thang_panda2.png}
   \label{fig:esp1_3}
}
\subfigure[Panda - Week 3]{
   \includegraphics[width=0.4\linewidth] {fig/thang_panda3.png}
   \label{fig:esp1_4}
}

\subfigure[Penguin - Week 2]{
   \includegraphics[width=0.4\linewidth] {fig/thang_penguin2.png}
   \label{fig:esp1_5}
 }
\subfigure[Penguin - Week 3]{
   \includegraphics[width=0.4\linewidth] {fig/thang_penguin3.png}
   \label{fig:esp1_6}
}
   \caption{Collaboration using the whiteboard}
   \label{fig:esp1}
\end{figure*}
share|improve this question
    
Just to clarify, you're trying to get the figures to expand past the margins, to fill more of the page horizontally? –  Nathanael Farley Jan 10 '13 at 0:14
    
If that's the case then davbud's answer on tex.stackexchange.com/questions/57702/… should do the job –  Nathanael Farley Jan 10 '13 at 0:16
    
It doesn't seem like you're using a twoside option, so \makebox[\linewidth]{\includegraphics[width=<len>]{<file>}} where you specify <len> would work. Even if <len>>\textwidth (say \paperwidth, or 1.1\textwidth, you won't receive any overfull box warnings, since the output is stored in a box of width \linewidth. –  Werner Jan 10 '13 at 0:56

1 Answer 1

up vote 4 down vote accepted

You can use the adjustwidth environment from the changepage package to help here; the general syntax is

\begin{adjustwidth}{<left offset>}{<right offset>}

Note that when using it with a float (such as figure) you have to put it inside the figure environment.

\documentclass{article}
\usepackage[demo]{graphicx}
\usepackage{subfig}
\usepackage{changepage}

\begin{document}

\begin{figure*}[!h!t]
    \begin{adjustwidth}{-2cm}{-2cm}
        \centering
        \subfloat[Panda - Week 2]{
        \includegraphics[width=0.4\linewidth] {fig/thang_panda2.png}
        \label{fig:esp1_3}
        }
        \subfloat[Panda - Week 3]{
        \includegraphics[width=0.4\linewidth] {fig/thang_panda3.png}
        \label{fig:esp1_4}
        }

        \subfloat[Penguin - Week 2]{
        \includegraphics[width=0.4\linewidth] {fig/thang_penguin2.png}
        \label{fig:esp1_5}
        }
        \subfloat[Penguin - Week 3]{
        \includegraphics[width=0.4\linewidth] {fig/thang_penguin3.png}
        \label{fig:esp1_6}
        }
        \caption{Collaboration using the whiteboard}
        \label{fig:esp1}
    \end{adjustwidth}
\end{figure*}

\end{document}

Note also that the subfigure package is considered obsolete (see What is the difference between \subfigure and \subfloat?) and you should use subfig instead which has the command subfloat.

You might also look at the subcaption package- a comparison is made in subcaption vs. subfig: Best package for referencing a subfigure

share|improve this answer

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.