summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/ximera/src/ungraded.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/ximera/src/ungraded.dtx')
-rw-r--r--macros/latex/contrib/ximera/src/ungraded.dtx22
1 files changed, 22 insertions, 0 deletions
diff --git a/macros/latex/contrib/ximera/src/ungraded.dtx b/macros/latex/contrib/ximera/src/ungraded.dtx
new file mode 100644
index 0000000000..78b3e29738
--- /dev/null
+++ b/macros/latex/contrib/ximera/src/ungraded.dtx
@@ -0,0 +1,22 @@
+% \subsubsection{Ungraded activities}
+% \DescribeEnv{ungraded}{The |ungraded| environment is used to record
+% that certain parts of activities should not be worth points. For
+% example, if you want to use a multipleChoice as a survey question,
+% you can place it inside an |ungraded| environment.}
+% On the \LaTeX\ side, the |ungraded| environment does nothing.
+% \begin{macrocode}
+%<*classXimera>
+\newenvironment{ungraded}{}{}
+%</classXimera>
+% \end{macrocode}
+% But on the html side, |ungraded| wraps the activities in a div in
+% order to assign some weight to them for grading.
+% \begin{macrocode}
+%<*htXimera>
+\renewenvironment{ungraded}{%
+\ifvmode \IgnorePar\fi \EndP\HCode{<div class="ungraded">}\IgnoreIndent%
+}{
+\ifvmode \IgnorePar\fi \EndP\HCode{</div>}\IgnoreIndent%
+}
+%</htXimera>
+% \end{macrocode}