1

I am trying to align the beginning of an image caption with the bullet point given by \item. I have included the portion of my code below.

\documentclass[a4paper,12pt]{extarticle}
                          
\usepackage{graphicx} 
\usepackage{amsmath}
\usepackage{amsfonts} 
\usepackage{amssymb} 
\usepackage{amsthm}
\usepackage{mathtools} 
\usepackage{float}
                
\begin{document}

\begin{itemize}
\item Super-Equilateral Isosceles Triangle: description
\begin{figure}[H]
\centering
\includegraphics[width=2.5cm]{super-equilateral isosceles triangle with division plane.JPG.png}
\caption{Super-equilateral isosceles triangle. The predicted division plane is marked with a red line.}
\label{fig: Super-equilateral isosceles triangle. The predicted division plane is marked with a red line.}
\end{figure} 
\end{itemize}

\end{document}

At present, the caption starts too far to the left as shown below.

enter image description here

1

1 Answer 1

2

Since you're using a non-float for your figure, you might as well place it inside a minipage in order to limit the horizontal width of the float box. The width here is fixed to \linewidth - the natural width within the itemize.

enter image description here

\documentclass{extarticle}

\usepackage{graphicx,float}

\begin{document}

\begin{itemize}
  \item Super-Equilateral Isosceles Triangle: description
  
  \medskip
  
  \begin{minipage}{\linewidth}
    \begin{figure}[H]
      \centering
      \includegraphics[width=2.5cm]{example-image}
      \caption{Super-equilateral isosceles triangle. The predicted division plane is marked with a red line.}
    \end{figure}
  \end{minipage}
\end{itemize}

\end{document}

If you don't wish to add an accompanying figure caption, you don't need a figure environment. You can just place the image inside (say) a center environment:

  \item Super-Equilateral Isosceles Triangle: description
  
    \begin{center}
      \includegraphics[width=2.5cm]{example-image}
    \end{center}
2
  • This worked very well. Just curious, what does the command \medskip do?
    – M B
    Jan 21, 2021 at 3:23
  • \medskip inserts a medium vertical skip (equivalent to \medskipamount). There's also \smallskip and \bigskip (inserting a \smallskipamount/\bigskipamount vertical space).
    – Werner
    Jan 21, 2021 at 3:27

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .