General ⇒ text on left and graphics(Fig.) image on the right
text on left and graphics(Fig.) image on the right
Hi,
I use latex to prepare question papers for my class, for geometry i used jpg files (for geometric figs) and then give there path in latex.
The image comes below the question, i always try to get them to the right side of question on the same line, but am unable to do so, can any one show me how to do that.
IT show look some thing like this
show that triangel ABC cong. triangel PQR,
Given that AB is cong. to PQ,~~~~~~~~~~~~~~~~~~~~~~~~Fig. of the questn. should
BC is cong. to QR.~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~be here.
angle B is cong. to angle Q
~ in above text means blank space
Pls. help how can i do this, Pls. I use mitex for windows.
Thanks,
Metric.
I use latex to prepare question papers for my class, for geometry i used jpg files (for geometric figs) and then give there path in latex.
The image comes below the question, i always try to get them to the right side of question on the same line, but am unable to do so, can any one show me how to do that.
IT show look some thing like this
show that triangel ABC cong. triangel PQR,
Given that AB is cong. to PQ,~~~~~~~~~~~~~~~~~~~~~~~~Fig. of the questn. should
BC is cong. to QR.~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~be here.
angle B is cong. to angle Q
~ in above text means blank space
Pls. help how can i do this, Pls. I use mitex for windows.
Thanks,
Metric.
NEW: TikZ book now 40% off at Amazon.com for a short time.

