Matnlarga ishlov berish LaTex text Formatting


Customizing the multiple-choice environments


Download 0.75 Mb.
bet10/18
Sana09.04.2023
Hajmi0.75 Mb.
#1344635
1   ...   6   7   8   9   10   11   12   13   ...   18
Bog'liq
Matnlarga ishlov berish

5. Customizing the multiple-choice environments
The different environments for writing choices that we explained at the beginning of the tutorial can be customized in several ways. We have already explained one of the commands used to customize the appearance of the correct answer, namely \CorrectChoiceEmphasis.
Furthermore, the checkbocex and oneparcheckboxes environments allow customization of the characters used for checkboxes and checks.

  • First, the checkbox printed in these environments is controlled by the argument passed to the command \checkboxchar. By default, the value of this command is:

\checkboxchar{$\bigcirc$}

but we could also use squares, declaring
\checkboxchar{$\Box$}
and loading in the preamble the amssymb package.

  • Second, the check that is printed for correct choices in these environments (of course, when solutions are being printed) is controlled by the argument of the command \checkedchar. The default symbol is created with the command:

\checkedchar{$\surd$}
Now let’s see a couple of examples of these customization options in action:
% Illustrative example
\documentclass[answers]{exam}
\usepackage{amssymb}
\begin{document}
\begin{questions}
\checkboxchar{$\Box$}
\checkedchar{$\blacksquare$}
\question Which of the following is not a Greek
philosopher?
\begin{oneparcheckboxes}
\choice Socrates
\choice Plato
\choice Pythagoras
\CorrectChoice You
\end{oneparcheckboxes}
\checkboxchar{$\heartsuit$}
\checkedchar{$\spadesuit$}
\question Which of the following is not a Greek
philosopher?
\begin{checkboxes}
\choice Socrates
\choice Plato
\choice Pythagoras
\CorrectChoice You
\end{checkboxes}
\end{questions}
\end{document}

You can see how these multiple-choice questions look in the following image:
Multiple choice questions with customized checkboxes.

Download 0.75 Mb.

Do'stlaringiz bilan baham:
1   ...   6   7   8   9   10   11   12   13   ...   18




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling