[tex4ht] tex4ht options, figure placement and exerquiz
Nasser M. Abbasi
nma at 12000.org
Sun Jan 10 21:38:23 CET 2021
On 1/10/2021 2:13 PM, Tomas Davidek wrote:
>
> 2. a detail regarding the figure placement. The LaTeX code
>
> \begin{figure}
> \centering
> \includegraphics[width=0.49\linewidth]{figures/kinematika/k0long_lips.eps}
> \includegraphics[width=0.49\linewidth]{figures/kinematika/dplus_lips.eps}
> \caption{The figure caption....}
> \label{fig:invariant_mass_distrib_example}
> \end{figure}
>
> normally results in two plots side-by-side, but in HTML the pictures are
> organized one on top of the other. Is there a way to restore the
> original behaviour?
I've always used tabular to force placement of images in html, something like
------------------
\documentclass[11pt]{article}
\usepackage{amsmath}
\usepackage{graphicx}
\begin{document}
\ifdefined\HCode
\begin{tabular}{p{5in}p{5in}} %adjust as needed
\includegraphics[width=5in]{images/lambda_3}&
\includegraphics[width=5in]{images/lambda_4}\\
\end{tabular}
\else
\begin{figure}
\centering
\includegraphics[width=0.49\linewidth]{images/lambda_3}
\includegraphics[width=0.49\linewidth]{images/lambda_4}
\caption{The figure caption....}
\label{fig:invariant_mass_distrib_example}
\end{figure}
\fi
\end{document}
----------------------
There might be better ways.
--Nasser
More information about the tex4ht
mailing list.