From 7f23e7cb61bff0bc73f418a613d78ce34bd2b7c5 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Sun, 11 Feb 2024 21:25:42 +0000 Subject: exam-zh (11feb24) git-svn-id: svn://tug.org/texlive/trunk@69802 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/doc/xelatex/exam-zh/CHANGELOG.md | 31 +++++ .../xelatex/exam-zh/doc/back/main-changelog.tex | 1 + .../doc/xelatex/exam-zh/doc/body/usage.tex | 143 +++++++++++++++++++-- .../doc/xelatex/exam-zh/doc/exam-zh-doc-setup.tex | 6 +- .../doc/xelatex/exam-zh/doc/exam-zh-doc.pdf | Bin 1595273 -> 1607182 bytes .../doc/xelatex/exam-zh/doc/exam-zh-doc.tex | 47 +++---- .../xelatex/exam-zh/examples/example-multiple.pdf | Bin 160210 -> 160276 bytes .../xelatex/exam-zh/examples/example-single.pdf | Bin 134928 -> 148041 bytes .../xelatex/exam-zh/examples/example-single.tex | 16 +-- 9 files changed, 197 insertions(+), 47 deletions(-) (limited to 'Master/texmf-dist/doc/xelatex') diff --git a/Master/texmf-dist/doc/xelatex/exam-zh/CHANGELOG.md b/Master/texmf-dist/doc/xelatex/exam-zh/CHANGELOG.md index 9fba646315c..cd4627352f5 100644 --- a/Master/texmf-dist/doc/xelatex/exam-zh/CHANGELOG.md +++ b/Master/texmf-dist/doc/xelatex/exam-zh/CHANGELOG.md @@ -5,6 +5,37 @@ 格式参照 [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), 并且此项目遵守 [Semantic Versioning](https://semver.org/spec/v2.0.0.html)。 +## [0.2.1] - 2024-02-11 + +### Added + +- 增加答案控制功能 +- 增加计算题排版环境 `calculations` + +### Fixed + +- 修复 `section` 的超链接问题 + + +## [0.1.29] - 2024-02-07 + +### Added + +- 增加 `fig-pos` 的同义选项 `pos` + +### Changed + +- 修改 `textfigure` 的选项的一些默认值 + + + +## [0.1.28] - 2023-07-14 + +### Changed + +- 修改 `\paren` 的宽度细节 + + ## [0.1.27] - 2023-06-27 ### Added diff --git a/Master/texmf-dist/doc/xelatex/exam-zh/doc/back/main-changelog.tex b/Master/texmf-dist/doc/xelatex/exam-zh/doc/back/main-changelog.tex index f3a51e79e1b..1b339b2a649 100644 --- a/Master/texmf-dist/doc/xelatex/exam-zh/doc/back/main-changelog.tex +++ b/Master/texmf-dist/doc/xelatex/exam-zh/doc/back/main-changelog.tex @@ -8,4 +8,5 @@ \item 2022.6 开发密封线、草稿纸、评分框 \item 2022.7 增加语文英语题型 \item 2022.8 开发图文排版模版 + \item 2024.2 发布答案控制功能、计算题排版功能 \end{itemize} \ No newline at end of file diff --git a/Master/texmf-dist/doc/xelatex/exam-zh/doc/body/usage.tex b/Master/texmf-dist/doc/xelatex/exam-zh/doc/body/usage.tex index 9d1191f76ba..85566213f4b 100644 --- a/Master/texmf-dist/doc/xelatex/exam-zh/doc/body/usage.tex +++ b/Master/texmf-dist/doc/xelatex/exam-zh/doc/body/usage.tex @@ -20,6 +20,9 @@ 按照~\ref{subsec:编译方式} 小节中的方式编译,您应当得到一篇 1 页的文档。 +注意,如果您要在 Overleaf 或者 TeXPage 等在线编辑器上使用 \cls{exam-zh},请在 \verb|\documentclass{exam-zh}| 前加一行代码:\verb|\let\stop\empty|. + + \subsection{编译方式} \label{subsec:编译方式} 本模板不支持 \pdfTeX{} 引擎,仅支持使用 \XeLaTeX{} 。为了生成正确的目录、脚注以及交叉引用,您至少需要连续编译两次。 @@ -570,11 +573,11 @@ 下面所有和 \env{solution} 有关的示例都默认加载了 \begin{latexcode} - \examsetup{solution/show-solution = true} + \examsetup{solution/show-solution = show-stay} \end{latexcode} \examsetup{ - solution/show-solution=true + solution/show-solution=show-stay } @@ -854,7 +857,7 @@ \geometry{showframe} ]{ page/size=a3paper, - solution/show-solution=true, + solution/show-solution=show-stay, paren/show-paren=true, paren/show-answer=true } @@ -1006,6 +1009,40 @@ \end{latexcode} 将用户设置放在 \cls{exam-zh} 的默认设置后从而使其产生作用。 + +\subsubsection{数学-计算题排版} + +\begin{function}[added = 2024-02-11]{calculations 环境} + \begin{ccnusyntax}[emph={[2]calculations}] + \begin{calculations}(*\oarg{键值列表}*) + \item (*\meta{内容1}*) + \item (*\meta{内容2}*) + ... + \end{calculations} + \end{ccnusyntax} + 计算题排版环境。用户可根据效果实现更多应用。\oarg{键值列表} 见~\ref{subsubsec:参数-计算题排版} 节。 +\end{function} + +\begin{latexexample}{\env{calculations} 环境示例} + \begin{calculations}[ + % index = 3, % 从 3 开始编号 + label = \arabic*., % 样式,和 question 环境的一样 + columns = 2, % 每行多少项 + hsep = 0pt, % 两列之间的间距 + vsep = 4cm % 两行之间的间距 + ] + \item + $(-10) + \dfrac{1}{3} - (-3)$ + \item(5分) + $(-10) + 5 - (-3)$ + \item + $(-10) + 5 - (-3)$ + \item(5分) + $(-10) + 5 - (-3)$ + \end{calculations} +\end{latexexample} + + \subsection{参数设置} \begin{function}{\examsetup} @@ -1195,9 +1232,9 @@ \end{ccnusyntax} 页脚内容设置。 \begin{itemize} - \item 若\meta{页脚格式} 中不含西文分号 |;|,则页脚内容为 \meta{页脚格式} 直接输出; - \item 若\meta{页脚格式} 中含一个西文分号 |;|,如 |foo;bar|,则页脚为 |foobar|,即西文分号代替了页码的位置; - \item 若\meta{页脚格式} 中含两个西文分号 |;|,如 |foo;bar;baz|,则页脚为 |foobarbaz|,即第一个西文分号代替了页码的位置,第二个代替了总页码。 + \item 若 \meta{页脚格式} 中不含西文分号 |;|,则页脚内容为 \meta{页脚格式} 直接输出; + \item 若 \meta{页脚格式} 中含一个西文分号 |;|,如 |foo;bar|,则页脚为 |foobar|,即西文分号代替了页码的位置; + \item 若 \meta{页脚格式} 中含两个西文分号 |;|,如 |foo;bar;baz|,则页脚为 \\|foobarbaz|,即第一个西文分号代替了页码的位置,第二个代替了总页码。 \end{itemize} \end{function} @@ -2193,9 +2230,9 @@ \fillin[width-type = normal, width = 1.1\linewidth][答案] 测试 \end{latexexample} -\begin{function}[added = 2022-07-15]{fillin/color} +\begin{function}[added = 2022-07-15, updated = 2023-07-03]{fillin/box-color} \begin{ccnusyntax}[emph={[1]color}] - color = (*\meta{color}*) + box-color = (*\meta{color}*) \end{ccnusyntax} 设置 \kvopt{fillin/type}{circle/rectangle} 类型的 \tn{fillin} 的边框颜色。 \end{function} @@ -2228,12 +2265,11 @@ \end{function} -\begin{function}[added = 2022-07-01,updated = 2022-08-17]{solution/show-solution,solution/show-answer} - \begin{ccnusyntax}[emph={[1]show-solution,show-answer}] - show-solution = (*\TTF*) - show-answer = (*\TTF*) +\begin{function}[added = 2022-07-01,updated = 2024-02-11]{solution/show-solution} + \begin{ccnusyntax}[emph={[1]show-solution}] + show-solution = (*<(show-hide)|show-stay|show-move>*) \end{ccnusyntax} - 是否显示解答环境 \env{solution} 的内容。\opt{show-solution} 和 \opt{show-answer} 两者等效。 + 是否显示或移动解答环境 \env{solution} 的内容。\opt{show-hide} 表示隐藏,\opt{show-stay} 表示显示在原处,\opt{show-move} 表示显示在章节最后。 \end{function} \begin{function}[added = 2022-07-20]{solution/parbreak} @@ -2983,4 +3019,85 @@ parindent = (*\meta{dimension}*) \end{ccnusyntax} 文本部分的缩进长度,默认为 |2em|。 +\end{function} + + +\subsubsection{数学-计算题排版环境} \label{subsubsec:参数-计算题排版} + +\begin{function}[updated = 2024-02-11]{calculations} + \begin{ccnusyntax}[emph={[1]calculations}] + calculations = (*\marg{键值列表}*) + calculations/(*\meta{key}*) = (*\meta{value}*) + \end{ccnusyntax} + 该选项包含多个子项目。用于设置 \env{calculations} 环境。可以在 \tn{examsetup} 中使用,也可以在 \env{calculations} 环境的可选参数中使用。 +\end{function} + +\begin{function}[added = 2024-02-11]{calculations/index} + \begin{ccnusyntax}[emph={[1]index}] + index = (*\meta{integer}*) + \end{ccnusyntax} + 第一个题干的序号。默认为 |1|。 +\end{function} + +\begin{function}[added = 2024-02-11]{calculations/columns} + \begin{ccnusyntax}[emph={[1]columns}] + columns = (*\meta{integer}*) + \end{ccnusyntax} + 每行多少项。默认为 |2|。 +\end{function} + +\begin{function}[added = 2024-02-11]{calculations/fig-pos} + \begin{ccnusyntax}[emph={[1]fig-pos}] + fig-pos = (**) + \end{ccnusyntax} + 题干相对于标签的位置。\opt{top} 和 \opt{above} 同义、\opt{bottom} 和 \opt{below} 同义。 +\end{function} + +\begin{function}[added = 2024-02-11]{calculations/top-sep} + \begin{ccnusyntax}[emph={[1]top-sep}] + top-sep = (*\meta{dimension}*) + \end{ccnusyntax} + \env{calculations} 环境上方额外弹性间距。默认为 |1ex plus .5ex minus .5ex|。 +\end{function} + +\begin{function}[added = 2024-02-11]{calculations/bottom-sep} + \begin{ccnusyntax}[emph={[1]bottom-sep}] + bottom-sep = (*\meta{dimension}*) + \end{ccnusyntax} + \env{calculations} 环境下方额外弹性间距。默认为 |0pt|。 +\end{function} + +\begin{function}[added = 2024-02-11]{calculations/hsep,calculations/vsep} + \begin{ccnusyntax}[emph={[1]hsep,vsep}] + hsep = (*\meta{dimension}*) + vsep = (*\meta{dimension}*) + \end{ccnusyntax} + \opt{hsep} 表示题干之间的水平间距,\opt{vsep} 表示题干之间的垂直间距。\opt{hsep} 默认为 |2em|,\opt{vsep} 默认为 |0em|。 +\end{function} + +\begin{function}[added = 2024-02-11]{calculations/align} + \begin{ccnusyntax}[emph={[1]align}] + align = (*<(t)|m|b>*) + \end{ccnusyntax} + 题干和标签的整体对齐方式。\opt{t} 表示顶部对齐、\opt{m} 表示居中对齐、\opt{b} 表示底部对齐。 +\end{function} + +\begin{function}[added = 2024-02-11]{calculations/xshift,calculations/hshift,calculations/yshift,calculations/vshift} + \begin{ccnusyntax}[emph={[1]xshift,hshift,yshift,vshift}] + xshift = (*\meta{dimension}*) + hshift = (*\meta{dimension}*) + yshift = (*\meta{dimension}*) + vshift = (*\meta{dimension}*) + \end{ccnusyntax} + 题干和标签整体的水平和垂直的偏移量。\opt{xshift} 和 \opt{hshift} 同义,表示水平;\opt{yshift} 和 \opt{vshift} 同义,表示垂直。 +\end{function} + +\begin{function}[added = 2024-02-11]{calculations/label-xshift,calculations/label-hshift,calculations/label-yshift,calculations/label-vshift} + \begin{ccnusyntax}[emph={[1]xshift,hshift,yshift,vshift}] + label-xshift = (*\meta{dimension}*) + label-hshift = (*\meta{dimension}*) + label-yshift = (*\meta{dimension}*) + label-vshift = (*\meta{dimension}*) + \end{ccnusyntax} + 标签相对题干的水平和垂直的偏移量。\opt{label-xshift} 和 \opt{label-hshift} 同义,表示水平;\opt{label-yshift} 和 \opt{label-vshift} 同义,表示垂直。 \end{function} \ No newline at end of file diff --git a/Master/texmf-dist/doc/xelatex/exam-zh/doc/exam-zh-doc-setup.tex b/Master/texmf-dist/doc/xelatex/exam-zh/doc/exam-zh-doc-setup.tex index 9a1f2a68443..d67b599cee9 100644 --- a/Master/texmf-dist/doc/xelatex/exam-zh/doc/exam-zh-doc-setup.tex +++ b/Master/texmf-dist/doc/xelatex/exam-zh/doc/exam-zh-doc-setup.tex @@ -7,6 +7,7 @@ \usepackage{../exam-zh-symbols} \usepackage{../exam-zh-chinese-english} \usepackage{../exam-zh-textfigure} +\usepackage{../exam-zh-math} \ExplSyntaxOn \NewDocumentCommand \examsetup { m } @@ -32,7 +33,10 @@ \title{\textcolor{MaterialIndigo800}{% \textbf{exam-zh: 中国试卷 \LaTeX \xpinyin[font=\sffamily,format=\color{MaterialIndigo800}]{模}{mu2}板}}} -\author{李泽平,夏康玮,郭李军} +\author{% + 夏康玮\thanks{% + 李泽平构建了 \cls{exam-zh} 的最初的基本框架;郭李军开发了连线题环境} +} \date{\DocDate\quad \DocVersion% \thanks{% \url{https://gitee.com/xkwxdyy/exam-zh} \\ diff --git a/Master/texmf-dist/doc/xelatex/exam-zh/doc/exam-zh-doc.pdf b/Master/texmf-dist/doc/xelatex/exam-zh/doc/exam-zh-doc.pdf index 513f8d06a0f..734be0a38fc 100644 Binary files a/Master/texmf-dist/doc/xelatex/exam-zh/doc/exam-zh-doc.pdf and b/Master/texmf-dist/doc/xelatex/exam-zh/doc/exam-zh-doc.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/exam-zh/doc/exam-zh-doc.tex b/Master/texmf-dist/doc/xelatex/exam-zh/doc/exam-zh-doc.tex index b8eb07a3a68..6beca867a6a 100644 --- a/Master/texmf-dist/doc/xelatex/exam-zh/doc/exam-zh-doc.tex +++ b/Master/texmf-dist/doc/xelatex/exam-zh/doc/exam-zh-doc.tex @@ -1,7 +1,7 @@ \documentclass{xdyydoc} -\newcommand{\DocDate}{2022-10-4} -\newcommand{\DocVersion}{v0.1.27} +\newcommand{\DocDate}{2024-02-11} +\newcommand{\DocVersion}{v0.2.1} \input{exam-zh-doc-setup.tex} \usepackage{amssymb} @@ -61,28 +61,28 @@ \begin{itemize} % \item 增加试卷范例(语文,英语) - \item 答案控制 - \begin{itemize} - \item 选择题 - \begin{itemize} - \item 题目下方 - \item 括号内 - \item 最后:列表形式、表格形式 - \end{itemize} - \item 填空题 - \begin{itemize} - \item 题目下方 - \item 划线内 - \item 最后 - \end{itemize} - \item 解答题 - \begin{itemize} - \item 题目下方 - \item 移动到最后 - \end{itemize} - \end{itemize} + % \item 答案控制 + % \begin{itemize} + % \item 选择题 + % \begin{itemize} + % \item 题目下方 + % \item 括号内 + % \item 最后:列表形式、表格形式 + % \end{itemize} + % \item 填空题 + % \begin{itemize} + % \item 题目下方 + % \item 划线内 + % \item 最后 + % \end{itemize} + % \item 解答题 + % \begin{itemize} + % \item 题目下方 + % \item 移动到最后 + % \end{itemize} + % \end{itemize} \item 选择题答案标记 - \item \env{choices} 环境“均分”效果 + % \item \env{choices} 环境“均分”效果 % \item 图文排版(参考 xkwxdyy 的 \pkg{text-figure} 宏包和 qinglee 的 \pkg{wrapstuff} 宏包) \item 测试兼容性 \item \env{question} 环境的引用 @@ -95,6 +95,7 @@ \item 通过 \tn{CJKunderline} 的 \meta{hidden} 键实现 \tn{fillin} 的无答案的时候,长度是答案的长度 \item \env{poem} 环境的引用字体不是斜体 \item 用 meta 优化键值,比如统一的 show-answer + \item 设置 \tn{vec} 命令的定制开关。 \end{itemize} diff --git a/Master/texmf-dist/doc/xelatex/exam-zh/examples/example-multiple.pdf b/Master/texmf-dist/doc/xelatex/exam-zh/examples/example-multiple.pdf index e6b4c80c25d..29b1dc48833 100644 Binary files a/Master/texmf-dist/doc/xelatex/exam-zh/examples/example-multiple.pdf and b/Master/texmf-dist/doc/xelatex/exam-zh/examples/example-multiple.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/exam-zh/examples/example-single.pdf b/Master/texmf-dist/doc/xelatex/exam-zh/examples/example-single.pdf index 66c7da9b6ed..1ecd7749c5c 100644 Binary files a/Master/texmf-dist/doc/xelatex/exam-zh/examples/example-single.pdf and b/Master/texmf-dist/doc/xelatex/exam-zh/examples/example-single.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/exam-zh/examples/example-single.tex b/Master/texmf-dist/doc/xelatex/exam-zh/examples/example-single.tex index 4a9e7e30335..d2f1506c264 100644 --- a/Master/texmf-dist/doc/xelatex/exam-zh/examples/example-single.tex +++ b/Master/texmf-dist/doc/xelatex/exam-zh/examples/example-single.tex @@ -6,15 +6,7 @@ paren/show-paren=true, paren/show-answer=true, fillin/show-answer=false, - solution/show-solution=false -} - -\ExamPrintAnswerSet{ - sealline/show=true, - page/size=a3paper, - paren/show-answer=false, - fillin/show-answer=false, - solution/show-solution=false, + solution/show-solution=show-move } @@ -60,7 +52,7 @@ % 1. \begin{question}[points = 2] - 设集合 $A = \{x \mid -1 < x < 4\}$,$B = \{2, 3, 4, 5\}$,则 $A \cap B = $ \paren[B] + 设集合 $A = \{x \mid -1 < x < 4\}$,$B = \{2, 3, 4, 5\}$,则 $A \cap B = $ \paren[A] \begin{choices} \item $\{2\}$ @@ -222,6 +214,10 @@ 已知函数 $f(x) = x^3 (a \cdot 2^x - 2^{-x})$ 是偶函数,则 $a = $ \fillin[$1$] 。 \end{question} +\begin{solution} + 由 $f(x) = f(-x)$,得 $a = 1$。 +\end{solution} + % 14. \begin{question} 已知 $O$ 为坐标原点,抛物线 $C \colon y^2 = 2px$($p > 0$)的焦点为 $F$, -- cgit v1.2.3