diff --git a/ouexam.dtx b/ouexam.dtx index 8d62a4f..9672b7a 100644 --- a/ouexam.dtx +++ b/ouexam.dtx @@ -1,6 +1,6 @@ -\def\ouexamdate{15 September 2014} -\def\ouexamversion{2.3.1} -\def\ouexamshortdate{2014/09/15} +\def\ouexamdate{9 October 2014} +\def\ouexamversion{2.3.2} +\def\ouexamshortdate{2014/10/09} % \iffalse meta-comment %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% @@ -36,7 +36,7 @@ % % \fi % -%% \CheckSum{889} +%% \CheckSum{892} %% %% \CharacterTable %% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z @@ -1386,6 +1386,8 @@ % placement of marks in output.} % \changes{2.0}{2001/05/15}{NJS Total marks for a question are now printed only % if the question has no sub-questions.} +% \changes{2.3.2}{2014/10/09}{NJS Fixed crashing bug with verbatim environments +% appearing at the end of questions.} % \begin{environment}{question} % The \textsf{question} environment specifies a top-level question, and produces % questions numbered in the form ``1.'', ``2.'', etc. It has one mandatory @@ -1436,7 +1438,7 @@ % 106 of \emph{The \TeX{}book}: % % \begin{macrocode} - \unskip\nobreak\hfil\penalty50\hskip2em\hbox{}\nobreak% + \vskip-\lastskip\nobreak\hfil\penalty50\hskip2em\hbox{}\nobreak% \hfil(\theqrunning~\ifnum\theqrunning=1 mark\else marks\fi)% \parfillskip=0pt \finalhyphendemerits=0 \par% % \end{macrocode} @@ -1474,6 +1476,8 @@ % redefinition of \textsf{enumerate}.} % \changes{2.0}{2001/05/13}{NJS Added penalty handling to ensure correct placement % of marks in output.} +% \changes{2.3.2}{2014/10/09}{NJS Fixed crashing bug with verbatim environments +% appearing at the end of subquestions.} % The \textsf{subquestion} environment is the analogue of \textsf{question} for % sub-questions. On initialisation, it sets |subqexpected| to the value of the % mandatory argument (defaulting to zero if the argument is empty), increments @@ -1509,7 +1513,7 @@ % Then the number of marks for the sub-question are typeset in a similar manner % to the \textsf{question} environment: % \begin{macrocode} - \unskip\nobreak\hfil\penalty50\hskip2em\hbox{}\nobreak% + \vskip-\lastskip\nobreak\hfil\penalty50\hskip2em\hbox{}\nobreak% \hfil(\thesubqrunning~\ifnum\thesubqrunning=1 mark\else marks\fi)% \parfillskip=0pt \finalhyphendemerits=0 \par% % \end{macrocode} @@ -1539,6 +1543,8 @@ % redefinition of \textsf{enumerate}.} % \changes{2.0}{2001/05/13}{NJS Added penalty handling to ensure correct placement % of marks in output.} +% \changes{2.3.2}{2014/10/09}{NJS Fixed crashing bug with verbatim environments +% appearing at the end of subsubquestions.} % This is similar to both \textsf{question} and \textsf{subquestion}, and % generates an appropriately numbered sub-sub-question (``(i)'', ``(ii)'', etc.). % \begin{macrocode} @@ -1568,7 +1574,7 @@ \addtocounter{qrunning}{\value{subsubqexpected}}% \addtocounter{subqrunning}{\value{subsubqexpected}}% \setcounter{lastexpected}{\value{subsubqexpected}}% - \unskip\nobreak\hfil\penalty50\hskip2em\hbox{}\nobreak% + \vskip-\lastskip\nobreak\hfil\penalty50\hskip2em\hbox{}\nobreak% \hfil(\thesubsubqexpected~\ifnum\thesubsubqexpected=1 mark% \else marks\fi)% \parfillskip=0pt \finalhyphendemerits=0 \par%