Using the packages adjustbox and qtree simultaneously causes the error:
Package graphics Error: Division by 0. \includegraphics[width=0.3\textwidth]{myimage.bmp}
Minimal working example:
\documentclass{report} \usepackage{adjustbox} %Lets table extend beyond margins \usepackage{qtree} %Allows drawing of syntax etc trees '\Tree' \begin{document} \begin{figure}[hp] \centering \includegraphics[width=0.3\textwidth]{myimage.bmp} \caption{My image} \label{fig:figure1} \end{figure} \end{document} Is it possible to use them both in the same document?
Edit: This is being compiled with XeLateX.
Edit2: This bug only occurs with .bmp, and not with .png files; changing file format is a fine workaround.
myimage.bmp.graphicxloaded instead. Two thoughts: (1) use a different file format; (2) if sticking with bitmaps, you probably need to use thebmpsizepackage.adjustboxloadsgraphicx(which is where the\includegraphicscommand comes from), the question becomes: doesqtreeconflict withgraphicx? But I mean don't use bitmaps as a matter of general practice. I can't actually reproduce the problem, however, so I'm not suggesting it as the solution, just a possible workaround. (Tonight, I'll try again with another.bmpfile.)myimage.bmptoexample-image-a, does the example work? I have no idea where I'd get a BMP from. But there is certainly no essential conflict ifadjustboxandqtreework with other image formats.