summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/randexam
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2024-07-09 20:04:54 +0000
committerKarl Berry <karl@freefriends.org>2024-07-09 20:04:54 +0000
commitd04b314526ec59cf706b894571225d080746fe83 (patch)
treef3d2d0fb213d8335f11aaaff2b51e7b219cd0d3c /Master/texmf-dist/tex/latex/randexam
parent63b951db329c5bee585d306fb234621cb8370a9e (diff)
randexam (9jul24)
git-svn-id: svn://tug.org/texlive/trunk@71754 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/randexam')
-rw-r--r--Master/texmf-dist/tex/latex/randexam/randexam.cls13
1 files changed, 11 insertions, 2 deletions
diff --git a/Master/texmf-dist/tex/latex/randexam/randexam.cls b/Master/texmf-dist/tex/latex/randexam/randexam.cls
index ec5d1c43c27..dacc079cb0a 100644
--- a/Master/texmf-dist/tex/latex/randexam/randexam.cls
+++ b/Master/texmf-dist/tex/latex/randexam/randexam.cls
@@ -6,7 +6,7 @@
% ----------------------------------------------------------------------------
\NeedsTeXFormat{LaTeX2e}
-\ProvidesClass{randexam}[2024-02-18 v2024E Make an exam paper and its randomized variants]
+\ProvidesClass{randexam}[2024-07-09 v2024F Make an exam paper and its randomized variants]
%% Old LaTeX release could not recognize date format like 2022-11-01
%\@ifl@t@r\fmtversion{2022-11-01}{}{
@@ -786,7 +786,8 @@
\UseExamTemplate{examdata}{default}
}
-\preto{\@enddocumenthook}{\printquestions\rdxm@stop@random}
+%% this equals to \AddToHook{enddocument}[randexam]{...}
+\AtEndDocument{\printquestions\rdxm@stop@random}
\newcommand\ignorepars{\@ifnextchar\par{\expandafter\ignorepars\@gobble}{}}
@@ -1228,6 +1229,11 @@
\mbox{}\nobreak\hfill$\cdots\cdots$\solutionpointstext{#1}
\par\noindent\ignorespaces
}
+
+%% \eqno would cause extra space after a $$...$$ equation
+%% this bug was fixed in latex release 2023-06-01
+%% see https://github.com/latex3/latex2e/issues/1059
+%% \tag is used in a \[...\] equation hence no problem with it
\newcommand{\pointseqno}[1]{\eqno{\cdots\cdots\text{\solutionpointstext{#1}}}}
\newcommand{\pointstag}[1]{\tag*{$\cdots\cdots$\solutionpointstext{#1}}}
@@ -1374,6 +1380,9 @@
\RequirePackage{extarrows}
\newcommand{\e}{\mathrm{e}}
\newcommand{\R}{\mathbb{R}}
+ \newcommand{\jacobi}[2]{{\left(\frac{##1}{##2}\right)}}
+ \newcommand{\ii}{\mathrm{i}}
+ \newcommand{\Zi}{\mathbb{Z}[\ii]}
\DeclareMathOperator{\arccot}{arccot}
\DeclareMathOperator{\Corr}{\rho}
\DeclareMathOperator{\Cov}{Cov}