how ican add image in the choices like this

Added by red sea almost 12 years ago

please how i can adding images in the choices like this pdf exam.


Replies (3)

RE: how ican add image in the choices like this - Added by red sea almost 12 years ago

ok thanks fo alixe.

for vir questions :

  \begin{choices}
    \correctchoice{\vbox to 1cm{\vfill\includegraphics[height=1cm,width=.5cm,keepaspectratio]{ele.jpg}\vfill}}
    \wrongchoice{\vbox to 1cm{\vfill\includegraphics[height=1cm,width=.5cm,keepaspectratio]{don.jpg}\vfill}}
    \wrongchoice{\vbox to 1cm{\vfill\includegraphics[height=1cm,width=.5cm,keepaspectratio]{don.jpg}\vfill}}
    \wrongchoice{\vbox to 1cm{\vfill\includegraphics[height=1cm,width=.5cm,keepaspectratio]{don.jpg}\vfill}}
  \end{choices}

for hor questions :

  \begin{choiceshoriz}
    \correctchoice{\hbox to 1cm{\hfill\includegraphics[height=1cm,width=.5cm,keepaspectratio]{don.jpg}\hfill}}
    \wrongchoice{\hbox to 1cm{\hfill\includegraphics[height=1cm,width=.5cm,keepaspectratio]{ele.jpg}\hfill}}
    \wrongchoice{\hbox to 1cm{\hfill\includegraphics[height=1cm,width=.5cm,keepaspectratio]{don.jpg}\hfill}}
    \wrongchoice{\hbox to 1cm{\hfill\includegraphics[height=1cm,width=.5cm,keepaspectratio]{don.jpg}\hfill}}
  \end{choiceshoriz}

regards

RE: how ican add image in the choices like this - Added by red sea almost 12 years ago

you can change image size, and vir or hor space.

regard

RE: how ican add image in the choices like this - Added by red sea almost 12 years ago

we can add latex graphes ...........

example :

in the head add the tikz graphs code (example):

\newcommand*\onn{\begin{tikzpicture}\draw[step=0.5cm] (0,0) grid (1,1);\end{tikzpicture}}
\newcommand*\tooo{\begin{tikzpicture}\draw[step=0.5cm] (0,0) grid (2,1);\end{tikzpicture}}
\newcommand*\thre{\begin{tikzpicture}\draw[step=0.5cm] (0,0) grid (3,1);\end{tikzpicture}}
\newcommand*\forr{\begin{tikzpicture}\draw[step=0.5cm] (0,0) grid (4,1);\end{tikzpicture}}

in the docum :

for tkiz graphs in vir questions :
for english..

\begin{choices}
\correctchoice{\onn}
\wrongchoice{\tooo}
\wrongchoice{\thre}
\wrongchoice{\forr}
\end{choices}
\end{question}

for arabic (must add arabic text, this make align from right to left)..

\begin{choices}
\correctchoice{شكل \onn}
\wrongchoice{شكل \tooo}
\wrongchoice{شكل \thre}
\wrongchoice{شكل \forr}
\end{choices}
\end{question}

(1-3/3)