summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/exam
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2021-03-01 03:01:22 +0000
committerNorbert Preining <norbert@preining.info>2021-03-01 03:01:22 +0000
commit3a1a102e980610859d9f1b197733d6ce6a541c62 (patch)
treef79acc362cf6dde2deff64ffa7bb7bfe1bea2e2c /macros/latex/contrib/exam
parent189140b53960215eec1626503040fb38360ab4ed (diff)
CTAN sync 202103010301
Diffstat (limited to 'macros/latex/contrib/exam')
-rw-r--r--macros/latex/contrib/exam/README4
-rw-r--r--macros/latex/contrib/exam/exam.cls93
-rw-r--r--macros/latex/contrib/exam/exam.md56
-rw-r--r--macros/latex/contrib/exam/examdoc.pdfbin481243 -> 482795 bytes
-rw-r--r--macros/latex/contrib/exam/examdoc.tex38
5 files changed, 121 insertions, 20 deletions
diff --git a/macros/latex/contrib/exam/README b/macros/latex/contrib/exam/README
index 01b54c4184..c640150cd6 100644
--- a/macros/latex/contrib/exam/README
+++ b/macros/latex/contrib/exam/README
@@ -1,5 +1,5 @@
-This is version 2.603 of the exam document class, dated December 17,
-2017.
+This is version 2.7 of the exam document class, dated February 26,
+2021.
The exam document class, together with its user's guide examdoc.tex,
attempts to make it easy for even a LaTeX novice to prepare exams.
diff --git a/macros/latex/contrib/exam/exam.cls b/macros/latex/contrib/exam/exam.cls
index cc587b3d65..ae851ef203 100644
--- a/macros/latex/contrib/exam/exam.cls
+++ b/macros/latex/contrib/exam/exam.cls
@@ -4,7 +4,7 @@
%% exam.cls
%% Copyright (c) 1994, 1997, 2000, 2004, 2008, 2011,
-%% 2015, 2017 Philip S. Hirschhorn
+%% 2015, 2017, 2021 Philip S. Hirschhorn
%
% This work may be distributed and/or modified under the
% conditions of the LaTeX Project Public License, either version 1.3
@@ -32,8 +32,8 @@
% from my web page: http://www-math.mit.edu/~psh/
-\def\fileversion{2.603}
-\def\filedate{2017/12/17}
+\def\fileversion{2.7}
+\def\filedate{2021/02/26}
%---------------------------------------------------------------------
%---------------------------------------------------------------------
%
@@ -86,6 +86,46 @@
% Changelog since version 2.4:
%--------------------------------------------------------------------
+% Version 2.7, 2021/02/26
+
+% No longer betatest.
+
+%--------------------------------------------------------------------
+% Version 2.607$\beta$, 2019/07/21
+
+% We fixed a bug, apparently introduced in version 2.602, that affected
+% vertical point tables (both regular and bonus, but not combined),
+% shifting the total points in the table towards the right of the cell,
+% rather than having the total points centered. The fix was to delete
+% an \hspace*{\fill} that had no business being there.
+
+% --------------------------------------------------------------------
+% Version 2.606$\beta$, 2019/02/17
+
+% We introduced a new command, \unstarredvspace, that changes the
+% solution environment so that, when solutions are not being printed,
+% any optional space called for is inserted with \vspace{amount},
+% instead of \vspace*{amount}. There is also a new command
+% \nounstarredvpsace that reverts to the default.
+
+%--------------------------------------------------------------------
+% Version 2.605$\beta$, 2018/08/22
+
+% We corrected the bug introduced in Version 2.604$\beta$ that caused a
+% \ref to a \correctchoice in a choices environment to have the wrong
+% value. The correction was to change \stepcounter to \refstepcounter.
+
+%--------------------------------------------------------------------
+% Version 2.604$\beta$, 2018/05/14
+
+% We changed the code for the \correctchoice command in the checkboxes
+% environment to correct a bug that causes the item label for the second
+% item to appear in the wrong place when the first item is a
+% \correctchoice and there's no text in between the \begin{checkboxes}
+% and the \correctchoice. We made a similar change to the choices
+% environment, which had the same problem.
+
+%--------------------------------------------------------------------
% Version 2.603, 2017/12/15
% No longer betatest.
@@ -4140,11 +4180,26 @@
% Motivated by the def of \leavevmode,
% \def\leavevmode{\unhbox\voidb@x}
% we will now leave hmode (if we're in hmode):
+ % 2018/05/13: We move the \item command to before the
+ % \begingroup and we also put
+ % \CorrectChoice@Emphasis\choicelabel (along with grouping)
+ % into the argument of the \item. We did this to correct
+ % the bug that appears when there is no text in between
+ % the \begin{choices} and the first item and that first
+ % item is a \correctchoice. The fact that a group had been
+ % begun before the first \item caused the label for the
+ % second item to appear in the position of the label for
+ % the item following that second item.
\ifhmode \unskip\unskip\unvbox\voidb@x \fi
+ % 2018/08/22: We changed \stepcounter to \refstepcounter:
+ \refstepcounter{choice}%
+ \item[{\color@begingroup \CorrectChoice@Emphasis
+ \choicelabel \color@endgroup}]%
\begingroup \color@begingroup \@correctchoicetrue
\CorrectChoice@Emphasis
+ \else
+ \item
\fi
- \item
\do@choice@pageinfo
} % CorrectChoice
\let\correctchoice\CorrectChoice
@@ -4237,10 +4292,20 @@
% Motivated by the def of \leavevmode,
% \def\leavevmode{\unhbox\voidb@x}
% we will now leave hmode (if we're in hmode):
+ % 2018/05/13: We move the \item[\checked@char] to before
+ % the \begingroup and we also put \CorrectChoice@Emphasis
+ % (along with grouping) into the argument of the \item. We
+ % did this to correct the bug that appears when there is no
+ % text in between the \begin{checkboxes} and the first item
+ % and that first item is a \correctchoice. The fact that a
+ % group had been begun before the first \item caused the
+ % label for the second item to appear in the position of
+ % the label for the item following that second item.
\ifhmode \unskip\unskip\unvbox\voidb@x \fi
+ \item[{\color@begingroup\CorrectChoice@Emphasis\checked@char
+ \color@endgroup}]%
\begingroup \color@begingroup \@correctchoicetrue
\CorrectChoice@Emphasis
- \item[\checked@char]
\else
\item
\fi
@@ -7176,7 +7241,6 @@
\hidden@ampersand
\hbox to \@cellwidth{\hfill}%
\else
- \hspace*{\fill}%
\if@bonus
\prt@tablebonuspoints
\else
@@ -7547,6 +7611,17 @@
\def\cancelspace{\cancelspacetrue}
\def\nocancelspace{\cancelspacefalse}
+% The command \unstarredvspace alters the solution environment so
+% that, when solutions are not being printed, any optional space will
+% be inserted with a \vspace{} command, instead of a \vspace*{}
+% command.
+
+\newif\if@unstarredvspace
+\def\unstarredvspace{\@unstarredvspacetrue}
+\def\nounstarredvspace{\@unstarredvspacefalse}
+\nounstarredvspace
+
+
% \if@insolution will be true while we're inside of any of the
% solution environments. This is used to supress \PgInfo@write and
% \label commands generated if there's a parts (or subparts, or
@@ -7579,7 +7654,11 @@
\else
\par
\penalty 0
- \vspace*{#1}%
+ \if@unstarredvspace
+ \vspace{#1}%
+ \else
+ \vspace*{#1}%
+ \fi
\fi
\setbox\z@\vbox\bgroup
\fi
diff --git a/macros/latex/contrib/exam/exam.md5 b/macros/latex/contrib/exam/exam.md5
index 38fd1b65a1..6dbd2d391e 100644
--- a/macros/latex/contrib/exam/exam.md5
+++ b/macros/latex/contrib/exam/exam.md5
@@ -1,3 +1,3 @@
-08a9755a8f51d31edf6b4124c9b710f9 exam.cls
-a9273b3443c367000e4a71b572c58a62 examdoc.pdf
-a9a481f4f36ec3dbf90ffe63f57ce803 examdoc.tex
+b210b790c86d89aeccb508074bd001ae exam.cls
+c9c5a6648a0a34ff32595455124eec6c examdoc.tex
+6de4faf2e619d56b8516369800d8a04a examdoc.pdf
diff --git a/macros/latex/contrib/exam/examdoc.pdf b/macros/latex/contrib/exam/examdoc.pdf
index 9386d25eac..fcf3b7f84b 100644
--- a/macros/latex/contrib/exam/examdoc.pdf
+++ b/macros/latex/contrib/exam/examdoc.pdf
Binary files differ
diff --git a/macros/latex/contrib/exam/examdoc.tex b/macros/latex/contrib/exam/examdoc.tex
index cbcfb377a5..579d551ae6 100644
--- a/macros/latex/contrib/exam/examdoc.tex
+++ b/macros/latex/contrib/exam/examdoc.tex
@@ -8,7 +8,7 @@
% The exam documentclass itself is in the file exam.cls.
-%%% Copyright (c) 1997, 2000, 2004, 2008, 2011, 2015, 2017
+%%% Copyright (c) 1997, 2000, 2004, 2008, 2011, 2015, 2017, 2021
% Philip S. Hirschhorn
%
% This work may be distributed and/or modified under the
@@ -47,11 +47,13 @@
% In case we're not using hyperref.sty:
\providecommand{\texorpdfstring}[2]{#1}
% The following can be used in \section commands
-% without generating pdf warnings:
+% to print a backslash (which will be omitted from the
+% pdf string) without generating pdf warnings.
+% Usage: \texttt{\bs documentclass}
\newcommand{\bs}{\texorpdfstring{\char`\\}{}}
-\newcommand{\docversion}{2.6}
-\newcommand{\docdate}{November 5, 2017}
+\newcommand{\docversion}{2.7}
+\newcommand{\docdate}{February 26, 2021}
%\newcommand{\docdate}{Draft: \today}
%--------------------------------------------------------------------
@@ -129,7 +131,8 @@
Wellesley College\\
Wellesley, MA 02481\\
psh@math.mit.edu\\[\bigskipamount]
- Copyright \copyright~1994, 1997, 2000, 2004, 2008, 2011, 2015, 2017\\
+ Copyright \copyright~1994, 1997, 2000, 2004, 2008, 2011, 2015, 2017,
+ 2021\\
Philip Hirschhorn\\
All rights reserved}
@@ -4868,9 +4871,12 @@ The six environments for solutions are divided into two types.
\index{solution environment@\texttt{solution} environment!optional argument}
%
\begin{itemize}
- \item the \verb"solution" enviroment inserts that amount of blank
+ \item the \verb"solution" environment inserts that amount of blank
space, as if you had given a \verb"\vspace*"\indc{vspace*} command
- (see section~\ref{sec:BlankSpace}),
+ (or, if you've given the command
+ \verb"\unstarredvspace"\indc{unstarredvspace}, as if you had given
+ a \verb"\vspace"\indc{vspace} command) (see
+ section~\ref{sec:BlankSpace}),
\item the \verb"solutionorbox" environment inserts an empty box of
that height, as if you had given a
\verb"\makeemptybox"\indc{makeemptybox} command (see
@@ -4890,6 +4896,15 @@ The six environments for solutions are divided into two types.
\end{itemize}
\end{itemize}
+Note that there are two commands that affect the space inserted by the
+optional argument to a \verb"solution" environment: The command
+\verb"\unstarredvspace"\indc{unstarredvspace} causes any space
+inserted by an optional argument to the \verb"solution" environment to
+be inserted using a \verb"\vspace" command, instead of the
+\verb"\vspace*" command. You can return to having such space inserted
+using a \verb"\vspace*" command by giving the command
+\verb"\nounstarredvspace"\indc{nounstarredvspace}.
+
You can use a parts, subparts, or subsubparts environment inside any
of the solution environments without having their points (if any)
counted as actual points on the exam. If there are points assigned to
@@ -5295,7 +5310,9 @@ Each of the \texttt{solution}, \texttt{solutionorbox},
\index{solution environment@\texttt{solution} environment!optional argument}
%
environment this is an amount of blank space to be left (just as if
- you had used a \verb"\vspace*"\indc{vspace*} command; see
+ you had used a \verb"\vspace*"\indc{vspace*} command (or, if you've
+ given the command \verb"\unstarredvspace"\indc{unstarredvspace}, as
+ if you had given a \verb"\vspace"\indc{vspace} command); see
section~\ref{sec:BlankSpace}) when solutions are not being printed,
\item in a
%
@@ -8768,3 +8785,8 @@ correct.
%--------------------------------------------------------------------
%--------------------------------------------------------------------
%--------------------------------------------------------------------
+
+%%% Local Variables:
+%%% mode: latex
+%%% TeX-master: t
+%%% End: