diff --git a/ouexam.dtx b/ouexam.dtx index cf76ee7..02b823c 100644 --- a/ouexam.dtx +++ b/ouexam.dtx @@ -1,6 +1,6 @@ -\def\ouexamdate{25 August 2016} +\def\ouexamdate{26 August 2016} \def\ouexamversion{2.4} -\def\ouexamshortdate{2016/08/25} +\def\ouexamshortdate{2016/08/26} % \iffalse meta-comment %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% @@ -36,7 +36,7 @@ % % \fi % -%% \CheckSum{1068} +%% \CheckSum{1090} %% %% \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 @@ -155,6 +155,9 @@ % Palatino. However, if this is not available, they will accept 13pt Times % instead. The \textsf{times} class option enables the latter, but should % only be used if Palatino is not available. +% +% \item[\textsf{embargo}] \DescribeMacro{embargo} +% Specify this option if the examination paper is to be embargoed. This will add a field for the candidate to enter their student ID in the top right of the title page, and automatically insert an instruction under ``other instructions'' to hand in the entire examination paper. % \end{description} % % @@ -997,6 +1000,19 @@ % \end{macro} % \end{macro} % +% \begin{macro}{embargo} +% \changes{2.4}{2016/09/26}{NJS New \textsf{embargo} class option.} +% \begin{macro}{\if@embargo} +% \changes{2.4}{2016/09/26}{NJS New switch for \textsf{embargo}.} +% Specify the \textsf{embargo} option if the exam paper is to be embargoed. This will print a field for the candidate to enter their student ID in the top right corner of the title page, and add relevant text to the other instructions section of the title page. +% +% \begin{macrocode} +\newif\if@embargo \@embargofalse +\DeclareOption{embargo}{\@embargotrue} +% \end{macrocode} +% \end{macro} +% \end{macro} +% % All other options are passed directly to the \textsf{article} class: % % \begin{macrocode} @@ -1253,6 +1269,7 @@ % \changes{2.1.1}{2006/08/21}{NJS Updated \textsf{lastpage} style to display ``\textbf{END}''.} % \changes{2.3}{2012/09/03}{NJS Rearranged headers and footers to conform to the latest formatting requirements. Swapped \fbox{MARKING SCHEDULE} and \fbox{DRAFT} between header and footer so that the page number doesn't get overprinted.} % \changes{2.4}{2013/06/06}{NJS Replaced the \textsf{lastpage} page style with direct manipulation of the footer contents in the \textsf{plain} page style, as \cs{pagestyle} and \cs{thispagestyle} don't affect automatically generated float pages on the last page of the document.} +% \changes{2.4}{2016/08/26}{NJS Added support to \textsf{titlepage} page style for new \textsf{embargo} class option.} % %\begin{macro}{\if@lastpagetext} %\begin{macro}{\if@lastpagefloat} @@ -1343,10 +1360,13 @@ % \end{macrocode} % % \begin{macro}{\ps@titlepage} -% The \textsf{titlepage} page style is similar to \textsf{plain}, but without the header. +% The \textsf{titlepage} page style is similar to \textsf{plain}, but without the header. If the exam is embargoed, insert a field for the candidate to write in their student ID in the top right corner. % \begin{macrocode} \def\ps@titlepage{% - \def\@oddhead{\@markingschedule}% + \def\@oddhead{% + \@markingschedule% + \if@embargo\hfill\large\textbf{Student ID:} \rule{4cm}{0.8pt}\fi% + }% \let\@evenhead\@oddhead% \def\@oddfoot{\@draft\hfill\textbf{TURN OVER}}% \let\@evenfoot\@oddfoot% @@ -2387,11 +2407,19 @@ \fi% % \end{macrocode} % \changes{2.1.3}{2009/04/28}{NJS Removed superfluous blank line.} -% Print out other instructions, and finish. +% \changes{2.4}{2016/08/26}{NJS Added instruction for embargoed exams.} +% Print out other instructions, and finish. Automatically insert an instruction to hand in the entire exam if it's embargoed. % \begin{macrocode} \underline{Other Instructions:}% \\[\baselineskip]% - \hspace*{1cm}\begin{minipage}{13.5cm}\@otherinst\end{minipage}% + \hspace*{1cm}% + \begin{minipage}{13.5cm}% + \if@embargo% + Hand in entire exam attached to answer book(s).% + \ifx\@otherinst\@NA\else \\ \@otherinst\fi% + \else\@otherinst% + \fi% + \end{minipage}% \newpage% }