3

In this MWE, the text of item 2 is on a separate line from the bullet point as shown in the attached image of the output.

\documentclass{article}

\usepackage{lipsum,changepage, mwe}
\begin{document}

\begin{itemize}

\item This is item 1. \lipsum[66] 

\item \begin{minipage}[t]{\dimexpr.5\textwidth-.5\columnsep}\vspace{0pt}%
    \raggedright
    This is item 2 \lipsum[66]
    \end{minipage}%
    \begin{minipage}[t]{\dimexpr.5\textwidth-.5\columnsep}\vspace{0pt}%
    \raggedright
    \includegraphics[scale=0.5]{example-image-a}
    \end{minipage}

\item This is item 3. \lipsum[66]

\end{itemize}

enter image description here

Question: How can I ensure the minipages start on the same line as the bullet point?

4
  • Remove the \vspace{0pt} from the first minipage environment? Jan 5 at 16:11
  • @WillieWong thanks, but then the image isn't aligned properly. Jan 5 at 16:19
  • How do you want the image aligned? Jan 5 at 16:19
  • With the first line of text Jan 5 at 16:20
3

The following should be closer to the expected output. Additionally to the alignment of the item and the image, I also made sure, the two minipages fit into the available space, since the original MWE caused an overfull box warning. (Red lines in the following screenshot indicate margins)

enter image description here

\documentclass{article}

\usepackage{lipsum}
\usepackage[export]{adjustbox} % provides the valign option

\begin{document}

\begin{itemize}

\item This is item 1. \lipsum[66] 

\item \begin{minipage}[t]{\dimexpr.5\linewidth-.5\columnsep}
    \raggedright
    This is item 2 \lipsum[66]
    \end{minipage}
    \hfill
    \begin{minipage}[t]{\dimexpr.5\linewidth-.5\columnsep}
    \raggedright
    \includegraphics[width=\linewidth,valign=t]{example-image-a}
    \end{minipage}

\item This is item 3. \lipsum[66]

\end{itemize}

\end{document}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.