- localghost
- Site Moderator
- Posts: 9202
- Joined: Fri Feb 02, 2007 12:06 pm
text on left and graphics(Fig.) image on the right
You could use the wrapfig package that makes text wrapping the figure automatically.
The used document class and packages should be well-known. Descriptions and documentations are available on CTAN.
Best regards
Thorsten¹
Code: Select all
\documentclass[BCOR13mm,DIV15]{scrartcl}
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
\usepackage[english]{babel}
\usepackage[font=small,labelfont=bf]{caption}
\usepackage{blindtext}
\parindent0pt
\begin{document}
\blindtext
\medskip
\begin{wrapfigure}{r}{7cm}
\centering
\rule{6.4cm}{3.6cm}
\caption{Dummy figure}\label{fig:dummy}
\end{wrapfigure}
\blindtext
\medskip
\blindtext
\end{document}
Best regards
Thorsten¹
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes
¹ System: TeX Live 2025 (vanilla), TeXworks 0.6.10
Board Rules
Avoidable Mistakes
¹ System: TeX Live 2025 (vanilla), TeXworks 0.6.10
Re: text on left and graphics(Fig.) image on the right
Hi,
Thanks for the info., i used the wrap command and was able to get the desired result, however when i used it along with enumerate command and used \item command. am unable to get the desired output.
Pls. assit , in short am unable to use wrapfigure command along with \item command, Pls. can you let me know how to do that.
Thank you,
metrics
Thanks for the info., i used the wrap command and was able to get the desired result, however when i used it along with enumerate command and used \item command. am unable to get the desired output.
Pls. assit , in short am unable to use wrapfigure command along with \item command, Pls. can you let me know how to do that.
Thank you,
metrics
text on left and graphics(Fig.) image on the right
Use two parallel minipages:
The precise alignment of the minipages depends on their contents.
Code: Select all
\documentclass{article}
% To get the \captionof command, load
% capt-of or caption
\usepackage{caption}
%\usepackage{capt-of}
\begin{document}
\noindent
\begin{minipage}{0.45\linewidth}
Here we have a list:
\begin{enumerate}
\item One
\item Two
\item Three
\end{enumerate}
\end{minipage}%
\hfill
\begin{minipage}{0.45\linewidth}
\centering
\rule{0.9\linewidth}{0.5\linewidth}
\captionof{figure}{Dummy figure}\label{fig:f1}
\end{minipage}
\bigskip \bigskip
\noindent
\begin{minipage}[t]{0.45\linewidth}
\vspace{0pt}
Here we have a list:
\begin{enumerate}
\item One
\item Two
\item Three
\end{enumerate}
\end{minipage}%
\hfill
\begin{minipage}[t]{0.45\linewidth}
\vspace{0pt}
\centering
\rule{0.9\linewidth}{0.5\linewidth}
\captionof{figure}{Dummy figure}\label{fig:f2}
\end{minipage}
\end{document}
Re: text on left and graphics(Fig.) image on the right
You also can input the (plain tex) package insbox, which hasn't the same limitations as wrapfig and is very simple to use.
B.A.
B.A.
- localghost
- Site Moderator
- Posts: 9202
- Joined: Fri Feb 02, 2007 12:06 pm
text on left and graphics(Fig.) image on the right
I did some experiments with invisible characters and negative vertical spaces. But I ran into trouble.
The result is the same as if using the approach given by Juanjo with two minipage environments side by side. The figure is not wrapped by the text.
As additional alternatives to that given by balf I suggest the floatflt package or the picins package.
Code: Select all
\documentclass[BCOR13mm,DIV15]{scrartcl}
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
\usepackage[english]{babel}
\usepackage[font=small,labelfont=bf]{caption}
\parindent0pt
\begin{document}
\begin{wrapfigure}[10]{r}{7cm}
\centering
\rule{6.4cm}{3.6cm}
\caption{Dummy figure}\label{fig:dummy}
\end{wrapfigure}
~
\vspace{-\baselineskip}
\begin{enumerate}
\item The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
\item The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
\item The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
\item The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
\item The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
\item The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
\item The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
\item The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
\end{enumerate}
\end{document}
As additional alternatives to that given by balf I suggest the floatflt package or the picins package.
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes
¹ System: TeX Live 2025 (vanilla), TeXworks 0.6.10
Board Rules
Avoidable Mistakes
¹ System: TeX Live 2025 (vanilla), TeXworks 0.6.10
Re: text on left and graphics(Fig.) image on the right
As far as I know, floatflt and picins have problems in the neighbourhood of a list environment, which shouldn't be the case with insbox, as it is a plain TeX package.
B.A.
B.A.
text on left and graphics(Fig.) image on the right
Sorry, am unable to get the result i want, below is a sample of the output result i would like to get but am unable to do so even after exprimenting with above code, pls. assist ...Juanjo wrote:Use two parallel minipages:The precise alignment of the minipages depends on their contents.Code: Select all
\documentclass{article} % To get the \captionof command, load % capt-of or caption \usepackage{caption} %\usepackage{capt-of} \begin{document} \noindent \begin{minipage}{0.45\linewidth} Here we have a list: \begin{enumerate} \item One \item Two \item Three \end{enumerate} \end{minipage}% \hfill \begin{minipage}{0.45\linewidth} \centering \rule{0.9\linewidth}{0.5\linewidth} \captionof{figure}{Dummy figure}\label{fig:f1} \end{minipage} \bigskip \bigskip \noindent \begin{minipage}[t]{0.45\linewidth} \vspace{0pt} Here we have a list: \begin{enumerate} \item One \item Two \item Three \end{enumerate} \end{minipage}% \hfill \begin{minipage}[t]{0.45\linewidth} \vspace{0pt} \centering \rule{0.9\linewidth}{0.5\linewidth} \captionof{figure}{Dummy figure}\label{fig:f2} \end{minipage} \end{document}
1) prove that triangle ABC is cong to trian PQR
Given : some given conditions ..... ~~~~~~~~~~~~~~~
............................~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~Fig. for question 1)
.........................
2) prove that some of the measure of a triangle
is 180 degree~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Fig. for Q2)
3) Prove that sum of the measure of 2 angles in a
triangle is greater than or equal to 3rd angle~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~Fig for Q. 3
text on left and graphics(Fig.) image on the right
Sorry, am unable to get the result i want, below is a sample of the output result i would like to get but am unable to do so even after exprimenting with above code, pls. assist ...
1) prove that triangle ABC is cong to trian PQR
Given : some given conditions ..... ~~~~~~~~~~~~~~~
............................~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~Fig. for question 1)
.........................
2) prove that some of the measure of a triangle
is 180 degree~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Fig. for Q2)
3) Prove that sum of the measure of 2 angles in a
triangle is greater than or equal to 3rd angle~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~Fig for Q. 3
Thanks for devoting the time, i really want to get the output as listed above, thanks for the efforts put in by the forum members.
Pls. help me in letting me knew on how to get the output,
Thanks,
metric
1) prove that triangle ABC is cong to trian PQR
Given : some given conditions ..... ~~~~~~~~~~~~~~~
............................~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~Fig. for question 1)
.........................
2) prove that some of the measure of a triangle
is 180 degree~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Fig. for Q2)
3) Prove that sum of the measure of 2 angles in a
triangle is greater than or equal to 3rd angle~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~Fig for Q. 3
Thanks for devoting the time, i really want to get the output as listed above, thanks for the efforts put in by the forum members.
Pls. help me in letting me knew on how to get the output,
Thanks,
metric
text on left and graphics(Fig.) image on the right
Does the following code fit your needs now?
Let's remark that I use the same basic idea as in my previous post. Now there are two parallel minipages in each list entry.
Code: Select all
\documentclass{article}
\usepackage{graphicx}
\usepackage[font=small]{caption}
\begin{document}
\begin{enumerate}
\item
\begin{minipage}[t]{0.45\linewidth}
Prove that triangle $ABC$ is congruent to triangle $PQR$.
Given these conditions blah blah blah.
\end{minipage}%
\hfill
\begin{minipage}[t]{0.45\linewidth}
\centering
\vspace{-1.5ex}
\rule{0.9\linewidth}{0.5\linewidth} %
\captionof{figure}{See triangles $ABC$ and $PQR$}\label{fig:f1}
\end{minipage}
\item
\begin{minipage}[t]{0.45\linewidth}
Prove this and that. Try this and that blah blah blah.
\end{minipage}%
\hfill
\begin{minipage}[t]{0.45\linewidth}
\centering
\vspace{-1.5ex}
\rule{0.9\linewidth}{0.5\linewidth}
\captionof{figure}{This picture exemplifies blah blah}\label{fig:f2}
\end{minipage}
\end{enumerate}
\end{document}