texlive[57334] Master/texmf-dist: moodle (5jan21)

commits+karl at tug.org commits+karl at tug.org
Tue Jan 5 23:05:39 CET 2021


Revision: 57334
          http://tug.org/svn/texlive?view=revision&revision=57334
Author:   karl
Date:     2021-01-05 23:05:39 +0100 (Tue, 05 Jan 2021)
Log Message:
-----------
moodle (5jan21)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/moodle/README.md
    trunk/Master/texmf-dist/doc/latex/moodle/moodle.pdf
    trunk/Master/texmf-dist/source/latex/moodle/moodle.dtx
    trunk/Master/texmf-dist/source/latex/moodle/moodle.ins
    trunk/Master/texmf-dist/tex/latex/moodle/moodle.sty

Added Paths:
-----------
    trunk/Master/texmf-dist/doc/latex/moodle/LICENSE
    trunk/Master/texmf-dist/doc/latex/moodle/test/
    trunk/Master/texmf-dist/doc/latex/moodle/test/fig/
    trunk/Master/texmf-dist/doc/latex/moodle/test/fig/11.PNG
    trunk/Master/texmf-dist/doc/latex/moodle/test/fig/22.pdf
    trunk/Master/texmf-dist/doc/latex/moodle/test/fig/3.gif
    trunk/Master/texmf-dist/doc/latex/moodle/test/fig/4.jpg
    trunk/Master/texmf-dist/doc/latex/moodle/test/fig/5.jpeg
    trunk/Master/texmf-dist/doc/latex/moodle/test/fig/MoodlE_logo.SVG
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_autopoints-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_calculated_python-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_categories-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_circuitikz-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_cloze_multi-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_cloze_numerical-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_cloze_shortanswer-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_commands-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_description-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_environments-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_escaping_right_braces_in_cloze-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_essay-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_expandnewcommands-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_fancyvrb-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_fractions-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_french-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_generalfeedback-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_handout-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics_via_tikz-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics_via_tikz_and_svg-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics_with_svg-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_macros-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_matching-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_mathenv-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_minted-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_multi-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_multiple_categories-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_penalty-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_point_points-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_special_characters-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tags-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tikz-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tikz_with_svg-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tolerance-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_truefalse-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_verbatim-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/makefile
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_autopoints.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_calculated_lua.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_calculated_python.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_categories.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_circuitikz.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_multi.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_numerical.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_shortanswer.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_commands.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_description.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_environments.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_escaping_right_braces_in_cloze.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_essay.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_expandnewcommands.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_fancyvrb.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_fractions.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_french.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_generalfeedback.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_handout.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_via_tikz.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_via_tikz_and_svg.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_with_svg.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_macros.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_matching.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_mathenv.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_minted.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_multi.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_multiple_categories.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_penalty.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_point_points.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_special_characters.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_tags.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_tikz.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_tikz_with_svg.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_tolerance.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_truefalse.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/test_verbatim.tex
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_autopoints-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_calculated_lua-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_calculated_python-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_categories-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_circuitikz-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_cloze_multi-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_cloze_numerical-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_cloze_shortanswer-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_commands-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_description-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_environments-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_escaping_right_braces_in_cloze-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_essay-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_expandnewcommands-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_fancyvrb-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_fractions-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_french-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_generalfeedback-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_handout-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics_via_tikz-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics_via_tikz_and_svg-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics_with_svg-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_macros-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_matching-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_mathenv-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_minted-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_multi-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_multiple_categories-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_penalty-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_point_points-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_special_characters-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tags-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tikz-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tikz_with_svg-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tolerance-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_truefalse-moodle.ref
    trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_verbatim-moodle.ref
    trunk/Master/texmf-dist/source/latex/moodle/makefile

Added: trunk/Master/texmf-dist/doc/latex/moodle/LICENSE
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/LICENSE	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/LICENSE	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,13 @@
+Copyright 2016 by Anders O.F. Hendrickson (anders.o.f.hendrickson AT gmail.com)
+and 2019-2021 by Matthieu Guerquin-Kern (guerquin-kern AT crans.org).
+This work may be distributed and/or modified under the conditions of the LaTeX
+Project Public License, either version 1.3 of this license or (at your option)
+any later version.
+
+The latest version of this license is in http://www.latex-project.org/lppl.txt
+and version 1.3 or later is part of all distributions of LaTeX version
+2005/12/01 or later.
+
+This work has the LPPL maintenance status `maintained'. 
+
+The Current Maintainer of this work is Matthieu Guerquin-Kern.

Modified: trunk/Master/texmf-dist/doc/latex/moodle/README.md
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/doc/latex/moodle/moodle.pdf
===================================================================
(Binary files differ)

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/11.PNG
===================================================================
(Binary files differ)

Index: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/11.PNG
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/fig/11.PNG	2021-01-05 22:04:49 UTC (rev 57333)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/fig/11.PNG	2021-01-05 22:05:39 UTC (rev 57334)

Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/11.PNG
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/22.pdf
===================================================================
(Binary files differ)

Index: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/22.pdf
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/fig/22.pdf	2021-01-05 22:04:49 UTC (rev 57333)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/fig/22.pdf	2021-01-05 22:05:39 UTC (rev 57334)

Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/22.pdf
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/pdf
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/3.gif
===================================================================
(Binary files differ)

Index: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/3.gif
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/fig/3.gif	2021-01-05 22:04:49 UTC (rev 57333)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/fig/3.gif	2021-01-05 22:05:39 UTC (rev 57334)

Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/3.gif
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/4.jpg
===================================================================
(Binary files differ)

Index: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/4.jpg
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/fig/4.jpg	2021-01-05 22:04:49 UTC (rev 57333)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/fig/4.jpg	2021-01-05 22:05:39 UTC (rev 57334)

Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/4.jpg
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/5.jpeg
===================================================================
(Binary files differ)

Index: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/5.jpeg
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/fig/5.jpeg	2021-01-05 22:04:49 UTC (rev 57333)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/fig/5.jpeg	2021-01-05 22:05:39 UTC (rev 57334)

Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/5.jpeg
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/fig/MoodlE_logo.SVG
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/fig/MoodlE_logo.SVG	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/fig/MoodlE_logo.SVG	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg version="1.1" viewBox="0 0 327 100" xmlns="http://www.w3.org/2000/svg">
+<g fill="#f98012">
+<path d="m72.4 77.45v-27.07c0-5.65-2.35-8.5-7-8.5-4.674 0-7.024 2.826-7.024 8.5v27.07h-13.77v-27.07c0-5.65-2.301-8.5-6.899-8.5-4.676 0-7 2.826-7 8.5v27.07h-13.78v-28.68c0-5.9 2.051-10.37 6.151-13.4 3.599-2.701 8.5-4.076 14.65-4.076 6.225 0 10.82 1.6 13.77 4.801 2.549-3.201 7.174-4.801 13.9-4.801 6.15 0 11.02 1.35 14.62 4.076 4.1 3.025 6.15 7.5 6.15 13.4v28.68z"/>
+<path d="m136.1 22.75-3.094-2.117-7.492 12.05c-5.375-1.792-10.59-1.792-11.56-1.792-17.1 0-26.55 10.59-26.55 24.43 0 6.351 2.443 14.98 11.73 19.87l-7.328 11.89 3.095 1.954 7.653-12.21c5.212 1.792 10.1 1.792 11.4 1.792 17.43 0 26.55-10.59 26.55-23.29 0-7.98-3.421-16.45-11.73-20.85zm-33.71 47.23c-3.095-3.746-3.095-9.609-3.095-14.82 0-7.817 0-20.52 14.66-20.52 3.095 0 6.189 0.651 8.794 2.443zm23.13-30.29c2.932 4.072 3.095 9.772 3.095 15.47 0 7.816 0 19.71-14.66 19.71-1.302 0-5.211 0-8.631-2.28z"/>
+<path d="m165.6 78.55c-6.975 0-12.75-2.224-17.3-6.65-4.551-4.424-6.826-10.12-6.826-17.12 0-6.975 2.275-12.67 6.826-17.1 4.549-4.424 10.32-6.65 17.3-6.65s12.77 2.225 17.35 6.65c4.6 4.426 6.899 10.15 6.899 17.1 0 6.975-2.299 12.68-6.899 17.12-4.6 4.426-10.37 6.65-17.35 6.65zm0-36.45c-3.324 0-5.875 1.25-7.674 3.775-1.775 2.525-2.676 5.5-2.676 8.975 0 3.475 0.8256 6.4 2.5 8.774 1.901 2.725 4.526 4.076 7.85 4.076 3.326 0 5.926-1.35 7.85-4.076 1.75-2.4 2.625-5.326 2.625-8.774 0-3.475-0.8256-6.4-2.5-8.774-1.924-2.651-4.576-3.975-7.975-3.975z"/>
+<path d="m227.2 77.32v-4.551c-1.225 1.65-3.326 2.951-6.276 3.951-2.625 0.8996-5.125 1.35-7.5 1.35-6.574 0-11.85-2.25-15.82-6.776-3.975-4.5-5.975-10.1-5.975-16.75 0-6.574 1.951-12.07 5.85-16.5 3.449-3.924 9.1-6.65 15.57-6.65 7.301 0 11.58 2.75 14.15 5.9v-37.3h13.42v77.32zm0-25.75c0-2.451-1.176-4.826-3.5-7.075-2.326-2.25-4.75-3.375-7.2-3.375-3.525 0-6.326 1.451-8.375 4.299-1.799 2.551-2.701 5.676-2.701 9.35 0 3.625 0.9013 6.7 2.701 9.225 2.049 2.951 4.85 4.424 8.375 4.424 2.125 0 4.451-1 6.95-3.025 2.5-2 3.75-4.074 3.75-6.225z"/>
+<path d="m244.8 0h13.8v77.32h-13.8z"/>
+<path d="m327 73.83h-2.774c-2.772 15.57-5.324 23-24.29 23h-14.64c-5.212 0-5.435-0.712-5.435-4.07v-27.07h9.872c10.76 0 11.98 3.257 11.98 11.91h2.773v-26.87h-2.773c0 8.649-1.22 11.8-11.98 11.8h-9.872v-24.32c0-3.358 0.2227-4.072 5.435-4.072h14.2c16.97 0 19.85 5.598 21.63 19.74h2.773l-3.105-22.8h-62.11v3.053h2.552c8.539 0 8.762 1.12 8.762 4.783v53.12c0 3.663-0.2216 4.782-8.762 4.782h-2.552v3.155h63.67l4.659-26.15z"/>
+</g>
+<path d="m43.67 29.22 13.68-10-0.176-0.6003c-24.67 3.025-35.9 5.174-57.17 17.5l0.2007 0.5493 1.699 0.0263c-0.1497 1.699-0.4243 5.9-0.074 12.25-2.35 6.824-0.051 11.47 2.099 16.52 0.3503-5.25 0.301-11-1.299-16.72-0.3257-6.275-0.0493-10.42 0.1003-12.02l14.1 0.125s-0.1003 4.25 0.4243 8.274c12.6 4.424 25.27-0.0247 32-10.92-1.9-2.125-5.576-4.975-5.576-4.975z" fill="#333"/>
+</svg>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_autopoints-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_autopoints-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_autopoints-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,117 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example Quiz</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[All correct]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>100\% is distributed uniformly. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="33.33333" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="33.33333" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="33.33333" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Auto sanction]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Without the star, an error shall be issued because correct answers should sum up to 100\%. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="-50" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="-50" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[All correct but sum \(\geq 100\)]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>A warning shall be issued because correct answers must sum up to 100\%. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="50" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="50" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="50" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Select the following numbers that are prime. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="20" format="html">
+    <text><![CDATA[<p>2</p>]]></text>
+  </answer>
+  <answer fraction="40" format="html">
+    <text><![CDATA[<p>5</p>]]></text>
+  </answer>
+  <answer fraction="40" format="html">
+    <text><![CDATA[<p>7</p>]]></text>
+  </answer>
+  <answer fraction="-50" format="html">
+    <text><![CDATA[<p>1</p>]]></text>
+  </answer>
+  <answer fraction="-25" format="html">
+    <text><![CDATA[<p>6</p>]]></text>
+  </answer>
+  <answer fraction="-25" format="html">
+    <text><![CDATA[<p>8</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_calculated_python-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_calculated_python-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_calculated_python-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example Quiz</text>
+  </category>
+</question>
+ 
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Arithmetic Quiz (3, 2)]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Solve the following tasks!<BR/> \(3 + 2 =\){1:NUMERICAL:=5:0}\(3 - 2 =\){1:NUMERICAL:=1:0}\(3 * 2 =\){1:NUMERICAL:=6:0}</p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[calculated]]></text></tag>
+  </tags>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Arithmetic Quiz (4, 2)]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Solve the following tasks!<BR/> \(4 + 2 =\){1:NUMERICAL:=6:0}\(4 - 2 =\){1:NUMERICAL:=2:0}\(4 * 2 =\){1:NUMERICAL:=8:0}\(4 : 2 =\){1:NUMERICAL:=2:0}</p>]]></text>
+  </questiontext>
+  <defaultgrade>4</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[calculated]]></text></tag>
+  </tags>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Arithmetic Quiz (4, 3)]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Solve the following tasks!<BR/> \(4 + 3 =\){1:NUMERICAL:=7:0}\(4 - 3 =\){1:NUMERICAL:=1:0}\(4 * 3 =\){1:NUMERICAL:=12:0}</p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[calculated]]></text></tag>
+  </tags>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_categories-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_categories-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_categories-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,200 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Examples</text>
+  </category>
+</question>
+ 
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Examples/Generic</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>A </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>D</p>]]></text>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>One </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>0</tolerance>
+  </answer>
+</question>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Examples/Very Specific</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>A </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>D</p>]]></text>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>One </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>0</tolerance>
+  </answer>
+</question>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Other Category</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>A </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>D</p>]]></text>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>One </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>0</tolerance>
+  </answer>
+</question>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Other Category/Other Subcategory</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>A </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>D</p>]]></text>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>One </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>0</tolerance>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_circuitikz-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_circuitikz-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_circuitikz-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,124 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Circuitikz</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAU4AAACyCAMAAAAaqtaNAAAAUVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAsiKZwAAAAGnRSTlMAESIzRFVma3V3iJeZp6q0u7/Mzd3f7u/w9HQfvdYAAAXnSURB 
+VHja7dzbmqUmEAXgQtFEYhxiDEnW+z9oLvTr3grsQ8eCPfbybvow1fsHqkBBkS9c+E6XFe0LUuOq 
+FJWc5CQnOclJTnKSk5zkJCc5yUlOcpKTnOQkJznJSU5ykpOc5CQnOclJTnKSk5zkJCc5yUlOcpKT 
+nOQkJznJSU5ykpOc5CQnOclJTnKSk5zkJCc5yUlOcpKTnOQkJzlVozpTI+qP5qKcCBVAC0Stw2l9 
+DdBmVI9ah3MFXfrSUVvtZqzFWQt0HRcX5BSxSy1Qtag1OUX6BVhsFVB7QU4xM+AuFLUqZzMGYC7d 
+OxsXFHqnsYPzHn5yg62CaScAU+nY7QjAdye30DDt3mw59aUngb0HMDalm9ADGNuT/9MZACY3WGut 
+Hdz6z4L9xAxLjXl8vwDBNee3UBi7289i+qlgX1mTV+kZknEBWIaTm9BMQBgy0cYC/UUleT1Z9U5v 
+wjZkB1kzArN2B1VJXtWqXh8w7zB37dXOCKqfVCV51at6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lfrwnqk7sakmzam3qUa5PhRN3YktX0lOtS1f6vWhbOpObEhMcSpt 
+SCxRH8qm7ni7bILTKW+Pj+tD+VPt+0dvX77izdw23nyDrvDYK3/EtT/piGt01CBamZbsLD//2YPo 
+IMx+FMwFR3pT5ezByVOKO8e0TIljWruseYHjwtUPEYpc6rhw/ojrVObzXem48Ap6OIDtCx7AvtJx 
+4c8PVen1AJc6LrxvsPIvr7jWceHUVfDVKhc7LlyXsw3XOkRYmfNyR1zrcl7vAHbl3Hn2ybMno/Yl 
+x3vZt3xdvhqVfmnahQ4NvwPn9gSsQtSAi75KunE1ohrHF52fG5Wc5CQnOclJTnKSk5zkJCc5yUlO 
+cpKTnOQkJznJSU5ykpOc5CQnOclJTnKSk5zkJCc5yUlOcpKTnOQkJznJSU5ykpOc5CQnOclJTnKS 
+k5zkJCc5yUlOcpKTnOQk53fhDPhG10uc/wE0y8cVfct2SQAAAABJRU5ErkJggg== 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAU4AAACyCAMAAAAaqtaNAAAAUVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAsiKZwAAAAGnRSTlMAESIzRFVma3V3iJeZp6q0u7/Mzd3f7u/w9HQfvdYAAAXnSURB 
+VHja7dzbmqUmEAXgQtFEYhxiDEnW+z9oLvTr3grsQ8eCPfbybvow1fsHqkBBkS9c+E6XFe0LUuOq 
+FJWc5CQnOclJTnKSk5zkJCc5yUlOcpKTnOQkJznJ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bH95tf6s9l3NdEtn7UUMn0uwnQes0yqARET+822A3+bue2/zPwYmYkzmPVS8TdWpF 
+zH6BPeOzbb17r1KUTF6H+Z+DEzOcyZmoetmoIv3N7Z/Ge8CPR873mChlktfNH+5EpA3OuBN75707 
+gnFUaZY2Ofncc9afxueSV/wZh8GcljszVS8b1UzpJAcrIh93GOovMm0ueeV/4ZyoLz0oMs5IkyKZ 
+ehHzkQbq3wL5KTjbyVrrUiTGd83nwil3xy3DqXGDzk5PDvYt401wJ6yP2mcH+1aAgVxetNbcdrf2 
+BU6d28f3SlHhBdj/vVwaKMOp9XDj7kRJb6E+3JkofbGN4kdveU7NR2+VNi/Mr6buh93TP825qD55 
+6+rsin8pdT/u8SEll+RU3Lbwlfrwnqk7sakmzam3qUa5PhRN3YktX0lOtS1f6vWhbOpObEhMcSpt 
+SCxRH8qm7ni7bILTKW+Pj+tD+VPt+0dvX77izdw23nyDrvDYK3/EtT/piGt01CBamZbsLD//2YPo 
+IMx+FMwFR3pT5ezByVOKO8e0TIljWruseYHjwtUPEYpc6rhw/ojrVObzXem48Ap6OIDtCx7AvtJx 
+4c8PVen1AJc6LrxvsPIvr7jWceHUVfDVKhc7LlyXsw3XOkRYmfNyR1zrcl7vAHbl3Hn2ybMno/Yl 
+x3vZt3xdvhqVfmnahQ4NvwPn9gSsQtSAi75KunE1ohrHF52fG5Wc5CQnOclJTnKSk5zkJCc5yUlO 
+cpKTnOQkJznJSU5ykpOc5CQnOclJTnKSk5zkJCc5yUlOcpKTnOQkJznJSU5ykpOc5CQnOclJTnKS 
+k5zkJCc5yUlOcpKTnOQk53fhDPhG10uc/wE0y8cVfct2SQAAAABJRU5ErkJggg== 
+"></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>toast</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAU4AAACyCAMAAAAaqtaNAAAAUVBMVEX///8AAAAAAAAA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ykpOc5CQnOclJTnKSk5zkJCc5yUlOcpKTnOQkJznJSU5ykpOc5CQnOclJTnKS 
+k5zkJCc5yUlOcpKTnOQk53fhDPhG10uc/wE0y8cVfct2SQAAAABJRU5ErkJggg== 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_cloze_multi-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_cloze_multi-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_cloze_multi-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Cloze Multi</text>
+  </category>
+</question>
+ 
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Regular, single, no shuffle {1:MULTICHOICE:=chip#yes~%10%<I>chop</I>~%-30%<B>chap</B>#no.}</P><P>Vertical, single, no shuffle {1:MULTICHOICE_V:=chip#yes~%10%chop~chap#no.}</P><P>Horizontal, single, no shuffle {1:MULTICHOICE_H:=chip#yes~%10%chop~chap#no.}</P><P>Regular, single, shuffle {1:MULTICHOICE_S:=chip~chop#yes~chap#no.}</P><P>Vertical, single, shuffle {1:MULTICHOICE_VS:=chip#yes~%10%chop~chap#no.}</P><P>Horizontal, single, shuffle {1:MULTICHOICE_HS:=chip#yes~chop~chap#no.}</P><P>Regular, multiple, no shuffle {1:MULTIRESPONSE:=chip~=chop#yes~chap#no.}</P><P></P><P>Horizontal, multiple, no shuffle {1:MULTIRESPONSE_H:=chip#yes~=chop~chap#no.}</P><P>Regular, multiple, shuffle {1:MULTIRESPONSE_S:=chip~=chop#yes~chap#no.}Horizontal, multiple, shuffle {1:MULTIRESPONSE_HS:=chip#yes~=chop~chap#no.}</P><P></p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_cloze_numerical-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_cloze_numerical-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_cloze_numerical-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Close Short Answer</text>
+  </category>
+</question>
+ 
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Enter an integer \(n\) such that \(0< n\leq 2\). {1:NUMERICAL:%10%0:0.001#study difference between \(<\) and \(\leq \)~=1:0.01#good!~=2:0.1#OK}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_cloze_shortanswer-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_cloze_shortanswer-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_cloze_shortanswer-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Close Short Answer</text>
+  </category>
+</question>
+ 
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Who? {1:SHORTANSWER_C:=chip~%10%chop#yes~%-30%chap#no.}what? {1:SHORTANSWER:=chip~%10%chop#yes~%-30%chap#no.}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_commands-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_commands-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_commands-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/LaTeX Commands</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[LaTeX Commands]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Find the answer with small capitals </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><EM>emphasis</EM></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><B>bold</B></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><I>italic</I></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><CODE>typewriter</CODE></p>]]></text>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><SPAN STYLE="font-variant: small-caps;">Small Capitals</SPAN></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><SPAN STYLE="text-decoration: underline;">underlined</SPAN></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>M<SUP>me</SUP></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>H<SUB>2</SUB>O</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><A href="http://192.0.0.256">http://192.0.0.256</A></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><A href="mailto:name at server.com">Contact me</A></p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_description-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_description-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_description-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example Quiz</text>
+  </category>
+</question>
+ 
+<question type="description">
+  <name format="html">
+    <text><![CDATA[Requirements]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>This is a description. Not really a question. We can include environments and math. <UL><LI>This</LI><LI>That</LI></UL> \[\mathrm {e}^{2\mathrm {i}\pi }+1=0.\]</p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>here is a feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[descr]]></text></tag>
+  </tags>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_environments-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_environments-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_environments-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/LaTeX Environments</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[LaTeX Environments]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><CENTER><SPAN STYLE="font-variant: small-caps;">This is a question</SPAN></CENTER> Select the numbered list </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><OL><LI>C</LI><LI>D <UL><LI>S</LI><LI>T</LI><LI>U</LI></UL></LI></OL></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>yes</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><UL><LI>E <OL><LI>X</LI><LI>Y</LI><LI>Z</LI></OL></LI><LI>F</LI></UL></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>Example of numbered list:<BR/><OL><LI>first item</LI><LI>second item</LI></OL></p>]]></text></feedback>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_escaping_right_braces_in_cloze-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_escaping_right_braces_in_cloze-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_escaping_right_braces_in_cloze-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Cloze: Escaping Characters</text>
+  </category>
+</question>
+ 
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>No escaping here: \(y=a\sqrt {x}/2+{b}\) </P><P>No escaping here: <CODE>text</CODE> \(y=a\sqrt {x}/2+{b}\) {4:MULTICHOICE_V:=\(\lbrace A\rbrace \)~{B\}}</P><P>{No escaping here: } \(y=a\sqrt {x}/2+{b}\) {1:SHORTANSWER:=chip#nip~%10%nop#that must be escaped: \(y=a\sqrt {x\}/2+{b\}\)}</P><P>{No escaping here: } \(y=a\sqrt {x}/2+{b}\) {1:NUMERICAL:=0:0#nip~%10%1:0#that must be escaped: \(y=a\sqrt {x\}/2+{b\}\)}</P><P></p>]]></text>
+  </questiontext>
+  <defaultgrade>2</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_essay-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_essay-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_essay-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Essay Test</text>
+  </category>
+</question>
+ 
+<question type="essay">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>A </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>feedback for essay</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <responserequired>0</responserequired>
+  <responseformat>editor</responseformat>
+  <responsefieldlines>15</responsefieldlines>
+  <attachments>0</attachments>
+  <attachmentsrequired>0</attachmentsrequired>
+  <graderinfo format="html"><text><![CDATA[
+    <ul>
+      <li>B </li>
+      <li>C</li>
+    </ul>
+  ]]></text></graderinfo>
+  <responsetemplate format="html">
+    <text><![CDATA[Type you answer here]]></text>
+  </responsetemplate>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_expandnewcommands-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_expandnewcommands-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_expandnewcommands-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Recording New Commands for Expansion</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Sets]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Standard notation for the set of natural integers: </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>\(\mathbb {N}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\mathbb {Z}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\mathbb {Q}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\mathbb {C}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\mathbb {R}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\mathbb {V}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\vphantom {K}^\dagger \mathbb {K}^*_2\)</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_fancyvrb-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_fancyvrb-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_fancyvrb-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Fancy Verbatim</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Pick up the code decorated with line numbering on both sides. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">2</span><mark>% !TEX TS-program = xelatex</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">2</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right"> </span><mark></mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">3</span><mark>\documentclass{article}</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">3</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">4</span><mark>\usepackage[nostamp]{moodle}</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">4</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">5</span><mark>\newif\iffvextra</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">5</span><BR/></CODE></PRE></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>No. Here, line numbers lie on the left side.</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE>% !TEX TS-program = xelatex<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">6</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">7</span><BR/><mark>\documentclass{article}</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">8</span><BR/>\usepackage[nostamp]{moodle}<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">9</span><BR/>\newif\iffvextra<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">10</span><BR/></CODE></PRE></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>No. Here, line numbers lie on the right side.</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">4</span><mark>\ifxetex % FOR XELATEX</mark><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">5</span><mark> \usepackage{fontspec}</mark><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">6</span>\else %% FOR PDFLATEX<BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">7</span>    \usepackage[utf8]{inputenc} % necessary<BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">8</span><mark>    \usepackage[T1]{fontenc} % necessary</mark><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">9</span>\fi<BR/></CODE></PRE></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>yes!</p>]]></text></feedback>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_fractions-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_fractions-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_fractions-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example Quiz</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Select the following numbers that are prime. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>abc<BR/>def \(\sqrt {2}\)</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="83.33333" format="html">
+    <text><![CDATA[<p>\(\sqrt {25}\)</p>]]></text>
+  </answer>
+  <answer fraction="-66.66667" format="html">
+    <text><![CDATA[<p><B>68</B></p>]]></text>
+  </answer>
+  <answer fraction="16.66667" format="html">
+    <text><![CDATA[<p>7</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>\(\sqrt {25}\)</p>]]></text></feedback>
+  </answer>
+  <answer fraction="33.33333" format="html">
+    <text><![CDATA[<p>8</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><CODE>nothing</CODE></p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_french-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_french-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_french-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/French Issues</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Test french]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p> <SPAN STYLE="text-decoration: underline;">Pangramme</SPAN> conçu par Gilles <SPAN STYLE="font-variant: small-caps;">Esposito-Farèse</SPAN> :</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>1<SUP>er</SUP>, M<SUP>me</SUP>, N<SUP>o</SUP><BR/> 1<SUP>er</SUP>, M<SUP>me</SUP>, N<SUP>o</SUP><BR/> H<SUB>2</SUB>O</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>Dès Noël où un zéphyr haï me vêt de glaçons würmiens je dîne d’exquis rôtis de bœuf au kir à l’aÿ d’âge mûr & cætera !</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>cité dans «  <A href="https://jacques-andre.fr/faqtypo/lessons.pdf">Petites leçons de typographie</A>  » de Jacques <SPAN STYLE="font-variant: small-caps;">André</SPAN>.</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>Portez ce vieux whisky au juge blond qui fume.</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_generalfeedback-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_generalfeedback-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_generalfeedback-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,158 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/General Feedback Test</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>multi</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>æ</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>tic</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>œ</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>tac</p>]]></text></feedback>
+  </answer>
+</question>
+<question type="shortanswer">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>shortanswer</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <usecase>0</usecase>
+  <answer fraction="100" format="plain_text">
+    <text>B</text>
+    <feedback format="html"><text><![CDATA[<p>toc</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>C</text>
+    <feedback format="html"><text><![CDATA[<p>«  »</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>*</text>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>numerical</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>toc</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>2</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>«  »</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>3</text>
+    <tolerance>0</tolerance>
+  </answer>
+</question>
+<question type="matching">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>matching</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p>æ</p>]]></text>
+    <answer><text>oui</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>œ</p>]]></text>
+    <answer><text>non</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text></text>
+    <answer><text>\xC5</text></answer>
+  </subquestion>
+</question>
+<question type="essay">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>essay</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <responserequired>0</responserequired>
+  <responseformat>editor</responseformat>
+  <responsefieldlines>15</responsefieldlines>
+  <attachments>0</attachments>
+  <attachmentsrequired>0</attachmentsrequired>
+  <graderinfo format="html"><text><![CDATA[
+    <ul>
+      <li>æyo </li>
+      <li>œ</li>
+    </ul>
+  ]]></text></graderinfo>
+  <responsetemplate format="html"><text/></responsetemplate>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>ÅŒ{1:MULTICHOICE:=chip~%10%chop#yes~chap#no.} »Å{1:SHORTANSWER:=B#toc~=C#«  »~*}« Å{1:NUMERICAL:=1:0~=2:0#«  »~3:0}Œ{1:MULTICHOICE_V:=chip#yes~%10%chop~chap#no.}</P><P>Œ{1:MULTICHOICE_H:=chip#yes~%10%chop~chap#no.}</P><P></p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>54</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_handout-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_handout-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_handout-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,336 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/ Option Handout</text>
+  </category>
+</question>
+ 
+<question type="description">
+  <name format="html">
+    <text><![CDATA[Description]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Description text</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="essay">
+  <name format="html">
+    <text><![CDATA[Essay]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <responserequired>0</responserequired>
+  <responseformat>editor</responseformat>
+  <responsefieldlines>15</responsefieldlines>
+  <attachments>0</attachments>
+  <attachmentsrequired>0</attachmentsrequired>
+  <graderinfo format="html"><text><![CDATA[
+    <ul>
+      <li>A </li>
+      <li>B </li>
+      <li>C</li>
+    </ul>
+  ]]></text></graderinfo>
+  <responsetemplate format="html"><text/></responsetemplate>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi Single]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>0</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>AAA</p>]]></text></feedback>
+  </answer>
+  <answer fraction="10" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>BBB</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>CCC</p>]]></text></feedback>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi Multiple]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="50" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>AAA</p>]]></text></feedback>
+  </answer>
+  <answer fraction="-50" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>BBB</p>]]></text></feedback>
+  </answer>
+  <answer fraction="50" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>CCC</p>]]></text></feedback>
+  </answer>
+  <answer fraction="-50" format="html">
+    <text><![CDATA[<p>D</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>DDD</p>]]></text></feedback>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[True/False 1]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="0" format="plain_text">
+    <text>true</text>
+    <feedback format="html"><text><![CDATA[<p>AAA</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>false</text>
+    <feedback format="html"><text><![CDATA[<p>BBB</p>]]></text></feedback>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[True/False 2]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>true</text>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>false</text>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[True/False 3]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="0" format="plain_text">
+    <text>true</text>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>false</text>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>1</tolerance>
+    <feedback format="html"><text><![CDATA[<p>1</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>3</text>
+    <tolerance>1</tolerance>
+    <feedback format="html"><text><![CDATA[<p>3</p>]]></text></feedback>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="shortanswer">
+  <name format="html">
+    <text><![CDATA[Short Answer]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <usecase>0</usecase>
+  <answer fraction="100" format="plain_text">
+    <text>aaa</text>
+    <feedback format="html"><text><![CDATA[<p>1</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>bbb</text>
+    <feedback format="html"><text><![CDATA[<p>3</p>]]></text></feedback>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Matching]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+    <answer format="html"><text><![CDATA[<p>1</p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+    <answer format="html"><text><![CDATA[<p>2</p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+    <answer format="html"><text><![CDATA[<p>3</p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text></text>
+    <answer format="html"><text><![CDATA[<p>4</p>]]></text></answer>
+  </subquestion>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="matching">
+  <name format="html">
+    <text><![CDATA[Matching]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>0</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+    <answer><text>1</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+    <answer><text>2</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+    <answer><text>3</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text></text>
+    <answer><text>4</text></answer>
+  </subquestion>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p></P><P>Question text {1:MULTICHOICE_H:=A#AAA~%10%B#BBB~C#CCC}</P><P>Question text {1:MULTICHOICE_V:=A#AAA~%10%B#BBB~C#CCC}</P><P>Question text {1:MULTICHOICE:=A#AAA~%10%B#BBB~C#CCC}</P><P>Question text {1:MULTICHOICE_HS:=A#AAA~%10%B#BBB~C#CCC}</P><P>Question text {1:MULTICHOICE_VS:=A#AAA~%10%B#BBB~C#CCC}</P><P>Question text {1:MULTICHOICE_S:=A#AAA~%10%B#BBB~C#CCC}</P><P>Question text {1:NUMERICAL:=1:1#1~3:1#3}</P><P>Question text {1:SHORTANSWER:=aaa#1~bbb#3}</P><P></p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,523 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Includegraphics</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG width=81 SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAQCAYAAAAvf+5AAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz 
+AAAN1wAADdcBQiibeAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAABhSURB 
+VCiR7dIxDkVgFEThj6jsxhp0Wlt6jY1o1NbBAlQKveLVNH8EIdFpTHKamzNTXSjxQ4sJS6BwynLD 
+QUxQo0cXGJGe167yv1qMnzQ/8QUxQoV8d8vCwIB5LzfuP2hjBTnvHcSzvuJGAAAAAElFTkSuQmCC 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/gif;base64,R0lGODlhCwARAOcAAAAAAAEBAQICAgMDAwQEBAUFBQYGBgcHBwgICAkJCQoKCgsLCwwMDA0NDQ4O 
+Dg8PDxAQEBERERISEhMTExQUFBUVFRYWFhcXFxgYGBkZGRoaGhsbGxwcHB0dHR4eHh8fHyAgICEh 
+ISIiIiMjIyQkJCUlJSYmJicnJygoKCkpKSoqKisrKywsLC0tLS4uLi8vLzAwMDExMTIyMjMzMzQ0 
+NDU1NTY2Njc3Nzg4ODk5OTo6Ojs7Ozw8PD09PT4+Pj8/P0BAQEFBQUJCQkNDQ0REREVFRUZGRkdH 
+R0hISElJSUpKSktLS0xMTE1NTU5OTk9PT1BQUFFRUVJSUlNTU1RUVFVVVVZWVldXV1hYWFlZWVpa 
+WltbW1xcXF1dXV5eXl9fX2BgYGFhYWJiYmNjY2RkZGVlZWZmZmdnZ2hoaGlpaWpqamtra2xsbG1t 
+bW5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OHA2dwAAAAASUVORK5CYII= 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAARAAsBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABAYJCP/EACkQAAEDAwQBAgcBAAAAAAAAAAECAwUEBgcAERIhEwgUIjM4UXFysbL/ 
+2gAIAQEAAD8APx7E+mJivyZXZktB2qnV35PeWZqYKTepm2PfOBsrqWWyylI2VueXWx321RXFsZaM 
+XjyAprE9qqzkUqTFmNqPLTFg9p8auR3T313pGd9XeCKi135RzKtlvRJbIcbVL05WoFJPAslXMqIB 
++Djue+tYiw9hLOc5YzcpjuRdtKxJCQka2ChqhlTC6aidrX3GR4+uIKFJUB9lDS5fX1uW/wDl/wD2 
+zqsTPyW/1H81/9k= 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAAQAAwBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABQYHCP/EACcQAAEDBAEDAwUAAAAAAAAAAAIBAwQFBgcRCAASIRMUMjhRcXax/9oA 
+CAEBAAA/ANg8gpDmb59exXTn3Btql08596TIxECkBNkUamAYqmjdVEcd0u0aFEVE9ZFQ7wW+j7En 
+6/H/AJ1OaLx5zXi3HVxQoOYrbnty1nVOoy5llmUuc+73G4bjnvvlrQp40IiIomhROl/iDY+cKjxi 
+xrJoGU7YpFFcorBRIMyzjlOsN68CTqTQ71T79qfjr//Z 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAQCAYAAAAvf+5AAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz 
+AAAN1wAADdcBQiibeAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAABhSURB 
+VCiR7dIxDkVgFEThj6jsxhp0Wlt6jY1o1NbBAlQKveLVNH8EIdFpTHKamzNTXSjxQ4sJS6BwynLD 
+QUxQo0cXGJGe167yv1qMnzQ/8QUxQoV8d8vCwIB5LzfuP2hjBTnvHcSzvuJGAAAAAElFTkSuQmCC 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHsAAADICAQAAABikFYvAAAX6klEQVR42u1d2XbjSK4EV8nu7vn/ 
+H71lSdzuQyYSEUBSLlVr85khj+0qLxKDQAIBJAA2gkcrnXTSSy+9DDLKIKMcZJSDHOWQz2P50FN/ 
+Msoggwz577t8tuVspJVG6scmqyyyyCKTzDLJJJNc8nkuH+k8yVlO+fO5/HSSS/67WWaZZZFZFlll 
+kTWfGwKtH400lc/6L/0eX/gmW/m6le8K/GuTexx4Nftn7Rq/hc03IL6glM8MVQHjd/7siDdOwo1v 
+ywd+tuu0q/wt2A28SVPegD8bfAS+5o/N3Yp7yNmA2DUo3DaA9kL6BjarNL+4fvYvh6C3CvD7HXhN 
+6ezgawc3wAMn8P03b9AC3Na9KEPeiulY8//aP4C+0b/tL21ZRdDJdK7lY5U1/3QFNHQNBltfp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gwIUSKFyNOdLgRY0SJFTEC4Eiw5EWT 
+IVEiDAgAOw== 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAAQAAwBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABQYHCP/EACcQAAEDBAEDAwUAAAAAAAAAAAIBAwQFBgcRCAASIRMUMjhRcXax/9oA 
+CAEBAAA/ANg8gpDmb59exXTn3Btql08596TIxECkBNkUamAYqmjdVEcd0u0aFEVE9ZFQ7wW+j7En 
+6/H/AJ1OaLx5zXi3HVxQoOYrbnty1nVOoy5llmUuc+73G4bjnvvlrQp40IiIomhROl/iDY+cKjxi 
+xrJoGU7YpFFcorBRIMyzjlOsN68CTqTQ71T79qfjr//Z 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAARAAsBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABAYJCP/EACkQAAEDAwQBAgcBAAAAAAAAAAECAwUEBgcAERIhEwgUIjM4UXFysbL/ 
+2gAIAQEAAD8APx7E+mJivyZXZktB2qnV35PeWZqYKTepm2PfOBsrqWWyylI2VueXWx321RXFsZaM 
+XjyAprE9qqzkUqTFmNqPLTFg9p8auR3T313pGd9XeCKi135RzKtlvRJbIcbVL05WoFJPAslXMqIB 
++Djue+tYiw9hLOc5YzcpjuRdtKxJCQka2ChqhlTC6aidrX3GR4+uIKFJUB9lDS5fX1uW/w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n8GD 
+BwciXKhwocGGDiEilEgQQMSKDhMWzPhPIsONFy1m9NixosmCJ0U+NIkwIAAh+QQJCgD/ACwAAAAA 
+CwARAAAIMwABCBwo8J/BgwcHIlyocKHBhg4hIpRIEEDEig4TFsz4TyLDjRctZvTYsaLJjScnmkQY 
+EAAh+QQJCgD/ACwAAAAACwARAAAIMwABCBwo8J/BgwcHIlyocKHBhg4hIpRIEEDEig4TFsz4TyLD 
+jRlBfrQ4sqLJhyc1YjwYEAAh+QQJCgD/ACwAAAAACwARAAAINAABCBwo8J/BgwcHIlyocKHBhg4h 
+IpRIEEDEig4TFsz4TyLDjRctZvT4sKJJkSdFdjSJMCAAIfkECQoA/wAsAAAAAAsAEQAACDQAAQgc 
+KPCfwYMHByJcqHChwYYOISKUSBBAxIoOExbM+E8iw40XLWb0+LCiSZEnRXY0iTAgACH5BAEKAP8A 
+LAAAAAALABEAAAgyAAEIHCjwn8GDBwciXKhwoUGCDv81ZFgwIUSKFyNOdLgRY0SJFTEC4Eiw5EWT 
+IVEiDAgAOw== 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG  SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHsAAADICAQAAABikFYvAAAX6klEQVR42u1d2XbjSK4EV8nu7vn/ 
+H71lSdzuQyYSEUBSLlVr85khj+0qLxKDQAIBJAA2gkcrnXTSSy+9DDLKIKMcZJSDHOWQz2P50FN/ 
+Msoggwz577t8tuVspJVG6scmqyyyyCKTzDLJJJNc8nkuH+k8yVlO+fO5/HSSS/67WWaZZZFZFlll 
+kTWfGwKtH400lc/6L/0eX/gmW/m6le8K/GuTexx4Nftn7Rq/hc03IL6glM8MVQHjd/7siDdOwo1v 
+ywd+tuu0q/wt2A28SVPegD8bfAS+5o/N3Yp7yNmA2DUo3DaA9kL6BjarNL+4fvYvh6C3CvD7HXhN 
+6ezgawc3wAMn8P03b9AC3Na9KEPeiulY8//aP4C+0b/tL21ZRdDJdK7lY5U1/3QFNHQN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/+Lz1U/6zbCP 
+tIFvj5vqCkHhdlO9NX6TUPVEDVksfa4+LVdeoui9HMtbW/uxPYvH5r3rheNTXXg6kt2UpaLS8fNL 
+YY+hekEV3T5bYLhJJ4uDOxRiklrUbdrJez3I2sGul23wYyKbIjnMsQ7FQ6t/9g+Yk/LKbwZ7IMLA 
+s+tsFQvAVs+Oe9GNtNK7WoQnxM3/BrZdmgeOT781c7RKL6ssMpQAUkHvNR6+HfAetoMYOIM2v9pK 
+l4FvATQWxfpg460Og43QuSvEEnytSHZRlvVM/dq1RDDSzzcD3hc7bZcXn2udfrLJKq1sBTjOPxt2 
+e3beEngvHUEW8XVpeMFtAa6/l0DbZJu9Dry3Ap2k7S/LQMdouC2/g+UetW7LW+z4C+LtPdhSgd0A 
+GIONBbFMUrZ3k7KHbYDtK9ef6tEKMrkYfb1JsHELbA86aoHuZjSyUQzN9vtHwka4zc5PmxyE+hrg 
+G9vHXwc7Amuu/C99Z5OGJBul/ObAmz8ugNt2vv7u3/nreDLsN5fLY47237/ETzz+B/u/6fgf7P+m 
+4/8BfX6FOOHA2dwAAAAASUVORK5CYII= 
+"></p>]]></text></answer>
+  </subquestion>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics_via_tikz-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics_via_tikz-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics_via_tikz-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,112 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Includegraphics with TikZ</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEIAAAAqCAMAAAAwLX3tAAAANlBMVEUAAAD///8AAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADl82K3AAAAEXRSTlMAABNESlN1 
+hImlq7XM2+b1/Z9TPi4AAABXSURBVEjH7dPJAYAwDAPBcIM5gvtvFqmExD/hKWB/W4awEnCBu2ci 
+E9qJud8NUgkP00vUdi9IJR5gYqS+zWQSJzAxUSaiiQ2YWOnniQWYOKgtsYOZySQ+ag86ObK16lIA 
+AAAASUVORK5CYII= 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAkAAAAOCAYAAAD9lDaoAAAAcUlEQVQokcWPMRWAMAxEf0FBLWCh 
+FrpiAy1FE0gACa0EkABDj0eXlpGbknc/yaXn1QBMwKg+FR4OWIALOICoOsoDIAhyxaDXwMaHgja6 
+rgGdT9GCBoF7DfA6FWqAJQeuhi4B+xNgZDpgruRMhvxqS+sNlq0d/BTebEoAAAAASUVORK5CYII= 
+"></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABcAAAAjAQMAAABFDwNYAAAABlBMVEX///8AAABVwtN+AAAAAXRS 
+TlMAQObYZgAAADdJREFUCNdj+P+/gYGB/QEEM/6A4n9Q/AOBoWr4gcJgDNTHj00vQwUqRjHjHxj/ 
+//8AgoFcJAwAXTsqcaGGnVkAAAAASUVORK5CYII= 
+"></p>]]></text>
+  </answer>
+</question>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAbCAYAAACa9mScAAAAdklEQVQ4jWNkYGAIZoAAQyhmQKIl 
+GRDAG0pvY0ADTOgC5AAWBgaGNdQwZBmUfYGBgeE8lA2jHzEwMHARMoRq3omm1BCquGTUkFFDRg0Z 
+NWRQGcLIwMDQCWU7Y5E3RLLoDpT+iK6IhYGBQQnKNiZgoQouCap4BwCPsgqJWVTJ7gAAAABJRU5E 
+rkJggg== 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAMAAABEpIrGAAAAM1BMVEUAAAD///8AAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADW5/q5AAAAEHRSTlMAABEiM0RVZneI 
+maq7zN3uf6QJ9gAAAKhJREFUOMu90sESwiAMRVGkVEpb4P7/17pQKJhAZ1yYJe8MyUDM46bMX4Ap 
+5dbFyCrAhgSkMAIu8a5oVbBmyOcJcGjAZQjWmOUAvAJiPQ6QJPBQhrMZngIkch3teeEKXNcXzm8Q 
+oHmhKMEOzUEgixbb1gHUp/4NLDfA46fAA+sEeGCf3PDJh6DkI1DzAbhyHTS5CtpcBW0+AGH+F93e 
+CmBjv9cCGNst7QvN2wpURq09lgAAAABJRU5ErkJggg== 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABcAAAAjAQMAAABFDwNYAAAABlBMVEX///8AAABVwtN+AAAAAXRS 
+TlMAQObYZgAAADdJREFUCNdj+P+/gYGB/QEEM/6A4n9Q/AOBoWr4gcJgDNTHj00vQwUqRjHjHxj/ 
+//8AgoFcJAwAXTsqcaGGnVkAAAAASUVORK5CYII= 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACIAAAAiCAMAAAANmfvwAAAA0lBMVEX///8AAAABAQECAgIDAwME 
+BAQFBQUJCQkLCwsNDQ0dHR0hISEiIiIoKCguLi41NTVJSUlMTExmZmZubm5zc3N1dXWLi4uQkJCS 
+kpKbm5ucnJydnZ2fn5+goKCioqKkpKSlpaWmpqapqamqqqqrq6utra2urq6xsbGzs7O1tbW2tra6 
+urq8vLzLy8vMzMzT09Pd3d3h4eHk5OTl5eXm5ubn5+fp6enr6+vs7Ozt7e3w8PDz8/P09PT29vb3 
+9/f5+fn6+vr7+/v8/Pz9/f3+/v7/////o5MGAAAAAXRSTlMAQObYZgAAAbNJREFUOMuF1NlS6kAQ 
+BuB0SEBlUWQ1BlyIARRZ4yBLwqR7/vd/pXPh2SoE6Mupr6Zrpv5uyzouWJcK2F8W+/OGGdjjXC+w 
+1ohxxhyw1lriFNCnxAHrtQinqdb59xgDwBhmBoBJjhA5HCACMPPX12QyyXktcGBRCh/calWrE6Js 
+F8znGHNTqcoHter16jVlTGAa83l5TM1mpdKlWb3uXROR/78IqNEol9tEd3fdLmYzzyMi3//3rpsb 
+Irq9bbfbn5/f3wDe3n7E3z8kqtVoOt1u2wBgDN7f/4jfZrcjqr1MjdkKRJLEBFnBu8WC3JfAGAiE 
+ORkGGbFnLBYbtxQEAJAyj4ZZsQew2axKpX4fiNN0NMoI/NRqtbLt19c4jo+EZSUJRLReRZFtDwbx 
+eHwkLCthATRHy6XrDppj26anjLAsBgDGUim32CzatvckyOYOADRipfwiFYueB5GjZIpojTj2fYfo 
+/h6A1rm5x3DoOM7VVb+fn24AYVgoOJ2O6/af83OLMCQqPHaiyKXnE+kPHaLeo44iRSdnyHF6PWit 
+1JlJfHgAgPN7wRgYc2ErGJjLuyXn7BfJsGNGBciJRQAAAABJRU5ErkJggg== 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAAdCAAAAABtMQhgAAABDUlEQVQYGW3Bu2pUURQA0LX3OXPN 
+o7GykBRaKggprFSCkEqxERTyF2JnZ6ddWv2A4CcIgl+gFoLBxmIg2KkIFpnJzH2YUjiuFXNX/ePQ 
+U6lVB3HNHWm2MOku+a326gMvFHpFnNqSWnXLOhUrMdOzidSqgxwshI3JKAOpVRfGwdoPpXOZwZKT 
+E3GuFKUcHHw8O5um1Iq53SeuuOj7B0fKkUdSK04N2wYpV956GL6IXlnpnBulw2deSq06Kh2WNsLk 
+7to7qVVnlh06Uxhs8kudzMKoWFfFz3BdatVQRkVP+OM1j6VWfe7eDRdU4zevvNmzK/1XsLOzvy+C 
++8fHwxCffP1s7r29m267tW2SWn8B1wBQQBxcN+IAAAAASUVORK5CYII= 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAC4AAABHAQMAAABCjOfmAAAABlBMVEX///8AAABVwtN+AAAAAXRS 
+TlMAQObYZgAAAEVJREFUGNOd0LENwCAMBdHrMjaMlrEoLF0KysQGUr3qyzqj2uEToEXO5b0mCvJd 
+flYHOfaMOmWjiPaPMnN+4o1qsGJwzgPXwLGKCxz0xgAAAABJRU5ErkJggg== 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACMAAAA2BAMAAAC/7D1CAAAAMFBMVEUAAAAAAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABaPxwLAAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAABBUlEQVQ4y62SMUoDURRFbyKIQQKzAIvUIsQVmCZFUiiW6XQHugSTBTh2diKphICm 
+sFMwrsAlKFhaJIiKRjPHYj7j//OETJFbHu7j3X/fF3lNtEh04+sWeFKgNUg2A1J6gOd5pqVHY9qy 
+pjHcG9NPtBDTjjEtY0wHBU1Jbh0FXze3J93Be0hWgP0Q7cFnSEpjOA9RBWZhTDXgLSS6MnNloGYi 
+fOfmqianGjCRqWqYQzGc2AxHMjUUQPG/aCTT1qvXlCTVYfpHziJJq37N24zc7T8cWYcvl4KuJKkN 
+sJueGi6azc4lwDRyt86UHEqSNjzUd5vjjFxn9R+nYNbzntAawMtp+lV+Afb0PN8sFBDMAAAAAElF 
+TkSuQmCC 
+"></p>]]></text></answer>
+  </subquestion>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics_via_tikz_and_svg-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics_via_tikz_and_svg-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics_via_tikz_and_svg-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,246 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Includegraphics with TikZ</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNDIuNSIg 
+aGVpZ2h0PSIyNi41NiIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNDIuNSAyNi41NiIgeG1s 
+OnNwYWNlPSJwcmVzZXJ2ZSIg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sMSkiIHdpZHRoPSIxIiBoZWlnaHQ9IjEi 
+IGltYWdlLXJlbmRlcmluZz0ib3B0aW1pemVTcGVlZCIgbWFzaz0idXJsKCNhKSIgcHJlc2VydmVB 
+c3BlY3RSYXRpbz0ibm9uZSIgeGxpbms6aHJlZj0iZGF0YTppbWFnZS9wbmc7YmFzZTY0LGlWQk9S 
+dzBLR2dvQUFBQU5TVWhFVWdBQUFBb0FBQUFRQ0FZQUFBQXZmKzVBQUFBQUJITkNTVlFJQ0FnSWZB 
+aGtpQUFBQUJwSlJFRlVLSkZqWkdCZytNOUFCR0FpUnRHb3dsR0ZsQ2tFQUxVaUFSOUNRa1gyQUFB 
+QUFFbEZUa1N1UW1DQyIvPjwvZz48L2c+PC9nPjwvZz48L2c+PC9nPjwvZz48L3N2Zz4K 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNS42MzA3 
+IiBoZWlnaHQ9IjguNjg5MyIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNS42MzA3IDguNjg5 
+MyIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZGVmcz48Y2xpcFBhdGggaWQ9ImEiPjxwYXRoIGQ9Im0wIDBoOC40NDYzdjEzLjAzNGgtOC40 
+NDYzeiIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIHRyYW5zZm9ybT0ibWF0cml4KDEuMzMzMyAwIDAg 
+LTEuMzMzMyAwIDguNjg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VVBQUFBQVNVVk9SSzVDWUlJPSIvPjwv 
+Zz48L2c+PC9nPjwvZz48L3N2Zz4K 
+"></p>]]></text>
+  </answer>
+</question>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iMTAuNjY3 
+IiBoZWlnaHQ9IjE3LjA2NyIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgMTAuNjY3IDE3LjA2 
+NyIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayI+PGRlZnM+PG1hc2sg 
+aWQ9ImEiIHg9IjAiIHk9IjAiIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIG1hc2tVbml0cz0idXNlclNw 
+YWNlT25Vc2UiPjxpbWFnZSB3aWR0aD0iMSIgaGVpZ2h0PSIxIiBpbWFnZS1yZW5kZXJpbmc9Im9w 
+dGltaXplU3BlZWQiIHByZXNlcnZlQXNwZWN0UmF0aW89Im5vbmUiIHhsaW5rOmhyZWY9ImRhdGE6 
+aW1hZ2UvcG5nO2Jhc2U2NCxpVkJPUncwS0dnb0FBQUFOU1VoRVVnQUFBQW9BQUFBUUNBQUFBQUFL 
+RkxHY0FBQUFBWE5DU1ZRSTVncGJtUUFBQUVCSlJFRlVDSmxqQ0c3Wit1ei9meThHQmdhRy8vLy8v 
+NGN3V1paZE9ILytFUmNEREh6OTc4WEF3TUFFNTlPRHlkanB6TUJneUhUbkl3TUR3K3IvTUFBQUdh 
+d2R4Rjl4QWJZQUFBQUFTVVZPUks1Q1lJST0iLz48L21hc2s+PC9kZWZzPjxnIHRyYW5zZm9ybT0i 
+bWF0cml4KDEuMzMzMyAwIDAgLTEuMzMzMyAwIDE3LjA2NykiPjxnIHRyYW5zZm9ybT0idHJhbnNs 
+YXRlKDQsNi40KSI+PGcgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoLTQsLTYuNCkiPjxnIHRyYW5zZm9y 
+bT0ic2NhbGUoOCwxMi44KSI+PGltYWdlIHRyYW5zZm9ybT0ibWF0cml4KDEsMCwwLC0xLDAsMSki 
+IHdpZHRoPSIxIiBoZWlnaHQ9IjEiIGltYWdlLXJlbmRlcmluZz0ib3B0aW1pemVTcGVlZCIgbWFz 
+az0idXJsKCNhKSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSIgeGxpbms6aHJlZj0iZGF0YTpp 
+bWFnZS9wbmc7YmFzZTY0LGlWQk9SdzBLR2dvQUFBQU5TVWhFVWdBQUFBb0FBQUFRQ0FZQUFBQXZm 
+KzVBQUFBQUJITkNTVlFJQ0FnSWZBaGtpQUFBQUJwSlJFRlVLSkZqWkdCZytNOUFCR0FpUnRHb3ds 
+R0ZsQ2tFQUxVaUFSOUNRa1gyQUFBQUFFbEZUa1N1UW1DQyIvPjwvZz48L2c+PC9nPjwvZz48L3N2 
+Zz4K 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iMjAuMjUy 
+IiBoZWlnaHQ9IjIwLjI1MiIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgMjAuMjUyIDIwLjI1 
+MiIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzI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TEuMzMzMyAwIDM0Ljc1NykiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDguNDQ2LDEzLjAzNCki 
+PjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKC04LjQ0NiwxMy4wMzQpIj48ZyB0cmFuc2Zvcm09Im1h 
+dHJpeCgyLDAsMCwyLDE2Ljg5MiwwKSI+PGcgdHJhbnNmb3JtPSJzY2FsZSgtMSkiPjxnIGNsaXAt 
+cGF0aD0idXJsKCNhKSI+PGcgdHJhbnNmb3JtPSJtYXRyaXgoMSAwIDAgLTEgMCAxMy4wMzQpIj48 
+dGV4dCB0cmFuc2Zvcm09InRyYW5zbGF0ZSgtLjg3ODkxIDEzLjAzNCkiIGZpbGw9IiMwMDAwMDAi 
+IGZvbnQtZmFtaWx5PSInT3BlbiBTYW5zJyIgZm9udC1zaXplPSIxOHB4Ij48dHNwYW4geD0iMCIg 
+eT0iMCI+MjwvdHNwYW4+PC90ZXh0PjwvZz48L2c+PC9nPjwvZz48L2c+PC9nPjwvZz48L3N2Zz4K 
+"></p>]]></text></answer>
+  </subquestion>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics_with_svg-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics_with_svg-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_includegraphics_with_svg-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,313 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Scalable Vector Graphics</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0i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QuMzJjMC0zLjM1OCAwLjIyMjct 
+NC4wNzIgNS40MzUtNC4wNzJoMTQuMmMxNi45NyAwIDE5Ljg1IDUuNTk4IDIxLjYzIDE5Ljc0aDIu 
+NzczbC0zLjEwNS0yMi44aC02Mi4xMXYzLjA1M2gyLjU1MmM4LjUzOSAwIDguNzYyIDEuMTIgOC43 
+NjIgNC43ODN2NTMuMTJjMCAzLjY2My0wLjIyMTYgNC43ODItOC43NjIgNC43ODJoLTIuNTUydjMu 
+MTU1aDYzLjY3bDQuNjU5LTI2LjE1eiIvPgo8L2c+CjxwYXRoIGQ9Im00My42NyAyOS4yMiAxMy42 
+OC0xMC0wLjE3Ni0wLjYwMDNjLTI0LjY3IDMuMDI1LTM1LjkgNS4xNzQtNTcuMTcgMTcuNWwwLjIw 
+MDcgMC41NDkzIDEuNjk5IDAuMDI2M2MtMC4xNDk3IDEuNjk5LTAuNDI0MyA1LjktMC4wNzQgMTIu 
+MjUtMi4zNSA2LjgyNC0wLjA1MSAxMS40NyAyLjA5OSAxNi41MiAwLjM1MDMtNS4yNSAwLjMwMS0x 
+MS0xLjI5OS0xNi43Mi0wLjMyNTctNi4yNzUtMC4wNDkzLTEwLjQyIDAuMTAwMy0xMi4wMmwxNC4x 
+IDAuMTI1cy0wLjEwMDMgNC4yNSAwLjQyNDMgOC4yNzRjMTIuNiA0LjQyNCAyNS4yNy0wLjAyNDcg 
+MzItMTAuOTItMS45LTIuMTI1LTUuNTc2LTQuOTc1LTUuNTc2LTQuOTc1eiIgZmlsbD0iIzMzMyIv 
+Pgo8L3N2Zz4K 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/gif;base64,R0lGODlhCwARAOcA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HBhg4hIpRIEEDEig4TFsz4TyLDjRctZvTYsaLJjScnmkQY 
+EAAh+QQJCgD/ACwAAAAACwARAAAIMwABCBwo8J/BgwcHIlyocKHBhg4hIpRIEEDEig4TFsz4TyLD 
+jRlBfrQ4sqLJhyc1YjwYEAAh+QQJCgD/ACwAAAAACwARAAAINAABCBwo8J/BgwcHIlyocKHBhg4h 
+IpRIEEDEig4TFsz4TyLDjRctZvT4sKJJkSdFdjSJMCAAIfkECQoA/wAsAAAAAAsAEQAACDQAAQgc 
+KPCfwYMHByJcqHChwYYOISKUSBBAxIoOExbM+E8iw40XLWb0+LCiSZEnRXY0iTAgACH5BAEKAP8A 
+LAAAAAALABEAAAgyAAEIHCjwn8GDBwciXKhwoUGCDv81ZFgwIUSKFyNOdLgRY0SJFTEC4Eiw5EWT 
+IVEiDAgAOw== 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG  SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iMTEuMjYy 
+IiBoZWlnaHQ9IjE3LjM3OSIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgMTEuMjYyIDE3LjM3 
+OSIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZyB0cmFuc2Zvcm09InNjYWxlKDEuMzMzMykiPjx0ZXh0IHRyYW5zZm9ybT0idHJhbnNsYXRl 
+KC0uODc4OTEgMTMuMDM0KSIgZmlsbD0iIzAwMDAwMCIgZm9udC1mYW1pbHk9IidPcGVuIFNhbnMn 
+IiBmb250LXNpemU9IjE4cHgiPjx0c3BhbiB4PSIwIiB5PSIwIj4yPC90c3Bhbj48L3RleHQ+PC9n 
+Pjwvc3ZnPgo= 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAARAAsBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABAYJCP/EACkQAAEDAwQBAgcBAAAAAAAAAAECAwUEBgcAERIhEwgUIjM4UXFysbL/ 
+2gAIAQEAAD8APx7E+mJivyZXZktB2qnV35PeWZqYKTepm2PfOBsrqWWyylI2VueXWx321RXFsZaM 
+XjyAprE9qqzkUqTFmNqPLTFg9p8auR3T313pGd9XeCKi135RzKtlvRJbIcbVL05WoFJPAslXMqIB 
++Djue+tYiw9hLOc5YzcpjuRdtKxJCQka2ChqhlTC6aidrX3GR4+uIKFJUB9lDS5fX1uW/wDl/wD2 
+zqsTPyW/1H81/9k= 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAAQAAwBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABQYHCP/EACcQAAEDBAEDAwUAAAAAAAAAAAIBAwQFBgcRCAASIRMUMjhRcXax/9oA 
+CAEBAAA/ANg8gpDmb59exXTn3Btql08596TIxECkBNkUamAYqmjdVEcd0u0aFEVE9ZFQ7wW+j7En 
+6/H/AJ1OaLx5zXi3HVxQoOYrbnty1nVOoy5llmUuc+73G4bjnvvlrQp40IiIomhROl/iDY+cKjxi 
+xrJoGU7YpFFcorBRIMyzjlOsN68CTqTQ71T79qfjr//Z 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name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TggMTEuOTFoMi43NzN2LTI2Ljg3aC0yLjc3M2Mw 
+IDguNjQ5LTEuMjIgMTEuOC0xMS45OCAxMS44aC05Ljg3MnYtMjQuMzJjMC0zLjM1OCAwLjIyMjct 
+NC4wNzIgNS40MzUtNC4wNzJoMTQuMmMxNi45NyAwIDE5Ljg1IDUuNTk4IDIxLjYzIDE5Ljc0aDIu 
+NzczbC0zLjEwNS0yMi44aC02Mi4xMXYzLjA1M2gyLjU1MmM4LjUzOSAwIDguNzYyIDEuMTIgOC43 
+NjIgNC43ODN2NTMuMTJjMCAzLjY2My0wLjIyMTYgNC43ODItOC43NjIgNC43ODJoLTIuNTUydjMu 
+MTU1aDYzLjY3bDQuNjU5LTI2LjE1eiIvPgo8L2c+CjxwYXRoIGQ9Im00My42NyAyOS4yMiAxMy42 
+OC0xMC0wLjE3Ni0wLjYwMDNjLTI0LjY3IDMuMDI1LTM1LjkgNS4xNzQtNTcuMTcgMTcuNWwwLjIw 
+MDcgMC41NDkzIDEuNjk5IDAuMDI2M2MtMC4xNDk3IDEuNjk5LTAuNDI0MyA1LjktMC4wNzQgMTIu 
+MjUtMi4zNSA2LjgyNC0wLjA1MSAxMS40NyAyLjA5OSAxNi41MiAwLjM1MDMtNS4yNSAwLjMwMS0x 
+MS0xLjI5OS0xNi43Mi0wLjMyNTctNi4yNzUtMC4wNDkzLTEwLjQyIDAuMTAwMy0xMi4wMmwxNC4x 
+IDAuMTI1cy0wLjEwMDMgNC4yNSAwLjQyNDMgOC4yNzRjMTIuNiA0LjQyNCAyNS4yNy0wLjAyNDcg 
+MzItMTAuOTItMS45LTIuMTI1LTUuNTc2LTQuOTc1LTUuNTc2LTQuOTc1eiIgZmlsbD0iIzMzMyIv 
+Pgo8L3N2Zz4K 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iMTEuMjYy 
+IiBoZWlnaHQ9IjE3LjM3OSIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgMTEuMjYyIDE3LjM3 
+OSIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZyB0cmFuc2Zvcm09InNjYWxlKDEuMzMzMykiPjx0ZXh0IHRyYW5zZm9ybT0idHJhbnNsYXRl 
+KC0uODc4OTEgMTMuMDM0KSIgZmlsbD0iIzAwMDAwMCIgZm9udC1mYW1pbHk9IidPcGVuIFNhbnMn 
+IiBmb250LXNpemU9IjE4cHgiPjx0c3BhbiB4PSIwIiB5PSIwIj4yPC90c3Bhbj48L3RleHQ+PC9n 
+Pjwvc3ZnPgo= 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG  SRC="data:image/gif;base64,R0lGODlhCwARAOcAAAAAAAEBAQICAgMDAwQEBAUFBQYGBgcHBwgICAkJCQoKCgsLCwwMDA0NDQ4O 
+Dg8PDxAQEBERERISEhMTExQUFBUVFRYWFhcXFxgYGBkZGRoaGhsbGxwcHB0dHR4eHh8fHyAgICEh 
+ISIiIiMjIyQkJCUlJSYmJicnJygoKCkpKSoqKisrKywsLC0tLS4uLi8vLzAwMDExMTIyMjMzMzQ0 
+NDU1NTY2Njc3Nzg4ODk5OTo6Ojs7Ozw8PD09PT4+Pj8/P0BAQEFBQUJCQkNDQ0REREVFRUZGRkdH 
+R0hISElJSUpKSktLS0xMTE1NTU5OTk9PT1BQUFFRUVJSUlNTU1RUVFVVVVZWVldXV1hYWFlZWVpa 
+WltbW1xcXF1dXV5eXl9fX2BgYGFhYWJiYmNjY2RkZGVlZWZmZmdnZ2hoaGlpaWp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 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAAQAAwBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABQYHCP/EACcQAAEDBAEDAwUAAAAAAAAAAAIBAwQFBgcRCAASIRMUMjhRcXax/9oA 
+CAEBAAA/ANg8gpDmb59exXTn3Btql08596TIxECkBNkUamAYqmjdVEcd0u0aFEVE9ZFQ7wW+j7En 
+6/H/AJ1OaLx5zXi3HVxQoOYrbnty1nVOoy5llmUuc+73G4bjnvvlrQp40IiIomhROl/iDY+cKjxi 
+xrJoGU7YpFFcorBRIMyzjlOsN68CTqTQ71T79qfjr//Z 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAARAAsBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABAYJCP/EACkQAAEDAwQBAgcBAAAAAAAAAAECAwUEBgcAERIhEwgUIjM4UXFysbL/ 
+2gAIAQEAAD8APx7E+mJivyZXZktB2qnV35PeWZqYKTepm2PfOBsrqWWyylI2VueXWx321RXFsZaM 
+XjyAprE9qqzkUqTFmNqPLTFg9p8auR3T313pGd9XeCKi135RzKtlvRJbIcbVL05WoFJPAslXMqIB 
++Djue+tYiw9hLOc5YzcpjuRdtKxJCQka2ChqhlTC6aidrX3GR4+uIKFJUB9lDS5fX1uW/wDl/wD2 
+zqsTPyW/1H81/9k= 
+"> </p>]]></text></answer>
+  </sub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c3ZnPgo= 
+"></p>]]></text></answer>
+  </subquestion>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_macros-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_macros-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_macros-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/LaTeX Macros</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[LaTeX Macros]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>The following commands should not be placed in items: <BR/> and </P><P>Find the \(\rm\LaTeX\) logo </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>\(\rm\TeX\) and \(\rm\LaTeX\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>(tilde) and #</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>$ and &</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>& and §</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>{ and }</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>(space) and (relax)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>(space) and (thinspace)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>… and …</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>€ and €</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\rm\TeX\) and \(\rm\LaTeX\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>_ and \</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_matching-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_matching-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_matching-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,70 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Matching</text>
+  </category>
+</question>
+ 
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Matching]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+    <answer format="html"><text><![CDATA[<p>1</p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+    <answer format="html"><text><![CDATA[<p>2</p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+    <answer format="html"><text><![CDATA[<p>3</p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text></text>
+    <answer format="html"><text><![CDATA[<p>4</p>]]></text></answer>
+  </subquestion>
+</question>
+<question type="matching">
+  <name format="html">
+    <text><![CDATA[Matching]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>0</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+    <answer><text>1</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+    <answer><text>2</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+    <answer><text>3</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text></text>
+    <answer><text>4</text></answer>
+  </subquestion>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_mathenv-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_mathenv-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_mathenv-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example Quiz</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>\[\begin {array}{c}$1\\2\end {array}\] </P><P>\[\begin {array}{c}$1\\2\end {array}\] </P><P>\(\begin {array}{c}$1\\2\end {array}\) </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>\($\sqrt {25}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>6</p>]]></text>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>7</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>\[$\sqrt {25}\]</p>]]></text></feedback>
+  </answer>
+  <answer fraction="10" format="html">
+    <text><![CDATA[<p>8</p>]]></text>
+  </answer>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>\[\begin {array}{c}$1\\2\end {array}\] </P><P>\[\begin {array}{c}$1\\2\end {array}\] </P><P>\(\begin {array}{c}$1\\2\end {array}\) {1:MULTICHOICE_VS:=\($\sqrt {25\}\)~6~=7#\[$\sqrt {25\}\]~%10%8}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_minted-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_minted-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_minted-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Minted</text>
+  </category>
+</question>
+ 
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[LaTeX Classes]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>In the following \(\rm\LaTeX\) code excerpt, on which line is the class loaded? <PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">2</span><span style="color: #177500">% !TEX TS-program = xelatex</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">2</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right"> </span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">3</span><span style="color: #A90D91">\documentclass{</span>article<span style="color: #A90D91">}</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">3</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">4</span><span style="color: #A90D91">\usepackage</span><span style="color: #836C28">[nostamp]</span><span style="color: #A90D91">{</span>moodle<span style="color: #A90D91">}</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">4</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">5</span><span style="color: #A90D91">\newif\iffvextra</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; fl!
 oat: right">5</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">6</span><span style="color: #A90D91">\fvextratrue</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">6</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">7</span><span style="color: #A90D91">\ifxetex</span> <span style="color: #177500">% FOR XELATEX</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">7</span><BR/></CODE></PRE> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>4</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>yes! <PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">2</span><span style="color: #177500">% !TEX TS-program = xelatex</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">2</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right"> </span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">3</span><mark><span style="color: #A90D91">\documentclass{</span>article<span style="color: #A90D91">}</span></mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">3</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">4</span><span style="color: #A90D91">\usepackage</span><span style="color: #836C28">[nostamp]</span><span style="color: #A90D91">{</span>moodle<span style="color: #A90D91">}</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">4</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">5</span><span style="color: #A90D91">\newif\iffvextra</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">5</span><BR/><span style="!
 font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">6</span><span style="color: #A90D91">\fvextratrue</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">6</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">7</span><span style="color: #A90D91">\ifxetex</span> <span style="color: #177500">% FOR XELATEX</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">7</span><BR/></CODE></PRE></p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>3</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>No. On line 3, there is only a comment.</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>5</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>No. On line 5, the package <CODE>moodle</CODE> is loaded.</p>]]></text></feedback>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Languages]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Select the code written in the Python language. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">2</span><mark><span style="color: #A90D91">if</span> <span style="color: #000000">n</span> <span style="color: #000000"><</span> <span style="color: #1C01CE">0</span>:</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">2</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">3</span>    <span style="color: #A90D91">raise</span> <span style="color: #000000">ValueError</span>(<span style="color: #C41A16">'non negative integer expected'</span>)<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">3</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right"> </span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">4</span><mark><span style="color: #000000">fact</span> <span style="color: #000000">=</span> <span style="color: #1C01CE">1</span></mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">4</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right"> </span><mark></mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16p!
 t; text-align: left; float: right"> </span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">5</span><mark><span style="color: #A90D91">for</span> <span style="color: #000000">i</span> <span style="color: #000000">in</span> <span style="color: #A90D91">range</span>(<span style="color: #1C01CE">2</span>, <span style="color: #000000">n</span> <span style="color: #000000">+</span> <span style="color: #1C01CE">1</span>):</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">5</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">6</span>    <span style="color: #000000">fact</span> <span style="color: #000000">*=</span> <span style="color: #000000">i</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">6</span><BR/></CODE></PRE></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>Indeed, this is Python code.</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="color: #888888">#!/usr/bin/XXXX</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">1</span><BR/><mark><span style="color: #008800; font-weight: bold">use</span> <span style="color: #0e84b5; font-weight: bold">strict</span>;</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">2</span><BR/><span style="color: #008800; font-weight: bold">use</span> <span style="color: #0e84b5; font-weight: bold">warnings</span>;<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">3</span><BR/><mark><span style="color: #008800; font-weight: bold">use</span> <span style="color: #0e84b5; font-weight: bold">IO::Handle</span>;</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">4</span><BR/><mark></mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><mark><span style="color: #008800; font-weight: bold">my</span> ( <span style="color: #996633">$remaining</span>, <span style="color: #996633">$tot</span> );</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">5</span><BR/><mark></mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="color: #996633">$remaining</span> <span style="color: #333333">=</span> <span style="color: #996633">$tot</span> <span style="color: #333333">=</span> <span style="color: #007!
 020">shift</span>(<span style="color: #996633">@ARGV</span>);<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">6</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="color: #007020">STDOUT</span><span style="color: #333333">-></span>autoflush(<span style="color: #0000DD; font-weight: bold">1</span>);<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">7</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="color: #008800; font-weight: bold">while</span> ( <span style="color: #996633">$remaining</span> ) {<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">8</span><BR/>  <span style="color: #007020">printf</span> ( <span style="background-color: #fff0f0">"Remaining %s/%s \r"</span>, <span style="color: #996633">$remaining</span><span style="color: #333333">--</span>, <span style="color: #996633">$tot</span> );<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">9</span><BR/>  <span style="color: #007020">sleep</span> <span style="color: #0000DD; font-weight: bold">1</span>;<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">10</span><BR/>}<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">11</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; dis!
 play: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="color: #008800; font-weight: bold">print</span> <span style="background-color: #fff0f0">"\n"</span>;<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">12</span><BR/></CODE></PRE></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>No. This is Perl code.</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">1</span><span style="color: #204a87; font-weight: bold">long</span> <span style="color: #000000">some_function</span><span style="color: #000000; font-weight: bold">();</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">2</span><mark><span style="color: #8f5902; font-style: italic">/* int */</span> <span style="color: #000000">other_function</span><span style="color: #000000; font-weight: bold">();</span></mark><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">3</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">4</span><mark><span style="color: #8f5902; font-style: italic">/* int */</span> <span style="color: #000000">calling_function</span><span style="color: #000000; font-weight: bold">()</span></mark><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">5</span><span style="color: #000000; font-weight: bold">{</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">6</span>    <span style="color: #204a87; font-weight: bold">long</span> <span style="color: #000000">test1</span><span style="color: #000000; font-weight: bold">;</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">7</span><mark>    <span style="color: #204a87; font-weight: bold">register</span> <span style="color: #8f5902; font-style: italic">/* int */</span> <span style="color: #000000">te!
 st2</span><span style="color: #000000; font-weight: bold">;</span></mark><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">8</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">9</span>    <span style="color: #000000">test1</span> <span style="color: #ce5c00; font-weight: bold">=</span> <span style="color: #000000">some_function</span><span style="color: #000000; font-weight: bold">();</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">10</span>    <span style="color: #204a87; font-weight: bold">if</span> <span style="color: #000000; font-weight: bold">(</span><span style="color: #000000">test1</span> <span style="color: #ce5c00; font-weight: bold">></span> <span style="color: #0000cf; font-weight: bold">0</span><span style="color: #000000; font-weight: bold">)</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">11</span>          <span style="color: #000000">test2</span> <span style="color: #ce5c00; font-weight: bold">=</span> <span style="color: #0000cf; font-weight: bold">0</span><span style="color: #000000; font-weight: bold">;</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">12</span>    <span style="color: #204a87; font-weight: bold">else</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">13</span>          <span style="color: #000000">test2</span> <span style="color: #ce5c00; font-weight: bold">=</span> <span style="color: #000000">other_function</span><span style="color: #000000; font-weight: bold">();</span><BR/><span style="font-size: 80%; background-color:!
  #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">14</span>    <span style="color: #204a87; font-weight: bold">return</span> <span style="color: #000000">test2</span><span style="color: #000000; font-weight: bold">;</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">15</span><span style="color: #000000; font-weight: bold">}</span><BR/></CODE></PRE></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>No. This is C code.</p>]]></text></feedback>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_multi-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_multi-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_multi-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,99 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example Quiz</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Select the following numbers that are prime. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>abc<BR/>def \(\sqrt {2}\)</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="70" format="html">
+    <text><![CDATA[<p>\(\sqrt {25}\)</p>]]></text>
+  </answer>
+  <answer fraction="-10" format="html">
+    <text><![CDATA[<p><B>68</B></p>]]></text>
+  </answer>
+  <answer fraction="30" format="html">
+    <text><![CDATA[<p>7</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>\(\sqrt {25}\)</p>]]></text></feedback>
+  </answer>
+  <answer fraction="-70" format="html">
+    <text><![CDATA[<p>8</p>]]></text>
+  </answer>
+  <answer fraction="-20" format="html">
+    <text><![CDATA[<p><CODE>nothing</CODE></p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Select the following numbers that are prime. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>abc<BR/>def \(\sqrt {2}\)</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>\(\sqrt {25}\)</p>]]></text>
+  </answer>
+  <answer fraction="-30" format="html">
+    <text><![CDATA[<p>6</p>]]></text>
+  </answer>
+  <answer fraction="-30" format="html">
+    <text><![CDATA[<p>9</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>\(\sqrt {25}\)</p>]]></text></feedback>
+  </answer>
+  <answer fraction="-70" format="html">
+    <text><![CDATA[<p><OL><LI>False</LI><LI>Wrong</LI></OL></p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_multiple_categories-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_multiple_categories-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_multiple_categories-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,61 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Category 1</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Q1]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Text 1 </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+</question>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Category 2</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Q2]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Text 2 </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>D</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_penalty-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_penalty-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_penalty-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>abc: def </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>abc: def</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>abc: def</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>6</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_point_points-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_point_points-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_point_points-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Ifnum</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[MWE]]></text>
+  </name>
+  <questiontext format="html"><text/></questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[MWE]]></text>
+  </name>
+  <questiontext format="html"><text/></questiontext>
+  <defaultgrade>.5</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[MWE]]></text>
+  </name>
+  <questiontext format="html"><text/></questiontext>
+  <defaultgrade>3.2</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_special_characters-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_special_characters-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_special_characters-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Diacritical marks and ligatures</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[\xC5 \xC0 \xC2 \xC3 \xC9 \xC8 \xCB \xCA \xCE \xCF \xD1 \xD5 \xD4 \xD6 \xD9 \xDC \xDB \xC7 ]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>\xE5 \xE0 \xE2 \xE3 \xE9 \xE8 \xEB \xEA \xEE \xEF \xF1 \xF5 \xF4 \xF6 \xF9 \xFC \xFB \xE7 <BR/> \xC5 \xC0 \xC2 \xC3 \xC9 \xC8 \xCB \xCA \xCE \xCF \xD1 \xD5 \xD4 \xD6 \xD9 \xDC \xDB \xC7 <BR/> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\xE5 \xE0 \xE2 \xE3 \xE9 \xE8 \xEB \xEA \xEE \xEF \xF1 \xF5 \xF4 \xF6 \xF9 \xFC \xFB \xE7 </p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>\xC5 \xC0 \xC2 \xC3 \xC9 \xC8 \xCB \xCA \xCE \xCF \xD1 \xD5 \xD4 \xD6 \xD9 \xDC \xDB \xC7 </p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>\xC5 \xC0 \xC2 \xC3 \xC9 \xC8 \xCB \xCA \xCE \xCF \xD1 \xD5 \xD4 \xD6 \xD9 \xDC \xDB \xC7 </p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>\xE5 \xE0 \xE2 \xE3 \xE9 \xE8 \xEB \xEA \xEE \xEF \xF1 \xF5 \xF4 \xF6 \xF9 \xFC \xFB \xE7 </p>]]></text></feedback>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Å À Â Ã É È Ë Ê Î Ï Ñ Õ Ö Ô Ù Ü Û Ç Ş Ţ Ő Ű Ÿ Ă Ĕ Ğ Ĭ Ŏ Ŭ Č Ď Ě Ľ Ň Ř Š Ť Ž ]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>å à â ã é è ë ê î ï ñ õ ö ô ù ü û ç ş ţ ő ű ÿ ă ĕ ğ ĭ ĭ ŏ ŭ č ď ě ľ ň ř š ť ž <BR/> Å À Â Ã É È Ë Ê Î Ï Ñ Õ Ö Ô Ù Ü Û Ç Ş Ţ Ő Ű Ÿ Ă Ĕ Ğ Ĭ Ŏ Ŭ Č Ď Ě Ľ Ň Ř Š Ť Ž <BR/> œ æ ß Œ Æ ẞ Ø Ł «  ø ł  » ¿ ¡ </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>å à â ã é è ë ê î ï ñ õ ö ô ù ü û ç ş ţ ő ű ÿ ă ĕ ğ ĭ ĭ ŏ ŭ č ď ě ľ ň ř š ť ž </p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>Å À Â Ã É È Ë Ê Î Ï Ñ Õ Ö Ô Ù Ü Û Ç Ş Ţ Ő Ű Ÿ Ă Ĕ Ğ Ĭ Ŏ Ŭ Č Ď Ě Ľ Ň Ř Š Ť Ž </p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>Å À Â Ã É È Ë Ê Î Ï Ñ Õ Ö Ô Ù Ü Û Ç Ş Ţ Ő Ű Ÿ Ă Ĕ Ğ Ĭ Ŏ Ŭ Č Ď Ě Ľ Ň Ř Š Ť Ž </p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>å à â ã é è ë ê î ï ñ õ ö ô ù ü û ç ş ţ ő ű ÿ ă ĕ ğ ĭ ĭ ŏ ŭ č ď ě ľ ň ř š ť ž </p>]]></text></feedback>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tags-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tags-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tags-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,161 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Moodle Tags</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>æ</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>tic</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>œ</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>tac</p>]]></text></feedback>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[multi\xE9\xE0\xEE]]></text></tag>
+  </tags>
+</question>
+<question type="shortanswer">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <usecase>0</usecase>
+  <answer fraction="100" format="plain_text">
+    <text>B</text>
+    <feedback format="html"><text><![CDATA[<p>toc</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>C</text>
+    <feedback format="html"><text><![CDATA[<p>«  »</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>*</text>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[quizz-level]]></text></tag>
+  </tags>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>toc</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>2</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>«  »</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>3</text>
+    <tolerance>0</tolerance>
+  </answer>
+</question>
+<question type="matching">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p>æ</p>]]></text>
+    <answer><text>oui</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>œ</p>]]></text>
+    <answer><text>non</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text></text>
+    <answer><text>\xC5</text></answer>
+  </subquestion>
+  <tags>
+    <tag><text><![CDATA[måtchïng]]></text></tag>
+  </tags>
+</question>
+<question type="essay">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <responserequired>0</responserequired>
+  <responseformat>editor</responseformat>
+  <responsefieldlines>15</responsefieldlines>
+  <attachments>0</attachments>
+  <attachmentsrequired>0</attachmentsrequired>
+  <graderinfo format="html"><text><![CDATA[
+    <ul>
+      <li>æyo </li>
+      <li>œ</li>
+    </ul>
+  ]]></text></graderinfo>
+  <responsetemplate format="html"><text/></responsetemplate>
+  <tags>
+    <tag><text><![CDATA[essay]]></text></tag>
+  </tags>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>ÅŒ{1:MULTICHOICE:=chip~%10%chop#yes~chap#no.} »Å{1:SHORTANSWER:=B#toc~=C#«  »~*}« Å{1:NUMERICAL:=1:0~=2:0#«  »~3:0}Œ{1:MULTICHOICE_V:=chip#yes~%10%chop~chap#no.}</P><P>Œ{1:MULTICHOICE_H:=chip#yes~%10%chop~chap#no.}</P><P></p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[cloze]]></text></tag>
+  </tags>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tikz-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tikz-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tikz-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,230 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/TikZ</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAIVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAADdcGRXAAAACnRSTlMAESIziJm7zN3u5dSV+AAAACNJREFUCNdjYMAC 
+RIGYybUKSDIaeIFFyCQVgETarDYHBhwAAGGpBhwPdrFnAAAAAElFTkSuQmCC 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvM3Uwh 
+kGcAAABYSURBVAjXY2DABBIdkxgYmCYy9AUwcDxlkDvAwP6Mge8CSMavAUSuEWBgYOleAGIyrRYA 
+UUA1QMD9lIHnIgP3Cwa+RyA2twGD3gYGxmUup4FqmMsNsNgEAJkrErcirjVRAAAAAElFTkSuQmCC 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvd7qAo 
+0mEAAABeSURBVAjXY2DAASI6BIAkhwP7BiAVqsD4AEhNaABRrAENrECKg6mA8wKQ185gVwDSwHwN 
+rC/KAERqJYCFNjIwBDAwSAswsAH5M1oVYgQYGDdov7vCwMBkwOCugN1mABiqEeALUM2PAAAAAElF 
+TkSuQmCC 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAKlBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADmU0mKAAAADXRSTlMAESIzRFVmd4iqu8zuDY55BwAA 
+AFNJREFUCNdjYMAE01w8AhgY7t69AWTvaFcAkgvA4hBySUchkDzG4AOUMGDgBgtyXGJgCWDguMLA 
+cwFEchUwcB1g4DBg0E1gYGh3XQ5UwVQqgMUmALNqEhN3PGWqAAAAAElFTkSuQmCC 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAU0lEQVQI12NgQIAICLUTTDJ+BVNsD8AUVwOY0lcAU50QFZfAFCdEypsDRDNu5EsA 
+UtIG9kCVjKcc64Ac7pDMO+VgNS8cQCTzZzCH/QKY4mhgQAMAKiMPa9oLlkgAAAAASUVORK5CYII= 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Matching]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAIVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAADdcGRXAAAACnRSTlMAESIziJm7zN3u5dSV+AAAACNJREFUCNdjYMAC 
+RIGYybUKSDIaeIFFyCQVgETarDYHBhwAAGGpBhwPdrFnAAAAAElFTkSuQmCC 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAKlBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADmU0mKAAAADXRSTlMAESIzRGaImaq7zN3uKN6begAA 
+AFVJREFUCNdjYMAEYplJDAxMkxhrDBg4FBhkNjDwHmLguMzAdYiB7QpInusiiPRNAJGrBIAE+0QQ 
+MxxEsBYwGDMwmDEwBDEwn0ibeYCB++7duxMYcAAA6VQQhImgcD0AAAAASUVORK5CYII= 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvM3Uwh 
+kGcAAABYSURBVAjXY2DABBIdkxgYmCYy9AUwcDxlkDvAwP6Mge8CSMavAUSuEWBgYOleAGIyrRYA 
+UUA1QMD9lIHnIgP3Cwa+RyA2twGD3gYGxmUup4FqmMsNsNgEAJkrErcirjVRAAAAAElFTkSuQmCC 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAJFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAADHJj5lAAAAC3RSTlMAESIzRGZ3iLvM3aXhim4AAAA+SURBVAjX 
+Y2DABjxABOMKEMk+A0SadYDIAhDJpgAizRhAZAGIZFMAkWoMINK9vHxXKUjpDgY42bm7nQEHAADc 
+tQymVD9SLAAAAABJRU5ErkJggg== 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAKlBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADmU0mKAAAADXRSTlMAESIzRFVmd4iqu8zuDY55BwAA 
+AFNJREFUCNdjYMAE01w8AhgY7t69AWTvaFcAkgvA4hBySUchkDzG4AOUMGDgBgtyXGJgCWDguMLA 
+cwFEchUwcB1g4DBg0E1gYGh3XQ5UwVQqgMUmALNqEhN3PGWqAAAAAElFTkSuQmCC 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvM3Uwh 
+kGcAAABYSURBVAjXY2DABBIdkxgYmCYy9AUwcDxlkDvAwP6Mge8CSMavAUSuEWBgYOleAGIyrRYA 
+UUA1QMD9lIHnIgP3Cwa+RyA2twGD3gYGxmUup4FqmMsNsNgEAJkrErcirjVRAAAAAElFTkSuQmCC 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAKlBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADmU0mKAAAADXRSTlMAESIzRGaImaq7zN3uKN6begAA 
+AFVJREFUCNdjYMAEYplJDAxMkxhrDBg4FBhkNjDwHmLguMzAdYiB7QpInusiiPRNAJGrBIAE+0QQ 
+MxxEsBYwGDMwmDEwBDEwn0ibeYCB++7duxMYcAAA6VQQhImgcD0AAAAASUVORK5CYII= 
+"></p>]]></text></answer>
+  </subquestion>
+</question>
+<question type="shortanswer">
+  <name format="html">
+    <text><![CDATA[Short]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAIVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAADdcGRXAAAACnRSTlMAESIziJm7zN3u5dSV+AAAACNJREFUCNdjYMAC 
+RIGYybUKSDIaeIFFyCQVgETarDYHBhwAAGGpBhwPdrFnAAAAAElFTkSuQmCC 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <usecase>0</usecase>
+  <answer fraction="100" format="plain_text">
+    <text>3</text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvd7qAo 
+0mEAAABeSURBVAjXY2DAASI6BIAkhwP7BiAVqsD4AEhNaABRrAENrECKg6mA8wKQ185gVwDSwHwN 
+rC/KAERqJYCFNjIwBDAwSAswsAH5M1oVYgQYGDdov7vCwMBkwOCugN1mABiqEeALUM2PAAAAAElF 
+TkSuQmCC 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>5</text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAU0lEQVQI12NgQIAICLUTTDJ+BVNsD8AUVwOY0lcAU50QFZfAFCdEypsDRDNu5EsA 
+UtIG9kCVjKcc64Ac7pDMO+VgNS8cQCTzZzCH/QKY4mhgQAMAKiMPa9oLlkgAAAAASUVORK5CYII= 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAIVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAADdcGRXAAAACnRSTlMAESIziJm7zN3u5dSV+AAAACNJREFUCNdjYMAC 
+RIGYybUKSDIaeIFFyCQVgETarDYHBhwAAGGpBhwPdrFnAAAAAElFTkSuQmCC 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>3</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvd7qAo 
+0mEAAABeSURBVAjXY2DAASI6BIAkhwP7BiAVqsD4AEhNaABRrAENrECKg6mA8wKQ185gVwDSwHwN 
+rC/KAERqJYCFNjIwBDAwSAswsAH5M1oVYgQYGDdov7vCwMBkwOCugN1mABiqEeALUM2PAAAAAElF 
+TkSuQmCC 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>5</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAU0lEQVQI12NgQIAICLUTTDJ+BVNsD8AUVwOY0lcAU50QFZfAFCdEypsDRDNu5EsA 
+UtIG9kCVjKcc64Ac7pDMO+VgNS8cQCTzZzCH/QKY4mhgQAMAKiMPa9oLlkgAAAAASUVORK5CYII= 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAIVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAADdcGRXAAAACnRSTlMAESIziJm7zN3u5dSV+AAAACNJREFUCNdjYMAC 
+RIGYybUKSDIaeIFFyCQVgETarDYHBhwAAGGpBhwPdrFnAAAAAElFTkSuQmCC 
+"> {1:MULTICHOICE_HS:=<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvM3Uwh 
+kGcAAABYSURBVAjXY2DABBIdkxgYmCYy9AUwcDxlkDvAwP6Mge8CSMavAUSuEWBgYOleAGIyrRYA 
+UUA1QMD9lIHnIgP3Cwa+RyA2twGD3gYGxmUup4FqmMsNsNgEAJkrErcirjVRAAAAAElFTkSuQmCC 
+">#<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvd7qAo 
+0mEAAABeSURBVAjXY2DAASI6BIAkhwP7BiAVqsD4AEhNaABRrAENrECKg6mA8wKQ185gVwDSwHwN 
+rC/KAERqJYCFNjIwBDAwSAswsAH5M1oVYgQYGDdov7vCwMBkwOCugN1mABiqEeALUM2PAAAAAElF 
+TkSuQmCC 
+">~<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAKlBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADmU0mKAAAADXRSTlMAESIzRFVmd4iqu8zuDY55BwAA 
+AFNJREFUCNdjYMAE01w8AhgY7t69AWTvaFcAkgvA4hBySUchkDzG4AOUMGDgBgtyXGJgCWDguMLA 
+cwFEchUwcB1g4DBg0E1gYGh3XQ5UwVQqgMUmALNqEhN3PGWqAAAAAElFTkSuQmCC 
+">#<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAU0lEQVQI12NgQIAICLUTTDJ+BVNsD8AUVwOY0lcAU50QFZfAFCdEypsDRDNu5EsA 
+UtIG9kCVjKcc64Ac7pDMO+VgNS8cQCTzZzCH/QKY4mhgQAMAKiMPa9oLlkgAAAAASUVORK5CYII= 
+">}</P><P><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAIVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAADdcGRXAAAACnRSTlMAESIziJm7zN3u5dSV+AAAACNJREFUCNdjYMAC 
+RIGYybUKSDIaeIFFyCQVgETarDYHBhwAAGGpBhwPdrFnAAAAAElFTkSuQmCC 
+"> {1:SHORTANSWER:=3#<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvd7qAo 
+0mEAAABeSURBVAjXY2DAASI6BIAkhwP7BiAVqsD4AEhNaABRrAENrECKg6mA8wKQ185gVwDSwHwN 
+rC/KAERqJYCFNjIwBDAwSAswsAH5M1oVYgQYGDdov7vCwMBkwOCugN1mABiqEeALUM2PAAAAAElF 
+TkSuQmCC 
+">~=5#<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAU0lEQVQI12NgQIAICLUTTDJ+BVNsD8AUVwOY0lcAU50QFZfAFCdEypsDRDNu5EsA 
+UtIG9kCVjKcc64Ac7pDMO+VgNS8cQCTzZzCH/QKY4mhgQAMAKiMPa9oLlkgAAAAASUVORK5CYII= 
+">}</P><P><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAIVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAADdcGRXAAAACnRSTlMAESIziJm7zN3u5dSV+AAAACNJREFUCNdjYMAC 
+RIGYybUKSDIaeIFFyCQVgETarDYHBhwAAGGpBhwPdrFnAAAAAElFTkSuQmCC 
+"> {1:NUMERICAL:=3:0#<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvd7qAo 
+0mEAAABeSURBVAjXY2DAASI6BIAkhwP7BiAVqsD4AEhNaABRrAENrECKg6mA8wKQ185gVwDSwHwN 
+rC/KAERqJYCFNjIwBDAwSAswsAH5M1oVYgQYGDdov7vCwMBkwOCugN1mABiqEeALUM2PAAAAAElF 
+TkSuQmCC 
+">~=5:0#<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAU0lEQVQI12NgQIAICLUTTDJ+BVNsD8AUVwOY0lcAU50QFZfAFCdEypsDRDNu5EsA 
+UtIG9kCVjKcc64Ac7pDMO+VgNS8cQCTzZzCH/QKY4mhgQAMAKiMPa9oLlkgAAAAASUVORK5CYII= 
+">}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tikz_with_svg-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tikz_with_svg-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tikz_with_svg-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,376 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/TikZ</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NCIg 
+aGVpZ2h0PSIxMy4yOCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NCAxMy4yOCIgeG1s 
+OnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyB0 
+cmFuc2Zvcm09Im1hdHJpeCgxLjMzMzMgMCAwIC0xLjMzMzMgMCAxMy4yOCkiPjxnIHRyYW5zZm9y 
+bT0idHJhbnNsYXRlKDIuNDksNC45OCkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yLjQ5LC0y 
+LjQ5MSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAsLTIuNDg5KSI+PHRleHQgdHJhbnNmb3Jt 
+PSJtYXRyaXgoMSwwLDAsLTEsMCwxLjc4NSkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFtaWx5PSJT 
+RlJNMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjE8L3RzcGFu 
+PjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NCIg 
+aGVpZ2h0PSIxMy4yOCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NCAxMy4yOCIgeG1s 
+OnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyB0 
+cmFuc2Zvcm09Im1hdHJpeCgxLjMzMzMgMCAwIC0xLjMzMzMgMCAxMy4yOCkiPjxnIHRyYW5zZm9y 
+bT0idHJhbnNsYXRlKDIuNDksNC45OCkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yLjQ5LC0y 
+LjQ5MSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAsLTIuNDg5KSI+PHRleHQgdHJhbnNmb3Jt 
+PSJtYXRyaXgoMSwwLDAsLTEsMCwxLjc4NSkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFtaWx5PSJT 
+RlJNMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjM8L3RzcGFu 
+PjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi43ODgi 
+IGhlaWdodD0iMTMuNTc2IiB2ZXJzaW9uPSIxLjEiIHZpZXdCb3g9IjAgMCA2Ljc4OCAxMy41NzYi 
+IHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zPSJodHRwOi8vd3d3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goMSwwLDAsLTEsMCwxLjc4NSkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFtaWx5PSJT 
+RlJNMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjU8L3RzcGFu 
+PjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi43ODgi 
+IGhlaWdodD0iMTMuNTc2IiB2ZXJzaW9uPSIxLjEiIHZpZXdCb3g9IjAgMCA2Ljc4OCAxMy41NzYi 
+IHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+ 
+PGcgdHJhbnNmb3JtPSJtYXRyaXgoMS4zMzMzIDAgMCAtMS4zMzMzIDAgMTMuNTc2KSI+PGcgdHJh 
+bnNmb3JtPSJ0cmFuc2xhdGUoMi41NDUsNS4wOTEpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgt 
+Mi41NDUsLTIuNDkxKSI+PGcgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMCwtMi42KSI+PHRleHQgdHJh 
+bnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwyLjg2NCkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFt 
+aWx5PSJTRlRJMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjQ8 
+L3RzcGFuPjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Matching]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NCIg 
+aGVpZ2h0PSIxMy4yOCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NCAxMy4yOCIgeG1s 
+OnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyB0 
+cmFuc2Zvcm09Im1hdHJpeCgxLjMzMzMgMCAwIC0xLjMzMzMgMCAxMy4yOCkiPjxnIHRyYW5zZm9y 
+bT0idHJhbnNsYXRlKDIuNDksNC45OCkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yLjQ5LC0y 
+LjQ5MSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAsLTIuNDg5KSI+PHRleHQgdHJhbnNmb3Jt 
+PSJtYXRyaXgoMSwwLDAsLTEsMCwxLjc4NSkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFtaWx5PSJT 
+RlJNMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjE8L3RzcGFu 
+PjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NCIg 
+aGVpZ2h0PSIxMy4yOCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NCAxMy4yOCIgeG1s 
+OnNwYWNlPSJwcmV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tYXRyaXgoMSwwLDAsLTEsMCwxLjc4NSkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFtaWx5PSJT 
+RlJNMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjM8L3RzcGFu 
+PjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NCIg 
+aGVpZ2h0PSIxMy4yOCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NCAxMy4yOCIgeG1s 
+OnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyB0 
+cmFuc2Zvcm09Im1hdHJpeCgxLjMzMzMgMCAwIC0xLjMzMzMgMCAxMy4yOCkiPjxnIHRyYW5zZm9y 
+bT0idHJhbnNsYXRlKDIuNDksNC45OCkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yLjQ5LC0y 
+LjQ5MSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAsLTIuNDg5KSI+PHRleHQgdHJhbnNmb3Jt 
+PSJtYXRyaXgoMSwwLDAsLTEsMCwxLjc4NSkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFtaWx5PSJT 
+RlJNMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjQ8L3RzcGFu 
+PjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGlu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GFu 
+PjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"></p>]]></text></answer>
+  </subquestion>
+</question>
+<question type="shortanswer">
+  <name format="html">
+    <text><![CDATA[Short]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NCIg 
+aGVpZ2h0PSIxMy4yOCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NCAxMy4yOCIgeG1s 
+OnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyB0 
+cmFuc2Zvcm09Im1hdHJpeCgxLjMzMzMgMCAwIC0xLjMzMzMgMCAxMy4yOCkiPjxnIHRyYW5zZm9y 
+bT0idHJhbnNsYXRlKDIuNDksNC45OCkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yLjQ5LC0y 
+LjQ5MSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAsLTIuNDg5KSI+PHRleHQgdHJhbnNmb3Jt 
+PSJtYXRyaXgoMSwwLDAsLTEsMCwxLjc4NSkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFtaWx5PSJT 
+RlJNMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjE8L3RzcGFu 
+PjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <usecase>0</usecase>
+  <answer fraction="100" format="plain_text">
+    <text>3</text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi43ODgi 
+IGhlaWdodD0iMTMuNTc2IiB2ZXJzaW9uPSIxLjEiIHZpZXdCb3g9IjAgMCA2Ljc4OCAxMy41NzYi 
+IHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+ 
+PGcgdHJhbnNmb3JtPSJtYXRyaXgoMS4zMzMzIDAgMCAtMS4zMzMzIDAgMTMuNTc2KSI+PGcgdHJh 
+bnNmb3JtPSJ0cmFuc2xhdGUoMi41NDUsNS4wOTEpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgt 
+Mi41NDUsLTIuNDkxKSI+PGcgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMCwtMi42KSI+PHRleHQgdHJh 
+bnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwxLjg5NSkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFt 
+aWx5PSJTRlRJMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjI8 
+L3RzcGFuPjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>5</text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi43ODgi 
+IGhlaWdodD0iMTMuNTc2IiB2ZXJzaW9uPSIxLjEiIHZpZXdCb3g9IjAgMCA2Ljc4OCAxMy41NzYi 
+IHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+ 
+PGcgdHJhbnNmb3JtPSJtYXRyaXgoMS4zMzMzIDAgMCAtMS4zMzMzIDAgMTMuNTc2KSI+PGcgdHJh 
+bnNmb3JtPSJ0cmFuc2xhdGUoMi41NDUsNS4wOTEpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgt 
+Mi41NDUsLTIuNDkxKSI+PGcgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMCwtMi42KSI+PHRleHQgdHJh 
+bnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwyLjg2NCkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFt 
+aWx5PSJTRlRJMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjQ8 
+L3RzcGFuPjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NCIg 
+aGVpZ2h0PSIxMy4yOCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NCAxMy4yOCIgeG1s 
+OnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyB0 
+cmFuc2Zvcm09Im1hdHJpeCgxLjMzMzMgMCAwIC0xLjMzMzMgMCAxMy4yOCkiPjxnIHRyYW5zZm9y 
+bT0idHJhbnNsYXRlKDIuNDksNC45OCkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yLjQ5LC0y 
+LjQ5MSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAsLTIuNDg5KSI+PHRleHQgdHJhbnNmb3Jt 
+PSJtYXRyaXgoMSwwLDAsLTEsMCwxLjc4NSkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFtaWx5PSJT 
+RlJNMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjE8L3RzcGFu 
+PjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>3</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi43ODgi 
+IGhlaWdodD0iMTMuNTc2IiB2ZXJzaW9uPSIxLjEiIHZpZXdCb3g9IjAgMCA2Ljc4OCAxMy41NzYi 
+IHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+ 
+PGcgdHJhbnNmb3JtPSJtYXRyaXgoMS4zMzMzIDAgMCAtMS4zMzMzIDAgMTMuNTc2KSI+PGcgdHJh 
+bnNmb3JtPSJ0cmFuc2xhdGUoMi41NDUsNS4wOTEpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgt 
+Mi41NDUsLTIuNDkxKSI+PGcgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMCwtMi42KSI+PHRleHQgdHJh 
+bnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwxLjg5NSkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFt 
+aWx5PSJTRlRJMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjI8 
+L3RzcGFuPjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>5</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi43ODgi 
+IGhlaWdodD0iMTMuNTc2IiB2ZXJzaW9uPSIxLjEiIHZpZXdCb3g9IjAgMCA2Ljc4OCAxMy41NzYi 
+IHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+ 
+PGcgdHJhbnNmb3JtPSJtYXRyaXgoMS4zMzMzIDAgMCAtMS4zMzMzIDAgMTMuNTc2KSI+PGcgdHJh 
+bnNmb3JtPSJ0cmFuc2xhdGUoMi41NDUsNS4wOTEpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgt 
+Mi41NDUsLTIuNDkxKSI+PGcgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMCwtMi42KSI+PHRleHQgdHJh 
+bnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwyLjg2NCkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFt 
+aWx5PSJTRlRJMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjQ8 
+L3RzcGFuPjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NCIg 
+aGVpZ2h0PSIxMy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L3N2ZyI+ 
+PGcgdHJhbnNmb3JtPSJtYXRyaXgoMS4zMzMzIDAgMCAtMS4zMzMzIDAgMTMuNTc2KSI+PGcgdHJh 
+bnNmb3JtPSJ0cmFuc2xhdGUoMi41NDUsNS4wOTEpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgt 
+Mi41NDUsLTIuNDkxKSI+PGcgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMCwtMi42KSI+PHRleHQgdHJh 
+bnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwyLjg2NCkiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFt 
+aWx5PSJTRlRJMTAwMCIgZm9udC1zaXplPSI5Ljk2MjZweCI+PHRzcGFuIHg9IjAiIHk9IjAiPjQ8 
+L3RzcGFuPjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+Cg== 
+">}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tolerance-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tolerance-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_tolerance-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,84 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Tolerance</text>
+  </category>
+</question>
+ 
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Num 1]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Give a number </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>4</tolerance>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>0</text>
+    <tolerance>2</tolerance>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>*</text>
+    <feedback format="html"><text><![CDATA[<p>nope</p>]]></text></feedback>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Num 2]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Give a number </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1,45E-3</text>
+    <tolerance>1,65e-4</tolerance>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>0</text>
+    <tolerance>0</tolerance>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>*</text>
+    <feedback format="html"><text><![CDATA[<p>nope</p>]]></text></feedback>
+  </answer>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[ClozeNum 1]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Give a number {1:NUMERICAL:=1:4~=0:3~*#nope}Give a number {1:NUMERICAL:=1:4~=0:2~*#nope}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[ClozeNum 2]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Give a number {1:NUMERICAL:=1,45e-3:1,65E-4~=0:0~*#nope}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_truefalse-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_truefalse-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_truefalse-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,96 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Truefalse questions</text>
+  </category>
+</question>
+ 
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[Truefalse Test 1]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>This is a matching question. </p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>general feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="0" format="plain_text">
+    <text>true</text>
+    <feedback format="html"><text><![CDATA[<p>Feedback for students choosing ”true”</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>false</text>
+    <feedback format="html"><text><![CDATA[<p> Feedback for students choosing ”false” </p>]]></text></feedback>
+  </answer>
+</question>
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[Truefalse Test 2]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>This is an essay question. </p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>general feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="0" format="plain_text">
+    <text>true</text>
+    <feedback format="html"><text><![CDATA[<p>Feedback for students choosing ”true” </p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>false</text>
+    <feedback format="html"><text><![CDATA[<p>Feedback for students choosing ”false”</p>]]></text></feedback>
+  </answer>
+</question>
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[Truefalse Test 3]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Please answer ”True”. </p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>general feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>true</text>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>false</text>
+  </answer>
+</question>
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[Truefalse Test 4]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Please answer ”False”. </p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>general feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="0" format="plain_text">
+    <text>true</text>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>false</text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_verbatim-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_verbatim-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/latin1ref/test_verbatim-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Verbatim</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE>% !TeX encoding = UTF-8<BR/>% !TeX spellcheck = en_US<BR/>% !TEX TS-program = xelatex<BR/>\documentclass{article}<BR/>\usepackage[nostamp]{moodle}<BR/>\newif\iffvextra<BR/>\fvextratrue<BR/>\ifxetex % FOR XELATEX<BR/> \usepackage{fontspec}<BR/>\else %% FOR PDFLATEX<BR/> \usepackage[utf8]{inputenc} % necessary<BR/> \usepackage[T1]{fontenc} % necessary<BR/>\fi<BR/></CODE></PRE> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>test</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>toast</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/makefile
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/makefile	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/makefile	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,62 @@
+PREFIX=test
+SUFFIX=moodle
+LUATEX_ONLY_TEST_FILES=test_calculated_lua.tex
+XETEX_EXCLUDED_TEST_FILES=test_includegraphics_via_tikz.tex test_includegraphics_via_tikz_and_svg.tex test_tikz_with_svg.tex
+GENERIC_TEST_FILES=$(filter-out $(LUATEX_ONLY_TEST_FILES) $(XETEX_EXCLUDED_TEST_FILES),$(wildcard $(PREFIX)_*.tex))
+TEX_ENGINES=pdflatex lualatex xelatex
+LATEXFLAGS=-interaction=nonstopmode -shell-escape
+DIFFTOOL=diff -abBwZ
+FILE_CLEAN=*.log *.aux *.auxlock *.out *.blg *.bbl *.toc *.xml *.bcf *.synctex.gz *~ *.nav *.snm *.idx *.ilg *.ind _minted-* *.glo *.gls *.dpth *-tikztemp-*.pdf fig/*-converted-to.*
+ifndef DEBUG
+	DEBUG=> /dev/null
+endif
+
+.DEFAULT_GOAL := all
+.NOTPARALLEL := test
+
+.PHONY: all test clean distclean $(TEX_ENGINES)
+.SECONDARY: $(foreach engine,$(TEX_ENGINES),$(GENERIC_TEST_FILES:.tex=_$(engine)-$(SUFFIX).xml)) $(LUATEX_ONLY_TEST_FILES:.tex=_lualatex-$(SUFFIX).xml) $(XETEX_EXCLUDED_TEST_FILES:.tex=_pdflatex-$(SUFFIX).xml) $(XETEX_EXCLUDED_TEST_FILES:.tex=_lualatex-$(SUFFIX).xml)
+
+all: test
+
+test: $(TEX_ENGINES)
+
+pdflatex: $(GENERIC_TEST_FILES:.tex=_pdflatex.diff) $(XETEX_EXCLUDED_TEST_FILES:.tex=_pdflatex.diff)
+
+xelatex: $(GENERIC_TEST_FILES:.tex=_xelatex.diff)
+
+lualatex: $(GENERIC_TEST_FILES:.tex=_lualatex.diff) $(LUATEX_ONLY_TEST_FILES:.tex=_lualatex.diff) $(XETEX_EXCLUDED_TEST_FILES:.tex=_lualatex.diff)
+
+clean:
+	rm -rf $(FILE_CLEAN)
+
+distclean: clean
+	rm -rf *.pdf *.xml *.diff *.md5 *.py *.err $(SUFFIX).sty
+
+%_pdflatex-$(SUFFIX).xml : %.tex $(SUFFIX).sty
+	@pdflatex $(LATEXFLAGS) $< $(DEBUG)
+	@mv $(basename $<)-$(SUFFIX).xml $@
+
+%_xelatex-$(SUFFIX).xml : %.tex $(SUFFIX).sty
+	@xelatex $(LATEXFLAGS) $< $(DEBUG)
+	@mv $(basename $<)-$(SUFFIX).xml $@
+
+%_lualatex-$(SUFFIX).xml : %.tex $(SUFFIX).sty
+	@lualatex $(LATEXFLAGS) $< $(DEBUG)
+	@mv $(basename $<)-$(SUFFIX).xml $@
+
+OK = "$$(tput setaf 0)$$(tput setab 2)[  OK  ]$$(tput sgr0)"
+KO = "$$(tput setaf 0)$$(tput setab 1)[FAILED]$$(tput sgr0)"
+$(PREFIX)_%_pdflatex.diff : latin1ref/$(PREFIX)_%-$(SUFFIX).ref $(PREFIX)_%_pdflatex-$(SUFFIX).xml
+	@$(DIFFTOOL) $^ > $@ && echo "$(OK) $* (pdflatex)"  | sed -e "s/_/ /g" || echo "$(KO) $* (pdflatex)" | sed -e "s/_/ /g"
+
+$(PREFIX)_%_xelatex.diff : utf8ref/$(PREFIX)_%-$(SUFFIX).ref $(PREFIX)_%_xelatex-$(SUFFIX).xml
+	@$(DIFFTOOL) $^ > $@ && echo "$(OK) $* (xelatex)"  | sed -e "s/_/ /g" || echo "$(KO) $* (xelatex)" | sed -e "s/_/ /g"
+	
+$(PREFIX)_%_lualatex.diff : utf8ref/$(PREFIX)_%-$(SUFFIX).ref $(PREFIX)_%_lualatex-$(SUFFIX).xml
+	@$(DIFFTOOL) $^ > $@ && echo "$(OK) $* (lualatex)"  | sed -e "s/_/ /g" || echo "$(KO) $* (lualatex)" | sed -e "s/_/ /g"
+
+$(SUFFIX).sty: ../$(SUFFIX).sty
+	cp $< $@
+../$(SUFFIX).sty: ../$(SUFFIX).dtx
+	$(MAKE) -C ../ $(SUFFIX).sty


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/makefile
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_autopoints.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_autopoints.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_autopoints.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,51 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\def\myequation{$(1+\sqrt{5})/2$}
+\htmlregister{\myequation}
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of autopoints in multi answers 
+questions.
+
+\begin{quiz}{Example Quiz}
+\begin{multi}[multiple]{All correct}
+100\% is distributed uniformly.
+\item* A
+\item* B
+\item* C
+\end{multi}
+\begin{multi}[multiple]{Auto sanction}
+Without the star, an error shall be issued because correct answers should sum 
+up to 100\%.
+\item* A
+\item B
+\item C
+\end{multi}
+\begin{multi}[multiple]{All correct but sum $\geq 100$}
+A warning shall be issued because correct answers must sum up to 100\%.
+\item[fraction=50] A
+\item[fraction=50] B
+\item[fraction=50] C
+\end{multi}
+\begin{multi}[multiple]{Multiple Choice}
+Select the following numbers that are prime.
+\item[fraction=20] 2
+\item* 5
+\item* 7
+\item[fraction=-50] 1
+\item 6
+\item 8
+\end{multi}
+\end{quiz}
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_autopoints.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_calculated_lua.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_calculated_lua.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_calculated_lua.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,77 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\usepackage{hyperref,luacode}
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the possibility of generating 
+pseudo-calculated questions with the help of Lua scripts.
+
+Inspired by
+\url{https://github.com/avohns/python-latex-moodle-quiz/blob/master/simple-examples-eng/example1_arithmetic.tex}
+
+\begin{quiz}[tags={calculated}]{Example Quiz}
+% THIS DOES NOT REQUIRE LUACODE AND WORKS WITH RECENT LUATEX (2020)
+%\directlua{
+%function clozenum_print(pair,op,result)
+%  tex.print("\\begin{numerical}$"..pair[1].." "..op.." "..pair[2].." 
+%  =$".."\\item ",result,"\\end{numerical}")
+%end
+%function cloze_print(pair,points)
+%  tex.print("\\begin{cloze}[points="..points.."]{Arithmetic Quiz 
+%  ("..pair[1]..", "..pair[2]..")}Solve the following tasks!\\\\")
+%  clozenum_print(pair,"+",pair[1]+pair[2])
+%  clozenum_print(pair,"-",pair[1]-pair[2])
+%  clozenum_print(pair,"*",pair[1]*pair[2])
+%  if pair[1]/pair[2]==math.floor(pair[1]/pair[2]) then
+%    clozenum_print(pair,":",math.floor(pair[1]/pair[2]))
+%  end
+%  tex.print("\\end{cloze}")
+%end
+%for x = 2,4 do
+%  for y = 2,4 do
+%    if x>y then
+%      if x/y==math.floor(x/y) then points=4 else points=3 end
+%      cloze_print({x,y},points)
+%    end
+%  end
+%end
+%}
+% THIS SEEMS TO WORK BETTER WITH EARLIER VERSIONS OF LUATEX
+\begin{luacode*}
+function clozenum_print(pair,op,result)
+  tex.print([[\begin{numerical}$]]..pair[1].." "..op.." "..pair[2]..
+  " = $"..[[\item ]],result,[[\end{numerical}]])
+end
+function cloze_print(pair,points)
+  tex.print([[\begin{cloze}[points=]]..points.."]{Arithmetic Quiz ("..
+  pair[1]..", "..pair[2]..[[)}Solve the following tasks!\\]])
+  clozenum_print(pair,"+",pair[1]+pair[2])
+  clozenum_print(pair,"-",pair[1]-pair[2])
+  clozenum_print(pair,"*",pair[1]*pair[2])
+  if pair[1]/pair[2]==math.floor(pair[1]/pair[2]) then
+    clozenum_print(pair,":",math.floor(pair[1]/pair[2]))
+  end
+  tex.print([[\end{cloze}]])
+end
+for x = 2,4 do
+  for y = 2,4 do
+    if x>y then
+      if x/y==math.floor(x/y) then points=4 else points=3 end
+      cloze_print({x,y},points)
+    end
+  end
+end
+\end{luacode*}
+\end{quiz}
+\end{document}
\ No newline at end of file


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_calculated_lua.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_calculated_python.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_calculated_python.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_calculated_python.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,52 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\usepackage{hyperref}
+\usepackage{python}
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the possibility of generating 
+pseudo-calculated questions with the help of Python scripts.
+
+Inspired by
+\url{https://github.com/avohns/python-latex-moodle-quiz/blob/master/simple-examples-eng/example1_arithmetic.tex}
+
+\begin{quiz}[tags={calculated}]{Example Quiz}
+% the following syntax is Python 3
+% on Ubuntu 20.10, I had to force python to default to python 3
+% https://stackoverflow.com/a/50331137
+\begin{python}
+def clozenum_print(pair,op,result):
+  print(rf"""\begin{{numerical}}
+${pair[0]} {op} {pair[1]} =$\item {result} 
+\end{{numerical}}""")
+def cloze_print(pair,points):
+  print(rf"""\begin{{cloze}}[points={points}]{{Arithmetic Quiz 
+  {(pair[0],pair[1])}}}Solve the following tasks!\\""")
+  clozenum_print([x,y],"+",x+y)
+  clozenum_print([x,y],"-",x-y)
+  clozenum_print([x,y],"*",x*y)
+  if pair[0]/pair[1] == pair[0]//pair[1]:
+    clozenum_print([x,y],":",x//y)
+  print("\end{cloze}")
+for x in range(2,5):
+  for y in range(2,5):
+    if x > y:
+      if x/y == x//y:
+        points=4
+      else:
+        points=3  
+      cloze_print([x,y],points)
+\end{python}
+\end{quiz}
+\end{document}
\ No newline at end of file


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_calculated_python.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_categories.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_categories.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_categories.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,77 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[section,nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of category settings in the quiz 
+environment.
+
+%\setcategory{Category Outside Quiz}
+%\setsubcategory{Subcategory Outside Quiz}
+
+\begin{quiz}{Examples}
+\setsubcategory{Generic}
+\begin{multi}{Multi}
+A
+\item* B
+\item C
+\item D
+\end{multi}
+
+\begin{numerical}{Numerical}
+One
+\item 1
+\end{numerical}
+
+\setsubcategory{Very Specific}
+\begin{multi}{Multi}
+A
+\item* B
+\item C
+\item D
+\end{multi}
+
+\begin{numerical}{Numerical}
+One
+\item 1
+\end{numerical}
+
+\setcategory{Other Category}
+
+\begin{multi}{Multi}
+A
+\item* B
+\item C
+\item D
+\end{multi}
+
+\begin{numerical}{Numerical}
+One
+\item 1
+\end{numerical}
+
+\setsubcategory{Other Subcategory}
+\begin{multi}{Multi}
+A
+\item* B
+\item C
+\item D
+\end{multi}
+
+\begin{numerical}{Numerical}
+One
+\item 1
+\end{numerical}
+
+\end{quiz}
+\end{document}
\ No newline at end of file


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_categories.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_circuitikz.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_circuitikz.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_circuitikz.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,38 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\usepackage[nooldvoltagedirection]{circuitikz}
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of circuitikz.
+
+\begin{quiz}{Circuitikz}
+
+\begin{multi}{Multi}
+\begin{tikzpicture}[american]
+\draw (0,0) to[isource, l=$I_0$] (0,3) --(2,3) to[R=$R_1$] (2,0) -- (0,0);
+\draw (2,3) -- (4,3) to[R=$R_2$] (4,0) -- (2,0);
+\end{tikzpicture}
+\item[feedback={}]* \begin{tikzpicture}[american]
+\draw (0,0) to[isource, l=$I_0$] (0,3) --(2,3) to[R=$R_1$] (2,0) -- (0,0);
+\draw (2,3) -- (4,3) to[R=$R_2$] (4,0) -- (2,0);
+\end{tikzpicture}
+\item[feedback={\begin{tikzpicture}[american]
+\draw (0,0) to[isource, l=$I_0$] (0,3) --(2,3) to[R=$R_1$] (2,0) -- (0,0);
+\draw (2,3) -- (4,3) to[R=$R_2$] (4,0) -- (2,0);
+\end{tikzpicture}}] toast
+\end{multi}
+
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_circuitikz.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_multi.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_multi.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_multi.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,117 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of multi answers questions 
+embedded in cloze questions. The following options are tested
+\begin{itemize}
+	\item Single or multiple correct answer
+	\item Regular mode, Horizontal mode, Vertical mode
+	\item Shuffling or no shuffling
+\end{itemize}
+
+\begin{quiz}{Cloze Multi}
+
+\begin{cloze}{Cloze}
+%% SINGLE
+\begin{multi}[shuffle=false]
+Regular, single, no shuffle
+\item[feedback={yes}]* chip 
+\item[fraction=10] \textit{chop} 
+\item[feedback={no.},fraction=-30] \textbf{chap}
+\end{multi}
+
+\begin{multi}[shuffle=false,vertical]
+Vertical, single, no shuffle
+\item[feedback={yes}]* chip
+\item[fraction=10] chop
+\item[feedback={no.}] chap
+\end{multi}
+
+\begin{multi}[shuffle=false,horizontal]
+Horizontal, single, no shuffle
+\item[feedback={yes}]* chip
+\item[fraction=10] chop
+\item[feedback={no.}] chap
+\end{multi}
+
+\begin{multi}[shuffle=true]
+	Regular, single, shuffle
+	\item[]* chip
+	\item[feedback={yes}] chop
+	\item[feedback={no.}] chap
+\end{multi}
+
+\begin{multi}[shuffle=true,vertical]
+	Vertical, single, shuffle
+	\item[feedback={yes}]* chip
+	\item[fraction=10] chop
+	\item[feedback={no.}] chap
+\end{multi}
+
+\begin{multi}[shuffle=true,horizontal]
+	Horizontal, single, shuffle
+	\item[feedback={yes}]* chip
+	\item chop
+	\item[feedback={no.}] chap
+\end{multi}
+
+%% MULTIPLE
+\begin{multi}[multiple,shuffle=false]
+	Regular, multiple, no shuffle
+	\item* chip
+	\item[feedback={yes}]* chop
+	\item[feedback={no.}] chap
+\end{multi}
+
+%\begin{multi}[multiple,shuffle=false,vertical]
+%	Vertical, multiple, no shuffle
+%	\item[feedback={yes}]* chip
+%	\item* chop
+%	\item[feedback={no.}] chap
+%\end{multi}
+
+\begin{multi}[multiple,shuffle=false,horizontal]
+	Horizontal, multiple, no shuffle
+	\item[feedback={yes}]* chip
+	\item* chop
+	\item[feedback={no.}] chap
+\end{multi}
+
+\begin{multi}[multiple,shuffle=true]
+	Regular, multiple, shuffle
+	\item[]* chip
+	\item[feedback={yes}]* chop
+	\item[feedback={no.}] chap
+\end{multi}
+%
+%\begin{multi}[multiple,shuffle=true,vertical]
+%	Vertical, multiple, shuffle
+%	\item[feedback={yes}]* chip
+%	\item* chop
+%	\item[feedback={no.}] chap
+%\end{multi}
+%
+\begin{multi}[multiple,shuffle=true,horizontal]
+	Horizontal, multiple, shuffle
+	\item[feedback={yes}]* chip
+	\item* chop
+	\item[feedback={no.}] chap
+\end{multi}
+
+\end{cloze}
+
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_multi.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_numerical.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_numerical.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_numerical.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,34 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of numerical questions 
+embedded in cloze questions.
+
+\begin{quiz}{Close Short Answer}
+
+\begin{cloze}{Cloze}
+\begin{numerical}
+Enter an integer $n$ such that $0< n\leq 2$.
+\item[tolerance=0.001,fraction={10},feedback={study difference between $<$ and 
+$\leq$}] 0
+\item[tolerance=0.01,feedback={good!}] 1
+\item[tolerance=0.1,feedback={OK}] 2
+\end{numerical}
+\end{cloze}
+
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_numerical.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_shortanswer.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_shortanswer.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_shortanswer.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,38 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of short answers questions 
+embedded in cloze questions.
+
+\begin{quiz}{Close Short Answer}
+
+\begin{cloze}{Cloze}
+\begin{shortanswer}[usecase]
+Who?
+\item chip
+\item[feedback={yes},fraction=10] chop
+\item[feedback={no.},fraction=-30] chap
+\end{shortanswer}
+\begin{shortanswer}
+what?
+\item chip
+\item[feedback={yes},fraction=10] chop
+\item[feedback={no.},fraction=-30] chap
+\end{shortanswer}
+\end{cloze}
+
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_cloze_shortanswer.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_commands.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_commands.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_commands.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,37 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\usepackage{hyperref}
+
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of some \LaTeX\ commands for 
+conversion to HTML.
+
+\begin{quiz}[points=1]{LaTeX Commands}
+\begin{multi}{LaTeX Commands}
+Find the answer with small capitals
+\item \emph{emphasis}
+\item \textbf{bold}
+\item \textit{italic}
+\item \texttt{typewriter}
+\item* \textsc{Small Capitals}
+\item \underline{underlined}
+\item M\textsuperscript{me}
+\item H\textsubscript{2}O
+\item \url{http://192.0.0.256}
+\item \href{mailto:name at server.com}{Contact me}
+\end{multi}
+
+\end{quiz}
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_commands.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_description.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_description.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_description.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,30 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of the description 
+question type.
+
+\begin{quiz}{Example Quiz}
+\begin{description}[tags={descr},feedback={here is a feedback}]{Requirements}
+This is a description. Not really a question. We can include environments and 
+math. 
+\begin{itemize}
+\item This
+\item That
+\end{itemize}
+\[\mathrm{e}^{2\mathrm{i}\pi}+1=0.\]
+\end{description}
+\end{quiz}
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_description.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_environments.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_environments.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_environments.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,51 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+
+\renewcommand\theenumiii{\arabic{enumiii}}% third level
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of some \LaTeX\ environments for 
+conversion to HTML.
+
+\begin{quiz}[points=1]{LaTeX Environments}
+\begin{multi}{LaTeX Environments}
+\begin{center}
+\textsc{This is a question}
+\end{center}
+Select the numbered list
+\item[feedback={yes}]* \begin{enumerate}
+         \item C
+         \item D
+         \begin{itemize}
+           \item S
+           \item T
+           \item U
+          \end{itemize}  
+       \end{enumerate}
+\item[feedback={Example of numbered list:\\\begin{enumerate}
+\item first item
+\item second item
+\end{enumerate}
+}] \begin{itemize}
+         \item E
+         \begin{enumerate}
+         \item X
+         \item Y
+         \item Z
+         \end{enumerate}
+         \item F
+      \end{itemize}
+\end{multi}
+\end{quiz}
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_environments.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_escaping_right_braces_in_cloze.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_escaping_right_braces_in_cloze.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_escaping_right_braces_in_cloze.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,53 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+
+\def\myequation{y=a\sqrt{x}/2+{b}}
+\htmlregister{\myequation}
+
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check that in cloze subquestion code the right 
+brace character is escaped with a backslash, as expected.
+
+This allows the character to pass Moodle import and \LaTeX equations to be 
+displayed in \texttt{clozemulti} answers and in all cloze feedbacks.
+
+\begin{quiz}{Cloze: Escaping Characters}
+
+\begin{cloze}[points=2]{Cloze}
+No escaping here: $\myequation$
+
+\begin{multi}[points=4,vertical,shuffle=false]
+No escaping here: \texttt{text} $\myequation$
+\item* $\lbrace A\rbrace$
+\item \{B\}
+\end{multi}
+
+\begin{shortanswer}
+{No escaping here: } $\myequation$
+\item[feedback={nip}] chip
+\item[fraction=10,feedback={that must be escaped: $\myequation$}] nop
+\end{shortanswer}
+
+\begin{numerical}
+{No escaping here: } $\myequation$
+\item[feedback={nip}] 0
+\item[fraction=10,feedback={that must be escaped: $\myequation$}] 1
+\end{numerical}
+
+\end{cloze}
+
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_escaping_right_braces_in_cloze.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_essay.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_essay.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_essay.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,29 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of essay questions.
+
+\begin{quiz}[points=1]{Essay Test}
+
+\begin{essay}[feedback={feedback for essay},template={Type you answer 
+here}]{Title}
+A
+\item B
+\item C
+\end{essay}
+
+\end{quiz}
+
+\end{document}
\ No newline at end of file


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_essay.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_expandnewcommands.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_expandnewcommands.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_expandnewcommands.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,49 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+
+\moodleregisternewcommands
+
+%%%% Defining Sets
+\providecommand{\N}{\mathbb{N}}
+\newcommand{\K}{\mathbb{K}}
+\newcommand{\C}{\mathcal{C}}
+\renewcommand{\C}{\mathbb{C}}
+\newcommand{\Z}{\mathbb{Z}}
+\newcommand*{\R}{\mathbb{R}}
+\newcommand{\Q}{\mathbb{Q}}
+\newcommand{\prepostbb}[3]{#1\mathbb{#2}#3}
+
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of automatic recording of 
+\LaTeX\ new commands for expansion when converting to HTML.
+
+\begin{quiz}{Recording New Commands for Expansion}
+
+\begin{multi}{Sets}
+Standard notation for the set of natural integers: 
+\item* $\N$
+\item $\Z$
+\item $\Q$
+\item $\C$
+\item $\R$
+\item $\prepostbb{}{V}{}$
+\item $\prepostbb{\vphantom{K}^\dagger}{K}{^*_2}$
+\end{multi}
+
+\end{quiz}
+
+\end{document}
+
+


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_expandnewcommands.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_fancyvrb.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_fancyvrb.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_fancyvrb.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,72 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\newif\iffvextra
+\fvextratrue % comment this line to use vanilla 'fancyvrb'
+\iffvextra
+  \usepackage{fvextra,xcolor}
+\else
+  \usepackage{fancyvrb} % must be loaded after fancybox 
+\fi
+
+\fvset{firstline=3,firstnumber=2,lastline=7,numbers=left,tabsize=4,numberblanklines=false}
+\iffvextra
+  \fvset{highlightlines={2-5,8},numbers=both}
+\fi
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of \textsf{fancyvrb} or  
+\textsf{fvextra} packages.
+
+The only command supported is \texttt{VerbatimInput[<options>]\{<filename>\}}.
+The variant with a star is unsupported.
+
+Outside of the moodle question bodies, \texttt{VerbatimOut} environments can be 
+set to define portions of code.
+
+\begin{quiz}{Fancy Verbatim}
+% /!\ firstline and lastline set previously would apply to VerbatimOut
+\begin{VerbatimOut}[firstline,lastline]{test.log}
+  % !TeX encoding = UTF-8
+  % !TeX spellcheck = en_US
+  % !TEX TS-program = xelatex
+  
+  \documentclass{article}
+  \usepackage[nostamp]{moodle}
+  \newif\iffvextra
+  \fvextratrue
+  \ifxetex % FOR XELATEX
+   \usepackage{fontspec}
+  \else %% FOR PDFLATEX
+  	\usepackage[utf8]{inputenc} % necessary
+  	\usepackage[T1]{fontenc} % necessary
+  \fi
+\end{VerbatimOut}
+\fvset{gobble=2} % remove two characters at the beginning of each line
+\fvset{frame=none}% overide default display settings for PDF
+
+% To avoid collision of line and item numbers in PDF, force `left-right' mode:
+\RecustomVerbatimCommand{\VerbatimInput}{LVerbatimInput}{}
+\begin{multi}{Multi}
+Pick up the code decorated with line numbering on both sides.
+\item[feedback={No. Here, line numbers lie on the left side.}] 
+\VerbatimInput{test.log}
+\item[feedback={No. Here, line numbers lie on the right side.}] 
+\VerbatimInput[numbers=right,firstnumber=last,numberblanklines=true]{test.log}
+\item[feedback={yes!}]* 
+\VerbatimInput[numbers=left,firstline=9,firstnumber=4,lastline=23]{test.log}
+\end{multi}
+
+\end{quiz}
+
+\end{document}
\ No newline at end of file


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_fancyvrb.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_fractions.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_fractions.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_fractions.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,31 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check how fractions are handled.
+
+\begin{quiz}{Example Quiz}
+
+\begin{multi}[multiple,feedback={abc\\def 
+$\sqrt{2}$}]{Multiple Choice}
+Select the following numbers that are prime.
+\item[fraction=83.3] $\sqrt{25}$
+\item[fraction=-66.6] \textbf{68}
+\item[fraction=16.7,feedback={$\sqrt{25}$}] 7
+\item[fraction=33.3] 8
+\item[fraction=-0.05] \texttt{nothing}
+\end{multi}
+
+\end{quiz}
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_fractions.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_french.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_french.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_french.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,62 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\usepackage[french]{babel} % for french quotes
+\usepackage{hyperref}
+% pangramme conçu par Gilles Esposito-Farèse et cité dans "Petites leçons de 
+% typographie" de Jacques André: https://jacques-andre.fr/faqtypo/lessons.pdf
+\ifPDFTeX
+  \def\myquestiontext{ \underline{Pangramme} con\c{c}u par Gilles 
+  \textsc{Esposito-Far\`ese}\,:}
+  \def\pangramme{D\`es No\"el o\`u un z\'ephyr ha\"i me v\^et de 
+gla\c{c}ons w\"urmiens je d\^ine d'exquis r\^otis de b\oe uf au kir \`a l'a\"y 
+d'\^age m\^ur \& c\ae tera\,!}
+  \def\myfeedback{cit\'e dans 
+\og\,\href{https://jacques-andre.fr/faqtypo/lessons.pdf}{Petites 
+  le\c{c}ons de typographie}\,\fg\ de Jacques \textsc{Andr\'e}.}
+\else % assuming XELATEX or LUALATEX
+  \def\myquestiontext{ \underline{Pangramme} conçu par Gilles 
+  \textsc{Esposito-Farèse}:}
+  \def\pangramme{Dès Noël où un zéphyr haï me vêt de glaçons würmiens je dîne 
+d’exquis rôtis de bœuf au kir à l’aÿ d’âge mûr \& cætera\,!}
+  \def\myfeedback{cité dans 
+  \og\href{https://jacques-andre.fr/faqtypo/lessons.pdf}{Petites 
+  leçons de typographie}\fg\ de Jacques \textsc{André}.}
+\fi
+\htmlregister{\myquestiontext}
+\htmlregister{\pangramme}
+\htmlregister{\myfeedback}
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of the \texttt{babel} package 
+with option \texttt{french} that causes problems during \texttt{pdfLaTeX} 
+compilation, due to autospacing.
+
+Secondarily, the use of \verb|\textsuperscript| (and french adaptation 
+\verb|\fup|), \verb|\textsubscript|, \verb|\textsc|, \verb|\underline|, 
+\verb|\url|, and \verb|\href| is also demonstrated.
+
+\begin{quiz}[points=1]{French Issues}
+\ifPDFTeX
+  \NoAutoSpacing% this option preserves pdflatex compilation
+\fi
+\begin{multi}[feedback={1\fup{er}, M\fup{me}, N\fup{o}\\
+1\textsuperscript{er}, M\textsuperscript{me}, N\textsuperscript{o}\\
+H\textsubscript{2}O}]{Test french}
+\myquestiontext
+\item[feedback={\myfeedback}]* \pangramme
+\item Portez ce vieux whisky au juge blond qui fume.
+\end{multi}
+
+\end{quiz}
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_french.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_generalfeedback.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_generalfeedback.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_generalfeedback.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,103 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\usepackage[french]{babel} % for french quotes
+
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of general feedback.
+
+\begin{quiz}[points=1]{General Feedback Test}
+\ifPDFTeX
+  \NoAutoSpacing% this option preserves pdflatex compilation
+\fi
+
+\begin{multi}[feedback={multi}]{Title}
+%\og abc\fg%\ae%\oe%
+\AA
+\item[feedback={tic}] \ae
+\item[feedback={tac}]* \oe
+\end{multi}
+
+\begin{shortanswer}[feedback={shortanswer}]{Title}
+%	%\og abc\fg%\ae%\oe
+\AA
+\item[feedback={toc}] B
+\item[feedback={\og\fg}] C
+\item[fraction=0] *
+\end{shortanswer}
+
+\begin{numerical}[feedback={numerical}]{Title}
+%	%\og abc\fg%\ae%\oe
+\AA
+\item[feedback={toc}] 1
+\item[feedback={\og\fg}] 2
+\item[fraction=0] 3
+\end{numerical}
+
+\begin{matching}[feedback={matching}]{Title}
+%\og abc\fg%\ae%\oe%
+\AA
+\item \ae \answer oui
+\item \oe \answer non
+\item \answer \AA
+\end{matching}
+
+\begin{essay}[feedback={essay}]{Title}
+%\og abc\fg%\ae%\oe%
+\AA
+\item \ae yo
+\item \oe
+\end{essay}
+
+\begin{cloze}[feedback={54}]{Cloze}
+\AA
+\begin{multi}[shuffle=false]
+\OE
+\item[]* chip
+\item[feedback={yes},fraction=10] chop
+\item[feedback={no.}] chap
+\end{multi}
+\fg
+\begin{shortanswer}
+\AA
+\item[feedback={toc}] B
+\item[feedback={\og\fg}] C
+\item[fraction=0] *
+\end{shortanswer}
+\og
+\begin{numerical}
+\AA
+\item[] 1
+\item[feedback={\og\fg}] 2
+\item[fraction=0] 3
+\end{numerical}
+\begin{multi}[shuffle=false,vertical]
+\OE
+\item[feedback={yes}]* chip
+\item[fraction=10] chop
+\item[feedback={no.}] chap
+\end{multi}
+
+\begin{multi}[shuffle=false,horizontal]
+\OE
+\item[feedback={yes}]* chip
+\item[fraction=10] chop
+\item[feedback={no.}] chap
+\end{multi}
+
+\end{cloze}
+
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_generalfeedback.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_handout.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_handout.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_handout.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,159 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp,handout]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+%\RLsetrandomseed{3}
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of the package option 
+\texttt{handout}. With this option, the PDF file is clean from teacher-only 
+information (answers, points, penalty, feedback, tags) and, hence, can be given 
+to students for classroom work. In particular, as would Moodle do, 
+answers in \texttt{matching} questions are shuffled and the option 
+\texttt{shuffle} triggers the shuffling of choices offered (\texttt{multi} and 
+\texttt{matching}). The XML file is generated as usual.
+
+\begin{quiz}[points=1,tags={tag},feedback={General feedback},shuffle]{ Option 
+Handout}
+
+\begin{description}{Description}
+Description text
+\end{description}
+
+\begin{essay}{Essay}
+Question text
+\item A
+\item B
+\item C
+\end{essay}
+
+\begin{multi}[shuffle=false]{Multi Single}
+Question text
+\item[feedback={AAA}]* A
+\item[feedback={BBB},fraction=10] B
+\item[feedback={CCC}] C
+\end{multi}
+
+\begin{multi}[multiple]{Multi Multiple}
+Question text
+\item[feedback={AAA}]* A
+\item[feedback={BBB}] B
+\item[feedback={CCC}]* C
+\item[feedback={DDD}] D
+\end{multi}
+
+\begin{truefalse}{True/False 1}
+Question text
+\item[feedback={AAA}]
+\item[feedback={BBB}]*
+\end{truefalse}
+
+\begin{truefalse}{True/False 2}
+Question text
+\item*
+\end{truefalse}
+
+\begin{truefalse}{True/False 3}
+Question text
+\item
+\item*
+\end{truefalse}
+
+\begin{numerical}[tolerance=1]{Numerical}
+Question text
+\item[feedback={1}] 1
+\item[feedback={3},fraction=0] 3
+\end{numerical}
+
+\begin{shortanswer}[tolerance=1]{Short Answer}
+Question text
+\item[feedback={1}] aaa
+\item[feedback={3},fraction=0] bbb
+\end{shortanswer}
+
+\begin{matching}[dd]{Matching}
+Question text
+\item A \answer 1
+\item B \answer 2
+\item C \answer 3
+\item   \answer 4
+\end{matching}
+
+\begin{matching}[shuffle=false]{Matching}
+Question text
+\item A \answer 1
+\item B \answer 2
+\item C \answer 3
+\item   \answer 4
+\end{matching}
+
+\begin{cloze}{Cloze}
+
+\begin{multi}[horizontal,shuffle=false]
+Question text
+\item[feedback={AAA}]* A
+\item[feedback={BBB},fraction=10] B
+\item[feedback={CCC}] C
+\end{multi}
+
+\begin{multi}[vertical,shuffle=false]
+Question text
+\item[feedback={AAA}]* A
+\item[feedback={BBB},fraction=10] B
+\item[feedback={CCC}] C
+\end{multi}
+
+\begin{multi}[inline,shuffle=false]
+Question text
+\item[feedback={AAA}]* A
+\item[feedback={BBB},fraction=10] B
+\item[feedback={CCC}] C
+\end{multi}
+
+\begin{multi}[horizontal]
+Question text
+\item[feedback={AAA}]* A
+\item[feedback={BBB},fraction=10] B
+\item[feedback={CCC}] C
+\end{multi}
+
+\begin{multi}[vertical]
+Question text
+\item[feedback={AAA}]* A
+\item[feedback={BBB},fraction=10] B
+\item[feedback={CCC}] C
+\end{multi}
+
+\begin{multi}[inline]
+Question text
+\item[feedback={AAA}]* A
+\item[feedback={BBB},fraction=10] B
+\item[feedback={CCC}] C
+\end{multi}
+
+\begin{numerical}[tolerance=1]
+Question text
+\item[feedback={1}] 1
+\item[feedback={3},fraction=0] 3
+\end{numerical}
+
+\begin{shortanswer}[tolerance=1]
+Question text
+\item[feedback={1}] aaa
+\item[feedback={3},fraction=0] bbb
+\end{shortanswer}
+
+\end{cloze}
+
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_handout.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,45 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\usepackage{graphicx}
+
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of picture inclusion using 
+\verb|\includegraphics|. Only options \texttt{width} and \texttt{height} are 
+supported. The file name or path may include spaces. The file path can be 
+specified with \verb|\graphicspath|. In general, file extensions can be 
+omitted. However, with case-sensitive file-systems (like under Linux), files 
+with extensions in upper-case cannot be omitted.
+
+\begin{quiz}{Includegraphics}
+
+\begin{multi}{Picture}
+\includegraphics[width=2cm]{fig/1 1.PNG}
+\item[feedback={\includegraphics{fig/2 2.pdf}}]* \includegraphics{fig/3.gif}
+\item[feedback={\includegraphics{fig/4.jpg}}] \includegraphics{fig/5.jpeg}
+\end{multi}
+
+\graphicspath{{./fig/}}
+
+\begin{matching}[dd]{Picture}
+\includegraphics{1 1.PNG}
+% on Linux, if .PNG is omitted moodle tries to manipulate "fig/1 1.png"
+\item \includegraphics{2 2} \answer \includegraphics{3}
+\item \includegraphics{4} \answer \includegraphics{5}
+\item \includegraphics{3} \answer \includegraphics{2 2}
+\end{matching}
+
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_via_tikz.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_via_tikz.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_via_tikz.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,41 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp,tikz]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to experiment the support of picture inclusion using 
+\verb|\includegraphics| via \texttt{tikz}. All options are supported. The file 
+name or path may include spaces. The file path can be specified with 
+\verb|\graphicspath|. File extensions can be omitted.
+
+\begin{quiz}{Includegraphics with TikZ}
+
+\begin{multi}{Picture}
+\includegraphics[width=2em,angle=90]{fig/1 1.PNG}
+%\includegraphics{fig/1.png}
+\item* \includegraphics[scale=.5]{fig/2 2.pdf}
+\item \includegraphics{fig/3.gif}
+\end{multi}
+
+\graphicspath{{./fig/}}
+\begin{matching}[dd]{Picture}
+\includegraphics{1 1}
+\item \includegraphics[angle=45]{2 2} \answer \includegraphics{3}
+\item \includegraphics[angle=-45]{4} \answer \includegraphics{5}
+\item \includegraphics[scale=2]{3} \answer 
+\includegraphics[angle=-180,scale=2]{2 2}
+\end{matching}
+
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_via_tikz.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_via_tikz_and_svg.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_via_tikz_and_svg.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_via_tikz_and_svg.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,5 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\PassOptionsToPackage{svg}{moodle}
+\input{test_includegraphics_via_tikz.tex}
\ No newline at end of file


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_via_tikz_and_svg.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_with_svg.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_with_svg.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_with_svg.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,46 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp,svg]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check picture inclusion using 
+\verb|\includegraphics| together with the \texttt{svg} package option.
+When this option is used, vector graphics will be converted to SVG rather than 
+being rasterized. The picture inclusion using \verb|\includegraphics| is mostly 
+unchanged. If SVG files are included, they are converted on-the-fly to PDF.
+Conversions from and to SVG are performed using \textsf{Inkscape}. The 
+\textsf{Scour} utility is used to perform an optimization on intermediate SVG 
+files, before inclusion to the XML.
+
+\begin{quiz}{Scalable Vector Graphics}
+
+\begin{multi}{Picture}
+\includegraphics{fig/MoodlE_logo.SVG}
+\item[feedback={\includegraphics{fig/2 2.pdf}}]* \includegraphics{fig/3.gif}
+\item[feedback={\includegraphics{fig/4.jpg}}] \includegraphics{fig/5.jpeg}
+\end{multi}
+
+\graphicspath{{./fig/}}
+
+\begin{matching}[dd]{Picture}
+\includegraphics[width=2cm]{MoodlE_logo.SVG}
+% on Linux, if .SVG is omitted moodle tries to manipulate "MoodlE_logo.svg"
+\item \includegraphics{2 2} \answer \includegraphics{3}
+\item \includegraphics{4} \answer \includegraphics{5}
+\item \includegraphics{3} \answer \includegraphics[width=2em]{2 2}
+\end{matching}
+
+\end{quiz}
+
+\end{document}
\ No newline at end of file


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_includegraphics_with_svg.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_macros.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_macros.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_macros.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,39 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\usepackage{eurosym,textcomp} % for Euro symbol
+
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of some \LaTeX\ macros for 
+conversion to HTML.
+
+\begin{quiz}[points=1]{LaTeX Macros}
+\begin{multi}{LaTeX Macros}
+The following commands should not be placed in items: \\ and \par
+Find the \LaTeX\ logo
+\item* \TeX\ and \LaTeX
+\item (tilde)~and \#
+\item \$ and \&
+\item \& and \S
+\item \{ and \}
+\item (space)\ and \relax (relax)
+\item (space)\,and\thinspace(thinspace)
+\item \dots\ and \ldots
+\item \euro\ and \texteuro
+\item \TeX\ and \LaTeX
+\item \_ and \textbackslash
+\end{multi}
+
+\end{quiz}
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_macros.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_matching.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_matching.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_matching.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,39 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+%\RLsetrandomseed{3}
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of the matching question type.
+
+\begin{quiz}{Matching}
+
+\begin{matching}[dd]{Matching}
+Question text
+\item A \answer 1
+\item B \answer 2
+\item C \answer 3
+\item   \answer 4
+\end{matching}
+
+\begin{matching}[shuffle=false]{Matching}
+Question text
+\item A \answer 1
+\item B \answer 2
+\item C \answer 3
+\item   \answer 4
+\end{matching}
+
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_matching.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_mathenv.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_mathenv.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_mathenv.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,39 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\begin{document}
+\begin{quiz}{Example Quiz}
+\begin{multi}{Multiple Choice}
+\[\begin{array}{c}\$1\\2\end{array}\]
+
+$$\begin{array}{c}\$1\\2\end{array}$$
+
+\(\begin{array}{c}\$1\\2\end{array}\)
+\item[fraction=100]* $\$\sqrt{25}$
+\item 6
+\item[fraction=30,feedback={\[\$\sqrt{25}\]}]* 7
+\item[fraction=10] 8
+\end{multi}
+\begin{cloze}{Cloze}
+\begin{multi}[vertical	]
+\[\begin{array}{c}\$1\\2\end{array}\]
+
+$$\begin{array}{c}\$1\\2\end{array}$$
+
+\(\begin{array}{c}\$1\\2\end{array}\)
+\item[fraction=100]* $\$\sqrt{25}$
+\item 6
+\item[fraction=30,feedback={\[\$\sqrt{25}\]}]* 7
+\item[fraction=10] 8
+\end{multi}
+\end{cloze}
+\end{quiz}
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_mathenv.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_minted.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_minted.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_minted.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,128 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\usepackage{minted}
+\usemintedstyle{tango}
+%\RecustomVerbatimEnvironment{Verbatim}{LVerbatim}{}
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of the \textsf{minted} package.
+
+The only command supported is 
+\texttt{inputminted[<options>]\{<lang>\}\{<filename>\}}.
+
+\begin{quiz}{Minted}
+
+\setminted{numbersep=3ex,tabsize=4,numberblanklines=false,autogobble=true}
+
+\begin{VerbatimOut}{_minted-test_minted/test.tex}
+  % !TeX encoding = UTF-8
+  % !TeX spellcheck = en_US
+  % !TEX TS-program = xelatex
+  
+  \documentclass{article}
+  \usepackage[nostamp]{moodle}
+  \newif\iffvextra
+  \fvextratrue
+  \ifxetex % FOR XELATEX
+   \usepackage{fontspec}
+  \else %% FOR PDFLATEX
+  	\usepackage[utf8]{inputenc} % necessary
+  	\usepackage[T1]{fontenc} % necessary
+  \fi
+\end{VerbatimOut}
+\setminted[latex]{firstline=3,firstnumber=2,lastline=9,numbers=both,style=xcode}
+
+\begin{VerbatimOut}{_minted-test_minted/test.py}
+n = int(input('Type a number, and its factorial will be printed: '))
+
+if n < 0:
+    raise ValueError('non negative integer expected')
+
+fact = 1
+
+for i in range(2, n + 1):
+    fact *= i
+
+print(fact)
+\end{VerbatimOut}
+\setminted[python]{firstline=3,firstnumber=2,lastline=9,numbers=both,style=xcode}
+
+\begin{VerbatimOut}{_minted-test_minted/test.c}
+long some_function();
+/* int */ other_function();
+
+/* int */ calling_function()
+{
+    long test1;
+    register /* int */ test2;
+
+    test1 = some_function();
+    if (test1 > 0)
+          test2 = 0;
+    else
+          test2 = other_function();
+    return test2;
+}
+\end{VerbatimOut}
+\setminted[c]{style=tango,numberblanklines=true,highlightlines={2,4,7}}
+
+\begin{VerbatimOut}{_minted-test_minted/test.pl}
+#!/usr/bin/XXXX
+use strict;
+use warnings;
+use IO::Handle;
+
+my ( $remaining, $tot );
+
+$remaining = $tot = shift(@ARGV);
+
+STDOUT->autoflush(1);
+
+while ( $remaining ) {
+  printf ( "Remaining %s/%s \r", $remaining--, $tot );
+  sleep 1;
+}
+
+print "\n";
+\end{VerbatimOut}
+\setminted[perl]{firstline=1,firstnumber=1,lastline=19,numbers=left}
+
+\begin{numerical}[tolerance=0]{LaTeX Classes}
+In the following \LaTeX\ code excerpt, on which line is the class loaded?
+\inputminted{latex}{_minted-test_minted/test.tex}
+\item[feedback={yes! 
+\inputminted[highlightlines={3}]{latex}{_minted-test_minted/test.tex}},fraction=100]
+ 4
+\item[feedback={No. On line 3, there is only a comment.},fraction=0] 3
+\item[feedback={No. On line 5, the package \texttt{moodle} is 
+loaded.},fraction=0] 5
+\end{numerical}
+
+% To avoid collision of line and item numbers in PDF, force `left-right' mode:
+\RecustomVerbatimEnvironment{Verbatim}{LVerbatim}{frame=lines,
+    label={[Beginning of code]End of code},framesep=3mm,numbersep=9pt}%
+\begin{multi}{Languages}
+Select the code written in the Python language.
+\item[feedback={Indeed, this is Python code.}]* 
+\inputminted[highlightlines={2,4-5},numbers=both]{python}{_minted-test_minted/test.py}
+\item[feedback={No. This is Perl code.}]
+\inputminted[highlightlines={2,4-5},numbers=right,style=colorful]{perl}{_minted-test_minted/test.pl}
+\item[feedback={No. This is C code.}]
+\inputminted[numbers=left]{c}{_minted-test_minted/test.c}
+\end{multi}
+
+
+\end{quiz}
+
+\end{document}
\ No newline at end of file


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_minted.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_multi.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_multi.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_multi.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,55 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\def\myequation{$(1+\sqrt{5})/2$}
+\htmlregister{\myequation}
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of multi answers questions. The 
+following options are tested
+\begin{itemize}
+	\item Single or multiple correct answer
+	\item Shuffling or no shuffling
+\end{itemize}
+
+\begin{quiz}{Example Quiz}
+
+\begin{multi}{Multiple Choice}
+Text
+\item* A
+\item B
+\item C
+\end{multi}
+
+\begin{multi}[multiple,feedback={abc\\def $\sqrt{2}$}]{Multiple Choice}
+Select the following numbers that are prime.
+\item[fraction=70] $\sqrt{25}$
+\item[fraction=-10] \textbf{68}
+\item[fraction=30,feedback={$\sqrt{25}$}] 7
+\item[fraction=-70] 8
+\item \texttt{nothing}
+\end{multi}
+
+\begin{multi}[shuffle,feedback={abc\\def $\sqrt{2}$}]{Multiple Choice}
+Select the following numbers that are prime.
+\item* $\sqrt{25}$
+\item[fraction=-30] 6
+\item[fraction=-30,feedback={$\sqrt{25}$}] 9
+\item[fraction=-70] \begin{enumerate}
+\item False
+\item Wrong
+\end{enumerate}
+\end{multi}
+
+\end{quiz}
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_multi.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_multiple_categories.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_multiple_categories.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_multiple_categories.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,27 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = xelatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifxetex % FOR XELATEX
+	\usepackage{fontspec}
+\else %% FOR PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\fi
+\begin{document}
+\begin{quiz}{Category 1}
+\begin{multi}{Q1}
+Text 1
+\item* A
+\item B
+\end{multi}
+\end{quiz}
+\begin{quiz}{Category 2}
+\begin{multi}{Q2}
+Text 2
+\item* C
+\item D
+\end{multi}
+\end{quiz}
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_multiple_categories.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_penalty.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_penalty.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_penalty.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,21 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\begin{document}
+\begin{quiz}{Example}
+\begin{multi}[feedback={abc: def}]{Multiple Choice}
+abc: def
+\item[fraction=100]* abc: def
+\item 6
+\end{multi}
+
+\end{quiz}
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_penalty.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_point_points.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_point_points.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_point_points.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,27 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\begin{document}
+\begin{quiz}{Ifnum}
+\begin{multi}{MWE}
+\item* A
+\item B
+\end{multi}
+\begin{multi}[points=.5]{MWE}
+\item* A
+\item B
+\end{multi}
+\begin{multi}[points=3.2]{MWE}
+\item* A
+\item B
+\end{multi}
+\end{quiz}
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_point_points.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_special_characters.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_special_characters.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_special_characters.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,88 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\usepackage{libertine} % includes the "großes Eszett" ß
+
+\def\UTFdiacriticLC{å à â ã é è ë ê î ï ñ õ ô ö ù ü û ç }
+\def\UTFdiacriticUC{Å À Â Ã É È Ë Ê Î Ï Ñ Õ Ô Ö Ù Ü Û Ç }
+\def\UTFligaturesLC{}
+\def\UTFligaturesUC{}
+\def\UTFotherLC{}
+\def\UTFotherUC{}
+\def\UFTextend{
+  \newcommand\addtomacro[2]{\expandafter\def\expandafter##1\expandafter{##1##2}}%
+  \addtomacro{\UTFdiacriticLC}{ş ţ ő ű ÿ ă ĕ ğ ĭ ŏ ŭ č ď ě ľ ň ř š ť ž }%
+  \addtomacro{\UTFdiacriticUC}{Ş Ţ Ő Ű Ÿ Ă Ĕ Ğ Ĭ Ŏ Ŭ Č Ď Ě Ľ Ň Ř Š Ť Ž }%
+  \addtomacro{\UTFligaturesLC}{œ æ ß }%
+  \addtomacro{\UTFligaturesUC}{Œ Æ ẞ }%
+  \addtomacro{\UTFotherLC}{« ø ł » ¿ ¡ }%
+  \addtomacro{\UTFotherUC}{Ø Ł }%
+}
+\ifTUTeX % xetex and luatex compile fine the following in the XML
+  \UFTextend
+\fi
+\def\LaTeXdiacriticLC
+{\aa\ \`a \^a \~a \'e \`e \"e \^e \^i \"i \~n \~o \"o \^o \`u \"u \^u \c{c}
+\c{s} \c{t} \H{o} \H{u} \"y \u{a} \u{e} \u{g} \u{i} \u{\i} \u{o} \u{u} \v{c} 
+\v{d} \v{e} \v{l} \v{n} \v{r} \v{s} \v{t} \v{z} }
+\def\LaTeXdiacriticUC
+{\AA\ \`A \^A \~A \'E \`E \"E \^E \^I \"I \~N \~O \"O \^O \`U \"U \^U \c{C}
+\c{S} \c{T} \H{O} \H{U} \"Y \u{A} \u{E} \u{G} \u{I} \u{O} \u{U} \v{C} \v{D} 
+\v{E} \v{L} \v{N} \v{R} \v{S} \v{T} \v{Z} }
+\def\LaTeXligaturesLC{\oe\ \ae\ \ss\ }
+\def\LaTeXligaturesUC{\OE\ \AE\ \SS\ }
+\def\LaTeXotherLC{\guillemotleft\ \o\ \l\ \guillemotright\ \textquestiondown\ %
+\textexclamdown\ }
+\def\LaTeXotherUC{\O\ \L\ }
+
+\htmlregister{\UTFdiacriticLC}
+\htmlregister{\UTFdiacriticUC}
+\htmlregister{\LaTeXdiacriticLC}
+\htmlregister{\LaTeXdiacriticUC}
+\htmlregister{\UTFligaturesLC}
+\htmlregister{\UTFligaturesUC}
+\htmlregister{\LaTeXligaturesLC}
+\htmlregister{\LaTeXligaturesUC}
+\htmlregister{\UTFotherLC}
+\htmlregister{\UTFotherUC}
+\htmlregister{\LaTeXotherLC}
+\htmlregister{\LaTeXotherUC}
+
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of diacritical marks (accents) 
+and ligatures found in different languages written with the latin alphabet.
+
+For most of them, two ways of encoding are tested: UTF8 et \LaTeX{} syntax.
+
+\begin{quiz}[points=1]{Diacritical marks and ligatures}
+
+\begin{multi}{\UTFdiacriticUC}
+\UTFdiacriticLC\\
+\UTFdiacriticUC\\
+\UTFligaturesLC \UTFligaturesUC \UTFotherUC \UTFotherLC
+\item[feedback={\UTFdiacriticUC}] \UTFdiacriticLC
+\item[feedback={\UTFdiacriticLC}]* \UTFdiacriticUC
+\end{multi}
+
+\begin{multi}{\LaTeXdiacriticUC}
+\LaTeXdiacriticLC\\
+\LaTeXdiacriticUC\\
+\LaTeXligaturesLC \LaTeXligaturesUC \LaTeXotherUC \LaTeXotherLC
+\item[feedback={\LaTeXdiacriticUC}] \LaTeXdiacriticLC 
+\item[feedback={\LaTeXdiacriticLC}]* \LaTeXdiacriticUC
+\end{multi}
+
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_special_characters.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_tags.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_tags.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_tags.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,100 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\usepackage[french]{babel} % for french quotes
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of tags (i.e. keywords). The 
+definition of multiple tags per question is currently unsupported.
+
+\begin{quiz}[points=1,tags={quizz-level}]{Moodle Tags}
+	
+	\begin{multi}[tags={multiéàî}]{Title}
+		%\og abc\fg%\ae%\oe%
+		\AA
+		\item[feedback={tic}] \ae
+		\item[feedback={tac}]* \oe
+	\end{multi}
+	
+	\begin{shortanswer}[]{Title}
+		%	%\og abc\fg%\ae%\oe
+		\AA
+		\item[feedback={toc}] B
+		\item[feedback={\og\fg}] C
+		\item[fraction=0] *
+	\end{shortanswer}
+	
+	\begin{numerical}[tags={}]{Title}
+		%	%\og abc\fg%\ae%\oe
+		\AA
+		\item[feedback={toc}] 1
+		\item[feedback={\og\fg}] 2
+		\item[fraction=0] 3
+	\end{numerical}
+	
+	\begin{matching}[tags={m\aa tch\"ing}]{Title}
+		%\og abc\fg%\ae%\oe%
+		\AA
+		\item \ae \answer oui
+		\item \oe \answer non
+		\item \answer \AA
+	\end{matching}
+	
+	\begin{essay}[tags={essay}]{Title}
+		%\og abc\fg%\ae%\oe%
+		\AA
+		\item \ae yo
+		\item \oe
+	\end{essay}
+	
+	\begin{cloze}[tags={cloze}]{Cloze}
+		\AA
+		\begin{multi}[shuffle=false]
+			\OE
+			\item[]* chip
+			\item[feedback={yes},fraction=10] chop
+			\item[feedback={no.}] chap
+		\end{multi}
+		\fg
+		\begin{shortanswer}
+			\AA
+			\item[feedback={toc}] B
+			\item[feedback={\og\fg}] C
+			\item[fraction=0] *
+		\end{shortanswer}
+		\og
+		\begin{numerical}
+			\AA
+			\item[] 1
+			\item[feedback={\og\fg}] 2
+			\item[fraction=0] 3
+		\end{numerical}
+		\begin{multi}[shuffle=false,vertical]
+			\OE
+			\item[feedback={yes}]* chip
+			\item[fraction=10] chop
+			\item[feedback={no.}] chap
+		\end{multi}
+		
+		\begin{multi}[shuffle=false,horizontal]
+			\OE
+			\item[feedback={yes}]* chip
+			\item[fraction=10] chop
+			\item[feedback={no.}] chap
+		\end{multi}
+		
+	\end{cloze}
+	
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_tags.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_tikz.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_tikz.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_tikz.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,68 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp,tikz]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of picture
+inclusion using Ti\emph{k}Z.
+
+\begin{quiz}{TikZ}
+
+\begin{multi}{Multi}
+\embedaspict{1}
+\item[feedback={\embedaspict{2}}]* \embedaspict{3}
+\item[feedback={\embedaspict{4}}] \embedaspict{5}
+\end{multi}
+
+\begin{matching}[dd]{Matching}
+\embedaspict{1}
+\item \embedaspict{2} \answer \embedaspict{3}
+\item \embedaspict{4} \answer \embedaspict{5}
+\item \embedaspict{3} \answer \embedaspict{2}
+\end{matching}
+
+\begin{shortanswer}{Short}
+\embedaspict{1}
+\item[feedback={\embedaspict{2}}] 3
+\item[feedback={\embedaspict{4}}] 5
+\end{shortanswer}
+
+\begin{numerical}{Numerical}
+\embedaspict{1}
+\item[feedback={\embedaspict{2}}] 3
+\item[feedback={\embedaspict{4}}] 5
+\end{numerical}
+
+\begin{cloze}{Cloze}
+\begin{multi}[horizontal]
+\embedaspict{1}
+\item[feedback={\embedaspict{2}}]* \embedaspict{3}
+\item[feedback={\embedaspict{4}}] \embedaspict{5}
+\end{multi}
+
+\begin{shortanswer}
+\embedaspict{1}
+\item[feedback={\embedaspict{2}}] 3
+\item[feedback={\embedaspict{4}}] 5
+\end{shortanswer}
+
+\begin{numerical}
+\embedaspict{1}
+\item[feedback={\embedaspict{2}}] 3
+\item[feedback={\embedaspict{4}}] 5
+\end{numerical}
+\end{cloze}
+
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_tikz.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_tikz_with_svg.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_tikz_with_svg.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_tikz_with_svg.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,5 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\PassOptionsToPackage{svg}{moodle}
+\input{test_tikz.tex}
\ No newline at end of file


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_tikz_with_svg.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_tolerance.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_tolerance.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_tolerance.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,56 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\usepackage{siunitx}
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of the tolerance key for 
+numerical questions.
+
+\begin{quiz}[tolerance=0]{Tolerance}
+\begin{numerical}[tolerance=2]{Num 1}
+Give a number
+\item[tolerance=4] 1
+\item 0
+\item[fraction=0,feedback={nope}] *
+\end{numerical}
+\begin{numerical}{Num 2}
+Give a number
+\item[tolerance={1,65e-4}] 1,45E-3
+\item 0
+\item[fraction=0,feedback={nope}] *
+\end{numerical}
+\begin{cloze}[tolerance=2]{ClozeNum 1}
+\begin{numerical}[tolerance=3]
+Give a number
+\item[tolerance=4] 1
+\item 0
+\item[fraction=0,feedback={nope}] *
+\end{numerical}
+\begin{numerical}
+Give a number
+\item[tolerance=4] 1
+\item 0
+\item[fraction=0,feedback={nope}] *
+\end{numerical}
+\end{cloze}
+\begin{cloze}{ClozeNum 2}
+\begin{numerical}
+Give a number
+\item[tolerance={1,65E-4}] 1,45e-3
+\item 0
+\item[fraction=0,feedback={nope}] *
+\end{numerical}
+\end{cloze}
+\end{quiz}
+\end{document}
\ No newline at end of file


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_tolerance.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_truefalse.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_truefalse.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_truefalse.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,51 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of truefalse questions.
+
+The penalty keyword is overridden.
+
+\begin{quiz}[points=3]{Truefalse questions}
+
+\begin{truefalse}[feedback={general feedback},penalty=3]{Truefalse Test 1}
+This is a matching question.
+\item[feedback={Feedback for students choosing "true"}] this is discarded 
+because the feedback key is defined
+\item[]* Feedback for students choosing "false"
+\item* Extra items are ignored
+\end{truefalse}
+
+\begin{truefalse}[feedback={general feedback}]{Truefalse Test 2}
+This is an essay question.
+\item Feedback for students choosing "true"
+\item[feedback={Feedback for students choosing "false"}]*
+\end{truefalse}
+
+\begin{truefalse}[feedback={general feedback}]{Truefalse Test 3}
+Please answer "True".
+\item*
+%\item % if the correct answer is "true", the second item is optional
+\end{truefalse}
+
+\begin{truefalse}[feedback={general feedback}]{Truefalse Test 4}
+Please answer "False".
+\item % if the correct answer is "false", the first item is mandatory, even 
+%when it is not given any feedback
+\item*
+\end{truefalse}
+
+\end{quiz}
+
+\end{document}


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_truefalse.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/test_verbatim.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/test_verbatim.tex	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/test_verbatim.tex	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,48 @@
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = lualatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\ifPDFTeX % FOR LATEX and PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\else % assuming XELATEX or LUALATEX
+	\usepackage{fontspec}
+\fi
+\usepackage{verbatim}
+\begin{document}
+
+\section*{Introduction}
+
+This document is intended to check the support of verbatim environment.
+
+Outside of the scope of moodle questions, \texttt{filecontents} environments 
+can be set to define portions of code.
+
+\begin{quiz}{Verbatim}
+
+\begin{filecontents*}[overwrite]{test.log}
+% !TeX encoding = UTF-8
+% !TeX spellcheck = en_US
+% !TEX TS-program = xelatex
+\documentclass{article}
+\usepackage[nostamp]{moodle}
+\newif\iffvextra
+\fvextratrue
+\ifxetex % FOR XELATEX
+	\usepackage{fontspec}
+\else %% FOR PDFLATEX
+	\usepackage[utf8]{inputenc} % necessary
+	\usepackage[T1]{fontenc} % necessary
+\fi
+\end{filecontents*}
+
+\begin{multi}{Multi}
+\verbatiminput{test.log}
+\item[feedback={}]* test
+\item[feedback={}] toast
+\end{multi}
+
+\end{quiz}
+
+\end{document}
\ No newline at end of file


Property changes on: trunk/Master/texmf-dist/doc/latex/moodle/test/test_verbatim.tex
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_autopoints-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_autopoints-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_autopoints-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,117 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example Quiz</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[All correct]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>100\% is distributed uniformly. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="33.33333" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="33.33333" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="33.33333" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Auto sanction]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Without the star, an error shall be issued because correct answers should sum up to 100\%. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="-50" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="-50" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[All correct but sum \(\geq 100\)]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>A warning shall be issued because correct answers must sum up to 100\%. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="50" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="50" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="50" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Select the following numbers that are prime. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="20" format="html">
+    <text><![CDATA[<p>2</p>]]></text>
+  </answer>
+  <answer fraction="40" format="html">
+    <text><![CDATA[<p>5</p>]]></text>
+  </answer>
+  <answer fraction="40" format="html">
+    <text><![CDATA[<p>7</p>]]></text>
+  </answer>
+  <answer fraction="-50" format="html">
+    <text><![CDATA[<p>1</p>]]></text>
+  </answer>
+  <answer fraction="-25" format="html">
+    <text><![CDATA[<p>6</p>]]></text>
+  </answer>
+  <answer fraction="-25" format="html">
+    <text><![CDATA[<p>8</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_calculated_lua-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_calculated_lua-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_calculated_lua-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example Quiz</text>
+  </category>
+</question>
+ 
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Arithmetic Quiz (3, 2)]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Solve the following tasks!<BR/> \(3 + 2 =\){1:NUMERICAL:=5:0}\(3 - 2 =\){1:NUMERICAL:=1:0}\(3 * 2 =\){1:NUMERICAL:=6:0}</p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[calculated]]></text></tag>
+  </tags>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Arithmetic Quiz (4, 2)]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Solve the following tasks!<BR/> \(4 + 2 =\){1:NUMERICAL:=6:0}\(4 - 2 =\){1:NUMERICAL:=2:0}\(4 * 2 =\){1:NUMERICAL:=8:0}\(4 : 2 =\){1:NUMERICAL:=2:0}</p>]]></text>
+  </questiontext>
+  <defaultgrade>4</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[calculated]]></text></tag>
+  </tags>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Arithmetic Quiz (4, 3)]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Solve the following tasks!<BR/> \(4 + 3 =\){1:NUMERICAL:=7:0}\(4 - 3 =\){1:NUMERICAL:=1:0}\(4 * 3 =\){1:NUMERICAL:=12:0}</p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[calculated]]></text></tag>
+  </tags>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_calculated_python-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_calculated_python-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_calculated_python-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example Quiz</text>
+  </category>
+</question>
+ 
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Arithmetic Quiz (3, 2)]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Solve the following tasks!<BR/> \(3 + 2 =\){1:NUMERICAL:=5:0}\(3 - 2 =\){1:NUMERICAL:=1:0}\(3 * 2 =\){1:NUMERICAL:=6:0}</p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[calculated]]></text></tag>
+  </tags>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Arithmetic Quiz (4, 2)]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Solve the following tasks!<BR/> \(4 + 2 =\){1:NUMERICAL:=6:0}\(4 - 2 =\){1:NUMERICAL:=2:0}\(4 * 2 =\){1:NUMERICAL:=8:0}\(4 : 2 =\){1:NUMERICAL:=2:0}</p>]]></text>
+  </questiontext>
+  <defaultgrade>4</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[calculated]]></text></tag>
+  </tags>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Arithmetic Quiz (4, 3)]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Solve the following tasks!<BR/> \(4 + 3 =\){1:NUMERICAL:=7:0}\(4 - 3 =\){1:NUMERICAL:=1:0}\(4 * 3 =\){1:NUMERICAL:=12:0}</p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[calculated]]></text></tag>
+  </tags>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_categories-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_categories-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_categories-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,200 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Examples</text>
+  </category>
+</question>
+ 
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Examples/Generic</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>A </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>D</p>]]></text>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>One </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>0</tolerance>
+  </answer>
+</question>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Examples/Very Specific</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>A </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>D</p>]]></text>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>One </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>0</tolerance>
+  </answer>
+</question>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Other Category</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>A </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>D</p>]]></text>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>One </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>0</tolerance>
+  </answer>
+</question>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Other Category/Other Subcategory</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>A </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>D</p>]]></text>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>One </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>0</tolerance>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_circuitikz-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_circuitikz-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_circuitikz-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,124 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Circuitikz</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAU4AAACyCAMAAAAaqtaNAAAAS1BMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 
+AADXrLZzAAAAGHRSTlMAESIzRFVmd3qImaeqtLu/zM3d3+7v8Pi3xGZ7AAAF7UlEQVR42u3c7Zak 
+JhAG4AJLDYxhjSFJ3f+V5oeemVagP2Yt6OO8/tvdma3uB6gCBYm+cclPupi0L6EWV6Oo4AQnOMEJ 
+TnCCE5zgBCc4wQlOcIITnOAEJzjBCU5wghOc4AQnOMEJTnCCE5zgBCc4wQlOcIITnOAEJzjBCU5w 
+ghOc4AQnOMEJTnCCE5zgBCc4wQlOcIITnOAEJzjBqRrVmRZR/7QX5ZTYALRC1DacHFqAWq8etQ3n 
+BjrUjmq1m7EV5wq6DG3GxQU5iXhpBaoWtSUn0bCILNwElC/ISWYWcfWjBq2oTTmtjyJz7d5pXVTo 
+nYZHF4KEyY3cBJO9iEy1Y3deREJ/cguN0+7NltNQexI4BBHxtnYTBhHx3cn/6SwiMrmRmZlHt/6x 
+Yj8xw9JiHr9Gtee3UPS92X29SUSmSn1lTV61Z0jGRZFlPLkJjReJYyGar9BfVJLXk1Xv9CbsYnGQ 
+GS8ya3dQleTVrOoN8SC2a69ulqj6TVWSV7uq50T8vtnEHue3ajlNJ3k1rHqjyCFr/iUfCbhOWjM6 
+yeupJtSJyknXsyL/maOnznhnkVh/ucAiUanqdTFZqHqRzN8tGiOjWxqMdLJqI93MMlHSOUX+McnP 
+BdShJ8rQbDKdM0mnZKJWObrQLMnE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KI902OXtw8pSi9TGtXda8wHFhMzU+REh0qePCzY+4npm83uJmwfEAdqh4APtKx4W/vlSj1wNc 
+6rjwvsHqv7yi0UGYilWv4qtVLnZcuC1nF691iLAx5+WOuLblbHoA21yO8/yTZ09GrfpSnLpv+bp8 
+Nar90rSGh4ZrPJyq/w4664sbLbRn8td8lbR1LaIahxednxsVnOAEJzjBCU5wghOc4AQnOMEJTnCC 
+E5zgBCc4wQlOcIITnOAEJzjBCU5wghOc4AQnOMEJTnCCE5zgBCc4wQlOcIITnOAEJzjBCU5wghOc 
+4AQnOMEJTnCCE5zgBOdP4Yzyg66XOP8Hdt63PieF0vUAAAAASUVORK5CYII= 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAU4AAACyCAMAAAAaqtaNAAAAS1BMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 
+AADXrLZzAAAAGHRSTlMAESIzRFVmd3qImaeqtLu/zM3d3+7v8Pi3xGZ7AAAF7UlEQVR42u3c7Zak 
+JhAG4AJLDYxhjSFJ3f+V5oeemVagP2Yt6OO8/tvdma3uB6gCBYm+cclPupi0L6EWV6Oo4AQnOMEJ 
+TnCCE5zgBCc4wQlOcIITnOAEJzjBCU5wghOc4AQnOMEJTnCCE5zgBCc4wQlOcIITnOAEJzjBCU5w 
+ghOc4AQnOMEJTnCCE5zgBCc4wQlOcIITnOAEJzjBqRrVmRZR/7QX5ZTYALRC1DacHFqAWq8etQ3n 
+BjrUjmq1m7EV5wq6DG3Gx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ktmly04+ 
+d5xvMI0vJa/0O46jOS13FqpeMaqZ8jMaYSL6vMPQfpHJpeRV/oVzor70oMg4QzaHPw1E5jMNtL8F 
+0pDz+Rl0NzGzy3Ga0NuvhZMt5MICp8YNOp6eHOxbxpvEuYqDfcuJIlJoRmZz2934BU6d28f3SlHl 
+BdjvXi4/2gucWg837k6Uat4e+O02Sh+9lTk1H7012rwwv5q6H3bP8DTnovrkrW+zK/6l1P24x8dc 
+9sxyKm5b+E59eM/UndlUk+fU21SjXB+qpm4zZ6pRhlNty5d6faibujMbEnOcShsSa9SHuqk73S6b 
+4XTK2+PT+lD9zHDnM/sGv3GNyWdPVlRqm7nLY6/+EdfhpIO1yVGDZGVas7M0OnswnrcjeYi5+v45 
+CuaKI902OXtw8pSi9TGtXda8wHFhMzU+REh0qePCzY+4npm83uJmwfEAdqh4APtKx4W/vlSj1wNc 
+6rjwvsHqv7yi0UGYilWv4qtVLnZcuC1nF691iLAx5+WOuLblbHoA21yO8/yTZ09GrfpSnLpv+bp8 
+Nar90rSGh4ZrPJyq/w4664sbLbRn8td8lbR1LaIahxednxsVnOAEJzjBCU5wghOc4AQnOMEJTnCC 
+E5zgBCc4wQlOcIITnOAEJzjBCU5wghOc4AQnOMEJTnCCE5zgBCc4wQlOcIITnOAEJzjBCU5wghOc 
+4AQnOMEJTnCCE5zgBOdP4Yzyg66XOP8Hdt63PieF0vUAAAAASUVORK5CYII= 
+"></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>toast</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAU4AAACyCAMAAAAaqtaNAAAAS1BMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 
+AADXrLZzAAAAGHRSTlMAESIzRFVmd3qImaeqtLu/zM3d3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]]></text></feedback>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_cloze_multi-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_cloze_multi-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_cloze_multi-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Cloze Multi</text>
+  </category>
+</question>
+ 
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Regular, single, no shuffle {1:MULTICHOICE:=chip#yes~%10%<I>chop</I>~%-30%<B>chap</B>#no.}</P><P>Vertical, single, no shuffle {1:MULTICHOICE_V:=chip#yes~%10%chop~chap#no.}</P><P>Horizontal, single, no shuffle {1:MULTICHOICE_H:=chip#yes~%10%chop~chap#no.}</P><P>Regular, single, shuffle {1:MULTICHOICE_S:=chip~chop#yes~chap#no.}</P><P>Vertical, single, shuffle {1:MULTICHOICE_VS:=chip#yes~%10%chop~chap#no.}</P><P>Horizontal, single, shuffle {1:MULTICHOICE_HS:=chip#yes~chop~chap#no.}</P><P>Regular, multiple, no shuffle {1:MULTIRESPONSE:=chip~=chop#yes~chap#no.}</P><P></P><P>Horizontal, multiple, no shuffle {1:MULTIRESPONSE_H:=chip#yes~=chop~chap#no.}</P><P>Regular, multiple, shuffle {1:MULTIRESPONSE_S:=chip~=chop#yes~chap#no.}Horizontal, multiple, shuffle {1:MULTIRESPONSE_HS:=chip#yes~=chop~chap#no.}</P><P></p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_cloze_numerical-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_cloze_numerical-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_cloze_numerical-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Close Short Answer</text>
+  </category>
+</question>
+ 
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Enter an integer \(n\) such that \(0< n\leq 2\). {1:NUMERICAL:%10%0:0.001#study difference between \(<\) and \(\leq \)~=1:0.01#good!~=2:0.1#OK}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_cloze_shortanswer-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_cloze_shortanswer-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_cloze_shortanswer-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Close Short Answer</text>
+  </category>
+</question>
+ 
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Who? {1:SHORTANSWER_C:=chip~%10%chop#yes~%-30%chap#no.}what? {1:SHORTANSWER:=chip~%10%chop#yes~%-30%chap#no.}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_commands-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_commands-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_commands-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/LaTeX Commands</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[LaTeX Commands]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Find the answer with small capitals </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><EM>emphasis</EM></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><B>bold</B></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><I>italic</I></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><CODE>typewriter</CODE></p>]]></text>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><SPAN STYLE="font-variant: small-caps;">Small Capitals</SPAN></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><SPAN STYLE="text-decoration: underline;">underlined</SPAN></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>M<SUP>me</SUP></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>H<SUB>2</SUB>O</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><A href="http://192.0.0.256">http://192.0.0.256</A></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><A href="mailto:name at server.com">Contact me</A></p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_description-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_description-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_description-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example Quiz</text>
+  </category>
+</question>
+ 
+<question type="description">
+  <name format="html">
+    <text><![CDATA[Requirements]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>This is a description. Not really a question. We can include environments and math. <UL><LI>This</LI><LI>That</LI></UL> \[\mathrm {e}^{2\mathrm {i}\pi }+1=0.\]</p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>here is a feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[descr]]></text></tag>
+  </tags>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_environments-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_environments-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_environments-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/LaTeX Environments</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[LaTeX Environments]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><CENTER><SPAN STYLE="font-variant: small-caps;">This is a question</SPAN></CENTER> Select the numbered list </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><OL><LI>C</LI><LI>D <UL><LI>S</LI><LI>T</LI><LI>U</LI></UL></LI></OL></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>yes</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><UL><LI>E <OL><LI>X</LI><LI>Y</LI><LI>Z</LI></OL></LI><LI>F</LI></UL></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>Example of numbered list:<BR/><OL><LI>first item</LI><LI>second item</LI></OL></p>]]></text></feedback>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_escaping_right_braces_in_cloze-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_escaping_right_braces_in_cloze-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_escaping_right_braces_in_cloze-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Cloze: Escaping Characters</text>
+  </category>
+</question>
+ 
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>No escaping here: \(y=a\sqrt {x}/2+{b}\) </P><P>No escaping here: <CODE>text</CODE> \(y=a\sqrt {x}/2+{b}\) {4:MULTICHOICE_V:=\(\lbrace A\rbrace \)~{B\}}</P><P>{No escaping here: } \(y=a\sqrt {x}/2+{b}\) {1:SHORTANSWER:=chip#nip~%10%nop#that must be escaped: \(y=a\sqrt {x\}/2+{b\}\)}</P><P>{No escaping here: } \(y=a\sqrt {x}/2+{b}\) {1:NUMERICAL:=0:0#nip~%10%1:0#that must be escaped: \(y=a\sqrt {x\}/2+{b\}\)}</P><P></p>]]></text>
+  </questiontext>
+  <defaultgrade>2</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_essay-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_essay-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_essay-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Essay Test</text>
+  </category>
+</question>
+ 
+<question type="essay">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>A </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>feedback for essay</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <responserequired>0</responserequired>
+  <responseformat>editor</responseformat>
+  <responsefieldlines>15</responsefieldlines>
+  <attachments>0</attachments>
+  <attachmentsrequired>0</attachmentsrequired>
+  <graderinfo format="html"><text><![CDATA[
+    <ul>
+      <li>B </li>
+      <li>C</li>
+    </ul>
+  ]]></text></graderinfo>
+  <responsetemplate format="html">
+    <text><![CDATA[Type you answer here]]></text>
+  </responsetemplate>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_expandnewcommands-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_expandnewcommands-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_expandnewcommands-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Recording New Commands for Expansion</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Sets]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Standard notation for the set of natural integers: </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>\(\mathbb {N}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\mathbb {Z}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\mathbb {Q}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\mathbb {C}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\mathbb {R}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\mathbb {V}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\vphantom {K}^\dagger \mathbb {K}^*_2\)</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_fancyvrb-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_fancyvrb-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_fancyvrb-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Fancy Verbatim</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Pick up the code decorated with line numbering on both sides. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">2</span><mark>% !TEX TS-program = xelatex</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">2</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right"> </span><mark></mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">3</span><mark>\documentclass{article}</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">3</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">4</span><mark>\usepackage[nostamp]{moodle}</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">4</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">5</span><mark>\newif\iffvextra</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">5</span><BR/></CODE></PRE></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>No. Here, line numbers lie on the left side.</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE>% !TEX TS-program = xelatex<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">6</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">7</span><BR/><mark>\documentclass{article}</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">8</span><BR/>\usepackage[nostamp]{moodle}<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">9</span><BR/>\newif\iffvextra<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">10</span><BR/></CODE></PRE></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>No. Here, line numbers lie on the right side.</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">4</span><mark>\ifxetex % FOR XELATEX</mark><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">5</span><mark> \usepackage{fontspec}</mark><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">6</span>\else %% FOR PDFLATEX<BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">7</span>    \usepackage[utf8]{inputenc} % necessary<BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">8</span><mark>    \usepackage[T1]{fontenc} % necessary</mark><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">9</span>\fi<BR/></CODE></PRE></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>yes!</p>]]></text></feedback>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_fractions-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_fractions-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_fractions-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example Quiz</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Select the following numbers that are prime. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>abc<BR/>def \(\sqrt {2}\)</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="83.33333" format="html">
+    <text><![CDATA[<p>\(\sqrt {25}\)</p>]]></text>
+  </answer>
+  <answer fraction="-66.66667" format="html">
+    <text><![CDATA[<p><B>68</B></p>]]></text>
+  </answer>
+  <answer fraction="16.66667" format="html">
+    <text><![CDATA[<p>7</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>\(\sqrt {25}\)</p>]]></text></feedback>
+  </answer>
+  <answer fraction="33.33333" format="html">
+    <text><![CDATA[<p>8</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><CODE>nothing</CODE></p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_french-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_french-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_french-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/French Issues</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Test french]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p> <SPAN STYLE="text-decoration: underline;">Pangramme</SPAN> conçu par Gilles <SPAN STYLE="font-variant: small-caps;">Esposito-Farèse</SPAN>:</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>1<SUP>er</SUP>, M<SUP>me</SUP>, N<SUP>o</SUP><BR/> 1<SUP>er</SUP>, M<SUP>me</SUP>, N<SUP>o</SUP><BR/> H<SUB>2</SUB>O</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>Dès Noël où un zéphyr haï me vêt de glaçons würmiens je dîne d’exquis rôtis de bœuf au kir à l’aÿ d’âge mûr & cætera !</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>cité dans « <A href="https://jacques-andre.fr/faqtypo/lessons.pdf">Petites leçons de typographie</A> » de Jacques <SPAN STYLE="font-variant: small-caps;">André</SPAN>.</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>Portez ce vieux whisky au juge blond qui fume.</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_generalfeedback-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_generalfeedback-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_generalfeedback-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,157 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/General Feedback Test</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>multi</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>æ</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>tic</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>œ</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>tac</p>]]></text></feedback>
+  </answer>
+</question>
+<question type="shortanswer">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>shortanswer</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <usecase>0</usecase>
+  <answer fraction="100" format="plain_text">
+    <text>B</text>
+    <feedback format="html"><text><![CDATA[<p>toc</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>C</text>
+    <feedback format="html"><text><![CDATA[<p>«  »</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>*</text>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>numerical</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>toc</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>2</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>«  »</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>3</text>
+    <tolerance>0</tolerance>
+  </answer>
+</question>
+<question type="matching">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>matching</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p>æ</p>]]></text>
+    <answer><text>oui</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>œ</p>]]></text>
+    <answer><text>non</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text></text>
+    <answer><text>Å</text></answer>
+  </subquestion>
+</question>
+<question type="essay">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>essay</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <responserequired>0</responserequired>
+  <responseformat>editor</responseformat>
+  <responsefieldlines>15</responsefieldlines>
+  <attachments>0</attachments>
+  <attachmentsrequired>0</attachmentsrequired>
+  <graderinfo format="html"><text><![CDATA[
+    <ul>
+      <li>æyo </li>
+      <li>œ</li>
+    </ul>
+  ]]></text></graderinfo>
+  <responsetemplate format="html"><text/></responsetemplate>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>ÅŒ{1:MULTICHOICE:=chip~%10%chop#yes~chap#no.} »Å{1:SHORTANSWER:=B#toc~=C#«  »~*}« Å{1:NUMERICAL:=1:0~=2:0#«  »~3:0}Œ{1:MULTICHOICE_V:=chip#yes~%10%chop~chap#no.}</P><P>Œ{1:MULTICHOICE_H:=chip#yes~%10%chop~chap#no.}</P><P></p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>54</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_handout-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_handout-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_handout-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,336 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/ Option Handout</text>
+  </category>
+</question>
+ 
+<question type="description">
+  <name format="html">
+    <text><![CDATA[Description]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Description text</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="essay">
+  <name format="html">
+    <text><![CDATA[Essay]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <responserequired>0</responserequired>
+  <responseformat>editor</responseformat>
+  <responsefieldlines>15</responsefieldlines>
+  <attachments>0</attachments>
+  <attachmentsrequired>0</attachmentsrequired>
+  <graderinfo format="html"><text><![CDATA[
+    <ul>
+      <li>A </li>
+      <li>B </li>
+      <li>C</li>
+    </ul>
+  ]]></text></graderinfo>
+  <responsetemplate format="html"><text/></responsetemplate>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi Single]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>0</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>AAA</p>]]></text></feedback>
+  </answer>
+  <answer fraction="10" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>BBB</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>CCC</p>]]></text></feedback>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi Multiple]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="50" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>AAA</p>]]></text></feedback>
+  </answer>
+  <answer fraction="-50" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>BBB</p>]]></text></feedback>
+  </answer>
+  <answer fraction="50" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>CCC</p>]]></text></feedback>
+  </answer>
+  <answer fraction="-50" format="html">
+    <text><![CDATA[<p>D</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>DDD</p>]]></text></feedback>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[True/False 1]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="0" format="plain_text">
+    <text>true</text>
+    <feedback format="html"><text><![CDATA[<p>AAA</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>false</text>
+    <feedback format="html"><text><![CDATA[<p>BBB</p>]]></text></feedback>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[True/False 2]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>true</text>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>false</text>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[True/False 3]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="0" format="plain_text">
+    <text>true</text>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>false</text>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>1</tolerance>
+    <feedback format="html"><text><![CDATA[<p>1</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>3</text>
+    <tolerance>1</tolerance>
+    <feedback format="html"><text><![CDATA[<p>3</p>]]></text></feedback>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="shortanswer">
+  <name format="html">
+    <text><![CDATA[Short Answer]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <usecase>0</usecase>
+  <answer fraction="100" format="plain_text">
+    <text>aaa</text>
+    <feedback format="html"><text><![CDATA[<p>1</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>bbb</text>
+    <feedback format="html"><text><![CDATA[<p>3</p>]]></text></feedback>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Matching]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+    <answer format="html"><text><![CDATA[<p>1</p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+    <answer format="html"><text><![CDATA[<p>2</p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+    <answer format="html"><text><![CDATA[<p>3</p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text></text>
+    <answer format="html"><text><![CDATA[<p>4</p>]]></text></answer>
+  </subquestion>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="matching">
+  <name format="html">
+    <text><![CDATA[Matching]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>0</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+    <answer><text>1</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+    <answer><text>2</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+    <answer><text>3</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text></text>
+    <answer><text>4</text></answer>
+  </subquestion>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p></P><P>Question text {1:MULTICHOICE_H:=A#AAA~%10%B#BBB~C#CCC}</P><P>Question text {1:MULTICHOICE_V:=A#AAA~%10%B#BBB~C#CCC}</P><P>Question text {1:MULTICHOICE:=A#AAA~%10%B#BBB~C#CCC}</P><P>Question text {1:MULTICHOICE_HS:=A#AAA~%10%B#BBB~C#CCC}</P><P>Question text {1:MULTICHOICE_VS:=A#AAA~%10%B#BBB~C#CCC}</P><P>Question text {1:MULTICHOICE_S:=A#AAA~%10%B#BBB~C#CCC}</P><P>Question text {1:NUMERICAL:=1:1#1~3:1#3}</P><P>Question text {1:SHORTANSWER:=aaa#1~bbb#3}</P><P></p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>General feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[tag]]></text></tag>
+  </tags>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,523 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Includegraphics</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG width=81 SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAQCAYAAAAvf+5AAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz 
+AAAN1wAADdcBQiibeAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAABhSURB 
+VCiR7dIxDkVgFEThj6jsxhp0Wlt6jY1o1NbBAlQKveLVNH8EIdFpTHKamzNTXSjxQ4sJS6BwynLD 
+QUxQo0cXGJGe167yv1qMnzQ/8QUxQoV8d8vCwIB5LzfuP2hjBTnvHcSzvuJGAAAAAElFTkSuQmCC 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/gif;base64,R0lGODlhCwARAOcAAAAAAAEBAQICAgMDAwQEBAUFBQYGBgcHBwgICAkJCQoKCgsLCwwMDA0NDQ4O 
+Dg8PDxAQEBERERISEhMTExQUFBUVFRYWFhcXFxgYGBkZGRoaGhsbGxwcHB0dHR4eHh8fHyAgICEh 
+ISIiIiMjIyQkJCUlJSYmJicnJygoKCkpKSoqKisrKywsLC0tLS4uLi8vLzAwMDExMTIyMjMzMzQ0 
+NDU1NTY2Njc3Nzg4ODk5OTo6Ojs7Ozw8PD09PT4+Pj8/P0BAQEFBQUJCQkNDQ0REREVFRUZGRkdH 
+R0hISElJSUpKSktLS0xMTE1NTU5OTk9PT1BQUFFRUVJSUlNTU1RUVFVVVVZWVldXV1hYWFlZWVpa 
+WltbW1xcXF1dXV5eXl9fX2BgYGFhYWJiYmNjY2RkZGVlZWZmZmdnZ2hoaGlpaWpqamtra2xsbG1t 
+bW5ubm9vb3BwcHFxcXJycnNzc3R0dHV1dXZ2dnd3d3h4eHl5eXp6ent7e3x8fH19fX5+fn9/f4CA 
+gIGBgYKCgoODg4SEhIWFhYaGhoeHh4iIiImJiYqKiouLi4yMjI2NjY6Ojo+Pj5CQkJGRkZKSkpOT 
+k5SUlJWVlZaWlpeXl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AAAACwARAAAI 
+MwABCBwo8J/BgwcHIlyocKFBgg7/NWQ4keBEiRYjPiyo8SJFAB05foxosSRHkyATlkQYEAAh+QQJ 
+CgD/ACwAAAAACwARAAAINAABCBwo8J/BgwcHIlyocKFBgg7/NWRYMCFBABQhRpRYMeJEhx8Rhnw4 
+8qLJiicxWryIMCAAIfkECQoA/wAsAAAAAAsAEQAACDQAAQgcKPCfwYMHByJcqHChwYYOISKUSBBA 
+xIoOExbM+E8iw40XLYYUObGiSZEnSXY0iTAgACH5BAkKAP8ALAAAAAALABEAAAg0AAEIHCjwn8GD 
+BwciXKhwocGGDiEilEgQQMSKDhMWzPhPIsONFy1m9NixosmCJ0U+NIkwIAAh+QQJCgD/ACwAAAAA 
+CwARAAAIMwABCBwo8J/BgwcHIlyocKHBhg4hIpRIEEDEig4TFsz4TyLDjRctZvTYsaLJjScnmkQY 
+EAAh+QQJCgD/ACwAAAAACwARAAAIMwABCBwo8J/BgwcHIlyocKHBhg4hIpRIEEDEig4TFsz4TyLD 
+jRlBfrQ4sqLJhyc1YjwYEAAh+QQJCgD/ACwAAAAACwARAAAINAABCBwo8J/BgwcHIlyocKHBhg4h 
+IpRIEEDEig4TFsz4TyLDjRctZvT4sKJJkSdFdjSJMCAAIfkECQoA/wAsAAAAAAsAEQAACDQAAQgc 
+KPCfwYMHByJcqHChwYYOISKUSBBAxIoOExbM+E8iw40XLWb0+LCiSZEnRXY0iTAgACH5BAEKAP8A 
+LAAAAAALABEAAAgyAAEIHCjwn8GDBwciXKhwoUGCDv81ZFgwIUSKFyNOdLgRY0SJFTEC4Eiw5EWT 
+IVEiDAgAOw== 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG  SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHsAAADICAQAAABikFYvAAAX6klEQVR42u1d2XbjSK4EV8nu7vn/ 
+H71lSdzuQyYSEUBSLlVr85khj+0qLxKDQAIBJAA2gkcrnXTSSy+9DDLKIKMcZJSDH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egxNDVgq 
+eQ6nruwIWgD070r7AUtAYXN6ARMMPrzUmSfWnWVZbw4oLS/WFMj2hOw/l/ZdYP9DsK0a3Agqj1zE 
+sMM7Lp8bszWtoNtQXPUik/YfkSBvHLZp88nUhtfKq+K0k7WsX1PulmRtsPHrk2D/XcKA1ik6DkzW 
+aXSr8GaeMbQ50JOthLRNtuIdyNrT0idL+2/hDSBMFvcuruYJ4Ah9CQRUb6VII6u01F8r4snpk49e 
+/pLaTEIchs02HAcl4/NxfZuKQV4Fn6+4x7yf+oznXj4Idu0xB/iwkq0wcjxiWf0G/+Lz1U/6zbCP 
+tIFvj5vqCkHhdlO9NX6TUPVEDVksfa4+LVdeoui9HMtbW/uxPYvH5r3rheNTXXg6kt2UpaLS8fNL 
+YY+hekEV3T5bYLhJJ4uDOxRiklrUbdrJez3I2sGul23wYyKbIjnMsQ7FQ6t/9g+Yk/LKbwZ7IMLA 
+s+tsFQvAVs+Oe9GNtNK7WoQnxM3/BrZdmgeOT781c7RKL6ssMpQAUkHvNR6+HfAetoMYOIM2v9pK 
+l4FvATQWxfpg460Og43QuSvEEnytSHZRlvVM/dq1RDDSzzcD3hc7bZcXn2udfrLJKq1sBTjOPxt2 
+e3beEngvHUEW8XVpeMFtAa6/l0DbZJu9Dry3Ap2k7S/LQMdouC2/g+UetW7LW+z4C+LtPdhSgd0A 
+GIONBbFMUrZ3k7KHbYDtK9ef6tEKMrkYfb1JsHELbA86aoHuZjSyUQzN9vtHwka4zc5PmxyE+hrg 
+G9vHXwc7Amuu/C99Z5OGJBul/ObAmz8ugNt2vv7u3/nreDLsN5fLY47237/ETzz+B/u/6fgf7P+m 
+4/8BfX6FOOHA2dwAAAAASUVORK5CYII= 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAARAAsBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABAYJCP/EACkQAAEDAwQBAgcBAAAAAAAAAAECAwUEBgcAERIhEwgUIjM4UXFysbL/ 
+2gAIAQEAAD8APx7E+mJivyZXZktB2qnV35PeWZqYKTepm2PfOBsrqWWyylI2VueXWx321RXFsZaM 
+XjyAprE9qqzkUqTFmNqPLTFg9p8auR3T313pGd9XeCKi135RzKtlvRJbIcbVL05WoFJPAslXMqIB 
++Djue+tYiw9hLOc5YzcpjuRdtKxJCQka2ChqhlTC6aidrX3GR4+uIKFJUB9lDS5fX1uW/wDl/wD2 
+zqsTPyW/1H81/9k= 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAAQAAwBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABQYHCP/EACcQAAEDBAEDAwUAAAAAAAAAAAIBAwQFBgcRCAASIRMUMjhRcXax/9oA 
+CAEBAAA/ANg8gpDmb59exXTn3Btql08596TIxECkBNkUamAYqmjdVEcd0u0aFEVE9ZFQ7wW+j7En 
+6/H/AJ1OaLx5zXi3HVxQoOYrbnty1nVOoy5llmUuc+73G4bjnvvlrQp40IiIomhROl/iDY+cKjxi 
+xrJoGU7YpFFcorBRIMyzjlOsN68CTqTQ71T79qfjr//Z 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAQCAYAAAAvf+5AAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz 
+AAAN1wAADdcBQiibeAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAABhSURB 
+VCiR7dIxDkVgFEThj6jsxhp0Wlt6jY1o1NbBAlQKveLVNH8EIdFpTHKamzNTXSjxQ4sJS6BwynLD 
+QUxQo0cXGJGe167yv1qMnzQ/8QUxQoV8d8vCwIB5LzfuP2hjBTnvHcSzvuJGAAAAAElFTkSuQmCC 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHsAAADICAQAAABikFYvAAAX6klEQVR42u1d2XbjSK4EV8nu7vn/ 
+H71lSdzuQyYSEUBSLlVr85khj+0qLxKDQAIBJAA2gkcrnXTSSy+9DDLKIKMcZJSDHOWQz2P50FN/ 
+Msoggwz577t8tuVspJVG6scmqyyyyCKTzDLJJJNc8nkuH+k8yVlO+fO5/HSSS/67WWaZZZFZFlll 
+kTWfGwKtH400lc/6L/0eX/gmW/m6le8K/GuTexx4Nftn7Rq/hc03IL6glM8MVQHjd/7siDdOwo1v 
+ywd+tuu0q/wt2A28SVPegD8bfAS+5o/N3Yp7yNmA2DUo3DaA9kL6BjarNL+4fvYvh6C3CvD7HXhN 
+6ezgawc3wAMn8P03b9AC3Na9KEPeiulY8//aP4C+0b/tL21ZRdDJdK7lY5U1/3QFNHQNBltfpKez 
+y7a9ZpcZuEJenCnZZJNWNliHrCv210s+Z1my/WWdsRWtkNO16Tv3BfYiXYGe/jrdrM1gt3T/zH3p 
+V3VJHUFvALiBXkgT0vfTBay0QJrqAlHQcwG+FOis4gq6DxqWbEuf/93md24i7DHA7jLYsXjioQK/ 
+Bhq/h7cCNaSl1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+oUGCDv81dDiRYEGEFgFEfHgx4kSKHRlq9BgyYcaMHFGatIgwIAAh+QQJCgD/ACwAAAAACwARAAAI 
+MwABCBwo8J/BgwcHIlyocKFBgg7/NWQ4keBEiRYjPiyo8SJFAB05foxosSRHkyATlkQYEAAh+QQJ 
+CgD/ACwAAAAACwARAAAINAABCBwo8J/BgwcHIlyocKFBgg7/NWRYMCFBABQhRpRYMeJEhx8Rhnw4 
+8qLJiicxWryIMCAAIfkECQoA/wAsAAAAAAsAEQAACDQAAQgcKPCfwYMHByJcqHChwYYOISKUSBBA 
+xIoOExbM+E8iw40XLYYUObGiSZEnSXY0iTAgACH5BAkKAP8ALAAAAAALABEAAAg0AAEIHCjwn8GD 
+BwciXKhwocGGDiEilEgQQMSKDhMWzPhPIsONFy1m9NixosmCJ0U+NIkwIAAh+QQJCgD/ACwAAAAA 
+CwARAAAIMwABCBwo8J/BgwcHIlyocKHBhg4hIpRIEEDEig4TFsz4TyLDjRctZvTYsaLJjScnmkQY 
+EAAh+QQJCgD/ACwAAAAACwARAAAIMwABCBwo8J/BgwcHIlyocKHBhg4hIpRIEEDEig4TFsz4TyLD 
+jRlBfrQ4sqLJhyc1YjwYEAAh+QQJCgD/ACwAAAAACwARAAAINAABCBwo8J/BgwcHIlyocKHBhg4h 
+IpRIEEDEig4TFsz4TyLDjRctZvT4sKJJkSdFdjSJMCAAIfkECQoA/wAsAAAAAAsAEQAACDQAAQgc 
+KPCfwYMHByJcqHChwYYOISKUSBBAxIoOExbM+E8iw40XLWb0+LCiSZEnRXY0iTAgACH5BAEKAP8A 
+LAAAAAALABEAAAgyAAEIHCjwn8GDBwciXKhwoUGCDv81ZFgwIUSKFyNOdLgRY0SJFTEC4Eiw5EWT 
+IVEiDAgAOw== 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAAQAAwBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABQYHCP/EACcQAAEDBAEDAwUAAAAAAAAAAAIBAwQFBgcRCAASIRMUMjhRcXax/9oA 
+CAEBAAA/ANg8gpDmb59exXTn3Btql08596TIxECkBNkUamAYqmjdVEcd0u0aFEVE9ZFQ7wW+j7En 
+6/H/AJ1OaLx5zXi3HVxQoOYrbnty1nVOoy5llmUuc+73G4bjnvvlrQp40IiIomhROl/iDY+cKjxi 
+xrJoGU7YpFFcorBRIMyzjlOsN68CTqTQ71T79qfjr//Z 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAARAAsBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABAYJCP/EACkQAAEDAwQBAgcBAAAAAAAAAAECAwUEBgcAERIhEwgUIjM4UXFysbL/ 
+2gAIAQEAAD8APx7E+mJivyZXZktB2qnV35PeWZqYKTepm2PfOBsrqWWyylI2VueXWx321RXFsZaM 
+XjyAprE9qqzkUqTFmNqPLTFg9p8auR3T313pGd9XeCKi135RzKtlvRJbIcbVL05WoFJPAslXMqIB 
++Djue+tYiw9hLOc5YzcpjuRdtKxJCQka2ChqhlTC6aidrX3GR4+uIKFJUB9lDS5fX1uW/wDl/wD2 
+zqsTPyW/1H81/9k= 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/gif;base64,R0lGODlhCwARAOcAAAAAAAEBAQICAgMDAwQEBAUFBQYGBgcHBwgICAkJCQoKCgsLCwwMDA0NDQ4O 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wAAAAACwARAAAIMwABCBwo8J/BgwcHIlyocKHBhg4hIpRIEEDEig4TFsz4TyLD 
+jRlBfrQ4sqLJhyc1YjwYEAAh+QQJCgD/ACwAAAAACwARAAAINAABCBwo8J/BgwcHIlyocKHBhg4h 
+IpRIEEDEig4TFsz4TyLDjRctZvT4sKJJkSdFdjSJMCAAIfkECQoA/wAsAAAAAAsAEQAACDQAAQgc 
+KPCfwYMHByJcqHChwYYOISKUSBBAxIoOExbM+E8iw40XLWb0+LCiSZEnRXY0iTAgACH5BAEKAP8A 
+LAAAAAALABEAAAgyAAEIHCjwn8GDBwciXKhwoUGCDv81ZFgwIUSKFyNOdLgRY0SJFTEC4Eiw5EWT 
+IVEiDAgAOw== 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG  SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHsAAADICAQAAABikFYvAAAX6klEQVR42u1d2XbjSK4EV8nu7vn/ 
+H71lSdzuQyYSEUBSLlVr85khj+0qLxKDQAIBJAA2gkcrnXTSSy+9DDLKIKMcZJSDHOWQz2P50FN/ 
+Msoggwz577t8tuVspJVG6scmqyyyyCKTzDLJJJNc8nkuH+k8yVlO+fO5/HSSS/67WWaZZZFZFlll 
+kTWfGwKtH400lc/6L/0eX/gmW/m6le8K/GuTexx4Nftn7Rq/hc03IL6glM8MVQHjd/7siDdOwo1v 
+ywd+tuu0q/wt2A28SVPegD8bfAS+5o/N3Yp7yNmA2DUo3DaA9kL6BjarNL+4fvYvh6C3CvD7HXhN 
+6ezgawc3wAMn8P03b9AC3Na9KEPeiulY8//aP4C+0b/tL21ZRdDJdK7lY5U1/3QFNHQNBltfpKez 
+y7a9ZpcZuEJenCnZZJNWNliHrCv210s+Z1my/WWdsRWtkNO16Tv3BfYiXYGe/jrdrM1gt3T/zH3p 
+V3VJHUFvALiBXkgT0vfTBay0QJrqAlHQcwG+FOis4gq6DxqWbEuf/93md24i7DHA7jLYsXjioQK/ 
+Bhq/h7cCN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 
+s+tsFQvAVs+Oe9GNtNK7WoQnxM3/BrZdmgeOT781c7RKL6ssMpQAUkHvNR6+HfAetoMYOIM2v9pK 
+l4FvATQWxfpg460Og43QuSvEEnytSHZRlvVM/dq1RDDSzzcD3hc7bZcXn2udfrLJKq1sBTjOPxt2 
+e3beEngvHUEW8XVpeMFtAa6/l0DbZJu9Dry3Ap2k7S/LQMdouC2/g+UetW7LW+z4C+LtPdhSgd0A 
+GIONBbFMUrZ3k7KHbYDtK9ef6tEKMrkYfb1JsHELbA86aoHuZjSyUQzN9vtHwka4zc5PmxyE+hrg 
+G9vHXwc7Amuu/C99Z5OGJBul/ObAmz8ugNt2vv7u3/nreDLsN5fLY47237/ETzz+B/u/6fgf7P+m 
+4/8BfX6FOOHA2dwAAAAASUVORK5CYII= 
+"></p>]]></text></answer>
+  </subquestion>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics_via_tikz-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics_via_tikz-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics_via_tikz-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,112 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Includegraphics with TikZ</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEIAAAAqCAMAAAAwLX3tAAAAM1BMVEUAAAAAAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACjBUbJAAAAEHRSTlMAE0RKU3WEiaWr 
+tczb5vX9QmfMGwAAAFlJREFUSMft08kRgDAMBEGBOSwuK/9o2U2AKss/oQmgfyPi70RmJkkkkcQ3 
+UfxdKBRhw8Ujnv4aCkXciMTEfJuFIQ5EYmZJjBIbIrGynxMLIlFZH7EjVQ1DvOOONZP3s13WAAAA 
+AElFTkSuQmCC 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAkAAAAOCAYAAAD9lDaoAAAAcUlEQVQokcWPMRWAMAxEf0FBLWCh 
+FrpiAy1FE0gACa0EkABDj0eXlpGbknc/yaXn1QBMwKg+FR4OWIALOICoOsoDIAhyxaDXwMaHgja6 
+rgGdT9GCBoF7DfA6FWqAJQeuhi4B+xNgZDpgruRMhvxqS+sNlq0d/BTebEoAAAAASUVORK5CYII= 
+"></p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABcAAAAjAQMAAABFDwNYAAAABlBMVEX///8AAABVwtN+AAAAAXRS 
+TlMAQObYZgAAADdJREFUCNdj+P+/gYGB/QEEM/6A4n9Q/AOBoWr4gcJgDNTHj00vQwUqRjHjHxj/ 
+//8AgoFcJAwAXTsqcaGGnVkAAAAASUVORK5CYII= 
+"></p>]]></text>
+  </answer>
+</question>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAbCAYAAACa9mScAAAAdklEQVQ4jWNkYGAIZoAAQyhmQKIl 
+GRDAG0pvY0ADTOgC5AAWBgaGNdQwZBmUfYGBgeE8lA2jHzEwMHARMoRq3omm1BCquGTUkFFDRg0Z 
+NWRQGcLIwMDQCWU7Y5E3RLLoDpT+iK6IhYGBQQnKNiZgoQouCap4BwCPsgqJWVTJ7gAAAABJRU5E 
+rkJggg== 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAMAAABEpIrGAAAAM1BMVEUAAAD///8AAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADW5/q5AAAAEHRSTlMAABEiM0RVZneI 
+maq7zN3uf6QJ9gAAAKhJREFUOMu90sESwiAMRVGkVEpb4P7/17pQKJhAZ1yYJe8MyUDM46bMX4Ap 
+5dbFyCrAhgSkMAIu8a5oVbBmyOcJcGjAZQjWmOUAvAJiPQ6QJPBQhrMZngIkch3teeEKXNcXzm8Q 
+oHmhKMEOzUEgixbb1gHUp/4NLDfA46fAA+sEeGCf3PDJh6DkI1DzAbhyHTS5CtpcBW0+AGH+F93e 
+CmBjv9cCGNst7QvN2wpURq09lgAAAABJRU5ErkJggg== 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABcAAAAjAQMAAABFDwNYAAAABlBMVEX///8AAABVwtN+AAAAAXRS 
+TlMAQObYZgAAADdJREFUCNdj+P+/gYGB/QEEM/6A4n9Q/AOBoWr4gcJgDNTHj00vQwUqRjHjHxj/ 
+//8AgoFcJAwAXTsqcaGGnVkAAAAASUVORK5CYII= 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACIAAAAiCAMAAAANmfvwAAAA0lBMVEX///8AAAABAQECAgIDAwME 
+BAQFBQUJCQkLCwsNDQ0dHR0hISEiIiIoKCguLi41NTVJSUlMTExmZmZubm5zc3N1dXWLi4uQkJCS 
+kpKbm5ucnJydnZ2fn5+goKCioqKkpKSlpaWmpqapqamqqqqrq6utra2urq6xsbGzs7O1tbW2tra6 
+urq8vLzLy8vMzMzT09Pd3d3h4eHk5OTl5eXm5ubn5+fp6enr6+vs7Ozt7e3w8PDz8/P09PT29vb3 
+9/f5+fn6+vr7+/v8/Pz9/f3+/v7/////o5MGAAAAAXRSTlMAQObYZgAAAbNJREFUOMuF1NlS6kAQ 
+BuB0SEBlUWQ1BlyIARRZ4yBLwqR7/vd/pXPh2SoE6Mupr6Zrpv5uyzouWJcK2F8W+/OGGdjjXC+w 
+1ohxxhyw1lriFNCnxAHrtQinqdb59xgDwBhmBoBJjhA5HCACMPPX12QyyXktcGBRCh/calWrE6Js 
+F8znGHNTqcoHter16jVlTGAa83l5TM1mpdKlWb3uXROR/78IqNEol9tEd3fdLmYzzyMi3//3rpsb 
+Irq9bbfbn5/f3wDe3n7E3z8kqtVoOt1u2wBgDN7f/4jfZrcjqr1MjdkKRJLEBFnBu8WC3JfAGAiE 
+ORkGGbFnLBYbtxQEAJAyj4ZZsQew2axKpX4fiNN0NMoI/NRqtbLt19c4jo+EZSUJRLReRZFtDwbx 
+eHwkLCthATRHy6XrDppj26anjLAsBgDGUim32CzatvckyOYOADRipfwiFYueB5GjZIpojTj2fYfo 
+/h6A1rm5x3DoOM7VVb+fn24AYVgoOJ2O6/af83OLMCQqPHaiyKXnE+kPHaLeo44iRSdnyHF6PWit 
+1JlJfHgAgPN7wRgYc2ErGJjLuyXn7BfJsGNGBciJRQAAAABJRU5ErkJggg== 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAAdCAAAAABtMQhgAAABDUlEQVQYGW3Bu2pUURQA0LX3OXPN 
+o7GykBRaKggprFSCkEqxERTyF2JnZ6ddWv2A4CcIgl+gFoLBxmIg2KkIFpnJzH2YUjiuFXNX/ePQ 
+U6lVB3HNHWm2MOku+a326gMvFHpFnNqSWnXLOhUrMdOzidSqgxwshI3JKAOpVRfGwdoPpXOZwZKT 
+E3GuFKUcHHw8O5um1Iq53SeuuOj7B0fKkUdSK04N2wYpV956GL6IXlnpnBulw2deSq06Kh2WNsLk 
+7to7qVVnlh06Uxhs8kudzMKoWFfFz3BdatVQRkVP+OM1j6VWfe7eDRdU4zevvNmzK/1XsLOzvy+C 
++8fHwxCffP1s7r29m267tW2SWn8B1wBQQBxcN+IAAAAASUVORK5CYII= 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAC4AAABHAQMAAABCjOfmAAAABlBMVEX///8AAABVwtN+AAAAAXRS 
+TlMAQObYZgAAAEVJREFUGNOd0LENwCAMBdHrMjaMlrEoLF0KysQGUr3qyzqj2uEToEXO5b0mCvJd 
+flYHOfaMOmWjiPaPMnN+4o1qsGJwzgPXwLGKCxz0xgAAAABJRU5ErkJggg== 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACMAAAA2BAMAAAC/7D1CAAAAMFBMVEUAAAAAAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABaPxwLAAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAABBUlEQVQ4y62SMUoDURRFbyKIQQKzAIvUIsQVmCZFUiiW6XQHugSTBTh2diKphICm 
+sFMwrsAlKFhaJIiKRjPHYj7j//OETJFbHu7j3X/fF3lNtEh04+sWeFKgNUg2A1J6gOd5pqVHY9qy 
+pjHcG9NPtBDTjjEtY0wHBU1Jbh0FXze3J93Be0hWgP0Q7cFnSEpjOA9RBWZhTDXgLSS6MnNloGYi 
+fOfmqianGjCRqWqYQzGc2AxHMjUUQPG/aCTT1qvXlCTVYfpHziJJq37N24zc7T8cWYcvl4KuJKkN 
+sJueGi6azc4lwDRyt86UHEqSNjzUd5vjjFxn9R+nYNbzntAawMtp+lV+Afb0PN8sFBDMAAAAAElF 
+TkSuQmCC 
+"></p>]]></text></answer>
+  </subquestion>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics_via_tikz_and_svg-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics_via_tikz_and_svg-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics_via_tikz_and_svg-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,247 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Includegraphics with TikZ</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNDIuNTEx 
+IiBoZWlnaHQ9IjI2LjU2NyIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNDIuNTExIDI2LjU2 
+NyIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+IiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayI+PGRlZnM+PG1hc2sg 
+aWQ9ImEiIHg9IjAiIHk9IjAiIHdpZHRoPSIxIiB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WFnZS9wbmc7YmFz 
+ZTY0LGlWQk9SdzBLR2dvQUFBQU5TVWhFVWdBQUFBb0FBQUFRQ0FZQUFBQXZmKzVBQUFBQUJITkNT 
+VlFJQ0FnSWZBaGtpQUFBQUJwSlJFRlVLSkZqWkdCZytNOUFCR0FpUnRHb3dsR0ZsQ2tFQUxVaUFS 
+OUNRa1gyQUFBQUFFbEZUa1N1UW1DQyIvPjwvZz48L2c+PC9nPjwvZz48L2c+PC9nPjwvZz48L3N2 
+Zz4K 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNS42MzA3 
+IiBoZWlnaHQ9IjguNjg5MyIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNS42MzA3IDguNjg5 
+MyIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZGVmcz48Y2xpcFBhdGggaWQ9ImEiPjxwYXRoIGQ9Im0wIDBoOC40NDYzdjEzLjAzNGgtOC40 
+NDYzeiIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIHRyYW5zZm9ybT0ibWF0cml4KDEuMzMzMyAwIDAg 
+LTEuMzMzMyAwIDguNjg5MykiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDIuMTEyLDMuMjU5KSI+ 
+PGcgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoLTIuMTEyLC0zLjI1OSkiPjxnIHRyYW5zZm9ybT0ic2Nh 
+bGUoLjUpIj48Zy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ncGJtUUFBQURoSlJFRlVDSmwxampFS0FDQVF3eEx4LzErdWc1Nklj 
+SjB5cEtXR0hjRk5BWXNKK0RDREd6OC9aK1k2b2Q4czUvVnB1MkQ5UkdiVFhaRGVEQnExSkJpeEFB 
+QUFBRWxGVGtTdVFtQ0MiLz48L21hc2s+PC9kZWZzPjxnIHRyYW5zZm9ybT0ibWF0cml4KDEuMzMz 
+MyAwIDAgLTEuMzMzMyAwIDIyLjY2NykiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDUuNSw4LjUp 
+Ij48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgtNS41LC04LjUpIj48ZyB0cmFuc2Zvcm09InNjYWxl 
+KDExLDE3KSI+PGltYWdlIHRyYW5zZm9ybT0ibWF0cml4KDEsMCwwLC0xLDAsMSkiIHdpZHRoPSIx 
+IiBoZWlnaHQ9IjEiIGltYWdlLXJlbmRlcmluZz0ib3B0aW1pemVTcGVlZCIgbWFzaz0idXJsKCNh 
+KSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSIgeGxpbms6aHJlZj0iZGF0YTppbWFnZS9wbmc7 
+YmFzZTY0LGlWQk9SdzBLR2dvQUFBQU5TVWhFVWdBQUFBc0FBQUFSQ0FZQUFBQUw0VmJiQUFBQUJI 
+TkNTVlFJQ0FnSWZBaGtpQUFBQUZoSlJFRlVLSkhGa3NFT3dDQUlROXRsLy8vTDlUSXpneFh4NUxz 
+UkNsU0VBSVFFNlU5VFl6UkFjaXA0U2gyL3dxWFlUU3FMSmEzRnp2UHJrbEhVU1czRUJwZFdkK1E1 
+Y3ZUQTBwNTdUR3l1RGpDZmtvbTJOaHdOWDdFckdXNWlRWVVBQUFBQVNVVk9SSzVDWUlJPSIvPjwv 
+Zz48L2c+PC9nPjwvZz48L3N2Zz4K 
+"></p>]]></text>
+  </answer>
+</question>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CD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zZm9y 
+bT0ic2NhbGUoOCwxMi44KSI+PGltYWdlIHRyYW5zZm9ybT0ibWF0cml4KDEsMCwwLC0xLDAsMSki 
+IHdpZHRoPSIxIiBoZWlnaHQ9IjEiIGltYWdlLXJlbmRlcmluZz0ib3B0aW1pemVTcGVlZCIgbWFz 
+az0idXJsKCNhKSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSIgeGxpbms6aHJlZj0iZGF0YTpp 
+bWFnZS9wbmc7YmFzZTY0LGlWQk9SdzBLR2dvQUFBQU5TVWhFVWdBQUFBb0FBQUFRQ0FZQUFBQXZm 
+KzVBQUFBQUJITkNTVlFJQ0FnSWZBaGtpQUFBQUJwSlJFRlVLSkZqWkdCZytNOUFCR0FpUnRHb3ds 
+R0ZsQ2tFQUxVaUFSOUNRa1gyQUFBQUFFbEZUa1N1UW1DQyIvPjwvZz48L2c+PC9nPjwvZz48L3N2 
+Zz4K 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iMjAuMjUy 
+IiBoZWlnaHQ9IjIwLjI1MiIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgMjAuMjUyIDIwLjI1 
+MiIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZGVmcz48Y2xpcFBhdGggaWQ9ImEiPjxwYXRoIGQ9Im0wIDBoOC40NDYzdjEzLjAzNGgtOC40 
+NDYzeiIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIHRyYW5zZm9ybT0ibWF0cml4KDE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dHJpeCgyLDAsMCwyLDE2Ljg5MiwwKSI+PGcgdHJhbnNmb3JtPSJzY2FsZSgtMSkiPjxnIGNsaXAt 
+cGF0aD0idXJsKCNhKSI+PGcgdHJhbnNmb3JtPSJtYXRyaXgoMSAwIDAgLTEgMCAxMy4wMzQpIj48 
+dGV4dCB0cmFuc2Zvcm09InRyYW5zbGF0ZSgtLjg3ODkxIDEzLjAzNCkiIGZpbGw9IiMwMDAwMDAi 
+IGZvbnQtZmFtaWx5PSInT3BlbiBTYW5zJyIgZm9udC1zaXplPSIxOHB4Ij48dHNwYW4geD0iMCIg 
+eT0iMCI+MjwvdHNwYW4+PC90ZXh0PjwvZz48L2c+PC9nPjwvZz48L2c+PC9nPjwvZz48L3N2Zz4K 
+"></p>]]></text></answer>
+  </subquestion>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics_with_svg-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics_with_svg-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_includegraphics_with_svg-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,313 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Scalable Vector Graphics</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB2ZXJzaW9uPSIxLjEi 
+IHZpZXdCb3g9IjAgMCAzMjcgMTAwIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmci 
+Pgo8ZyBmaWxsPSIjZjk4MDEyIj4KPHBhdGggZD0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zOSAwIDguNzYyIDEuMTIgOC43 
+NjIgNC43ODN2NTMuMTJjMCAzLjY2My0wLjIyMTYgNC43ODItOC43NjIgNC43ODJoLTIuNTUydjMu 
+MTU1aDYzLjY3bDQuNjU5LTI2LjE1eiIvPgo8L2c+CjxwYXRoIGQ9Im00My42NyAyOS4yMiAxMy42 
+OC0xMC0wLjE3Ni0wLjYwMDNjLTI0LjY3IDMuMDI1LTM1LjkgNS4xNzQtNTcuMTcgMTcuNWwwLjIw 
+MDcgMC41NDkzIDEuNjk5IDAuMDI2M2MtMC4xNDk3IDEuNjk5LTAuNDI0MyA1LjktMC4wNzQgMTIu 
+MjUtMi4zNSA2LjgyNC0wLjA1MSAxMS40NyAyLjA5OSAxNi41MiAwLjM1MDMtNS4yNSAwLjMwMS0x 
+MS0xLjI5OS0xNi43Mi0wLjMyNTctNi4yNzUtMC4wNDkzLTEwLjQyIDAuMTAwMy0xMi4wMmwxNC4x 
+IDAuMTI1cy0wLjEwMDMgNC4yNSAwLjQyNDMgOC4yNzRjMTIuNiA0LjQyNCAyNS4yNy0wLjAyNDcg 
+MzItMTAuOTItMS45LTIuMTI1LTUuNTc2LTQuOTc1LTUuNTc2LTQuOTc1eiIgZmlsbD0iIzMzMyIv 
+Pgo8L3N2Zz4K 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/gif;base64,R0lGODlhCwARAOcAAAAAAAEBAQICAgMDAwQEBAUFBQYGBgcHBwgICAkJCQoKCgsLCwwMDA0NDQ4O 
+Dg8PDxAQEBERERISEhMTExQUFBUVFRYWFhcXFxgYGBkZGRoaGhsbGxwcHB0dHR4eHh8fHyAgICEh 
+ISIiIiMjIyQkJCUlJSY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AAAAACwARAAAINAABCBwo8J/BgwcHIlyocKHBhg4h 
+IpRIEEDEig4TFsz4TyLDjRctZvT4sKJJkSdFdjSJMCAAIfkECQoA/wAsAAAAAAsAEQAACDQAAQgc 
+KPCfwYMHByJcqHChwYYOISKUSBBAxIoOExbM+E8iw40XLWb0+LCiSZEnRXY0iTAgACH5BAEKAP8A 
+LAAAAAALABEAAAgyAAEIHCjwn8GDBwciXKhwoUGCDv81ZFgwIUSKFyNOdLgRY0SJFTEC4Eiw5EWT 
+IVEiDAgAOw== 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG  SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iMTEuMjYy 
+IiBoZWlnaHQ9IjE3LjM3OSIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgMTEuMjYyIDE3LjM3 
+OSIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZyB0cmFuc2Zvcm09InNjYWxlKDEuMzMzMykiPjx0ZXh0IHRyYW5zZm9ybT0idHJhbnNsYXRl 
+KC0uODc4OTEgMTMuMDM0KSIgZmlsbD0iIzAwMDAwMCIgZm9udC1mYW1pbHk9IidPcGVuIFNhbnMn 
+IiBmb250LXNpemU9IjE4cHgiPjx0c3BhbiB4PSIwIiB5PSIwIj4yPC90c3Bhbj48L3RleHQ+PC9n 
+Pjwvc3ZnPgo= 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAARAAsBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABAYJCP/EACkQAAEDAwQBAgcBAAAAAAAAAAECAwUEBgcAERIhEwgUIjM4UXFysbL/ 
+2gAIAQEAAD8APx7E+mJivyZXZktB2qnV35PeWZqYKTepm2PfOBsrqWWyylI2VueXWx321RXFsZaM 
+XjyAprE9qqzkUqTFmNqPLTFg9p8auR3T313pGd9XeCKi135RzKtlvRJbIcbVL05WoFJPAslXMqIB 
++Djue+tYiw9hLOc5YzcpjuRdtKxJCQka2ChqhlTC6aidrX3GR4+uIKFJUB9lDS5fX1uW/wDl/wD2 
+zqsTPyW/1H81/9k= 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAAQAAwBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABQYHCP/EACcQAAEDBAEDAwUAAAAAAAAAAAIBAwQFBgcRCAASIRMUMjhRcXax/9oA 
+CAEBAAA/ANg8gpDmb59exXTn3Btql08596TIxECkBNkUamAYqmjdVEcd0u0aFEVE9ZFQ7wW+j7En 
+6/H/AJ1OaLx5zXi3HVxQoOYrbnty1nVOoy5llmUuc+73G4bjnvvlrQp40IiIomhROl/iDY+cKjxi 
+xrJoGU7YpFFcorBRIMyzjlOsN68CTqTQ71T79qfjr//Z 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Picture]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG width=81 SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB2ZXJzaW9uPSIxLjEi 
+IHZpZXdCb3g9IjAgMCAzMjcgM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IDE5Ljg1IDUuNTk4IDIxLjYzIDE5Ljc0aDIu 
+NzczbC0zLjEwNS0yMi44aC02Mi4xMXYzLjA1M2gyLjU1MmM4LjUzOSAwIDguNzYyIDEuMTIgOC43 
+NjIgNC43ODN2NTMuMTJjMCAzLjY2My0wLjIyMTYgNC43ODItOC43NjIgNC43ODJoLTIuNTUydjMu 
+MTU1aDYzLjY3bDQuNjU5LTI2LjE1eiIvPgo8L2c+CjxwYXRoIGQ9Im00My42NyAyOS4yMiAxMy42 
+OC0xMC0wLjE3Ni0wLjYwMDNjLTI0LjY3IDMuMDI1LTM1LjkgNS4xNzQtNTcuMTcgMTcuNWwwLjIw 
+MDcgMC41NDkzIDEuNjk5IDAuMDI2M2MtMC4xNDk3IDEuNjk5LTAuNDI0MyA1LjktMC4wNzQgMTIu 
+MjUtMi4zNSA2LjgyNC0wLjA1MSAxMS40NyAyLjA5OSAxNi41MiAwLjM1MDMtNS4yNSAwLjMwMS0x 
+MS0xLjI5OS0xNi43Mi0wLjMyNTctNi4yNzUtMC4wNDkzLTEwLjQyIDAuMTAwMy0xMi4wMmwxNC4x 
+IDAuMTI1cy0wLjEwMDMgNC4yNSAwLjQyNDMgOC4yNzRjMTIuNiA0LjQyNCAyNS4yNy0wLjAyNDcg 
+MzItMTAuOTItMS45LTIuMTI1LTUuNTc2LTQuOTc1LTUuNTc2LTQuOTc1eiIgZmlsbD0iIzMzMyIv 
+Pgo8L3N2Zz4K 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iMTEuMjYy 
+IiBoZWlnaHQ9IjE3LjM3OSIgdmVyc2l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BgyYcaMHFGatIgwIAAh+QQJCgD/ACwAAAAACwARAAAI 
+MwABCBwo8J/BgwcHIlyocKFBgg7/NWQ4keBEiRYjPiyo8SJFAB05foxosSRHkyATlkQYEAAh+QQJ 
+CgD/ACwAAAAACwARAAAINAABCBwo8J/BgwcHIlyocKFBgg7/NWRYMCFBABQhRpRYMeJEhx8Rhnw4 
+8qLJiicxWryIMCAAIfkECQoA/wAsAAAAAAsAEQAACDQAAQgcKPCfwYMHByJcqHChwYYOISKUSBBA 
+xIoOExbM+E8iw40XLYYUObGiSZEnSXY0iTAgACH5BAkKAP8ALAAAAAALABEAAAg0AAEIHCjwn8GD 
+BwciXKhwocGGDiEilEgQQMSKDhMWzPhPIsONFy1m9NixosmCJ0U+NIkwIAAh+QQJCgD/ACwAAAAA 
+CwARAAAIMwABCBwo8J/BgwcHIlyocKHBhg4hIpRIEEDEig4TFsz4TyLDjRctZvTYsaLJjScnmkQY 
+EAAh+QQJCgD/ACwAAAAACwARAAAIMwABCBwo8J/BgwcHIlyocKHBhg4hIpRIEEDEig4TFsz4TyLD 
+jRlBfrQ4sqLJhyc1YjwYEAAh+QQJCgD/ACwAAAAACwARAAAINAABCBwo8J/BgwcHIlyocKHBhg4h 
+IpRIEEDEig4TFsz4TyLDjRctZvT4sKJJkSdFdjSJMCAAIfkECQoA/wAsAAAAAAsAEQAACDQAAQgc 
+KPCfwYMHByJcqHChwYYOISKUSBBAxIoOExbM+E8iw40XLWb0+LCiSZEnRXY0iTAgACH5BAEKAP8A 
+LAAAAAALABEAAAgyAAEIHCjwn8GDBwciXKhwoUGCDv81ZFgwIUSKFyNOdLgRY0SJFTEC4Eiw5EWT 
+IVEiDAgAOw== 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAAQAAwBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABQYHCP/EACcQAAEDBAEDAwUAAAAAAAAAAAIBAwQFBgcRCAASIRMUMjhRcXax/9oA 
+CAEBAAA/ANg8gpDmb59exXTn3Btql08596TIxECkBNkUamAYqmjdVEcd0u0aFEVE9ZFQ7wW+j7En 
+6/H/AJ1OaLx5zXi3HVxQoOYrbnty1nVOoy5llmUuc+73G4bjnvvlrQp40IiIomhROl/iDY+cKjxi 
+xrJoGU7YpFFcorBRIMyzjlOsN68CTqTQ71T79qfjr//Z 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG  SRC="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQIAIwAjAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK 
+CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/wAALCAARAAsBAREA/8QAFwAAAwEAAAAA 
+AAAAAAAAAAAABAYJCP/EACkQAAEDAwQBAgcBAAAAAAAAAAECAwUEBgcAERIhEwgUIjM4UXFysbL/ 
+2gAIAQEAAD8APx7E+mJivyZXZktB2qnV35PeWZqYKTepm2PfOBsrqWWyylI2VueXWx321RXFsZaM 
+XjyAprE9qqzkUqTFmNqPLTFg9p8auR3T313pGd9XeCKi135RzKtlvRJbIcbVL05WoFJPAslXMqIB 
++Djue+tYiw9hLOc5YzcpjuRdtKxJCQka2ChqhlTC6aidrX3GR4+uIKFJUB9lDS5fX1uW/wDl/wD2 
+zqsTPyW/1H81/9k= 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG  SRC="data:image/gif;base64,R0lGODlhCwARAOcAAAAAAAEBAQICAgMDAwQEBAUFBQYGBgcHBwgICAkJCQoKCgsLCwwMDA0NDQ4O 
+Dg8PDxAQEBERERISEhMTExQUFBUVFRYWFh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Bhg4hIpRIEEDEig4TFsz4TyLD 
+jRlBfrQ4sqLJhyc1YjwYEAAh+QQJCgD/ACwAAAAACwARAAAINAABCBwo8J/BgwcHIlyocKHBhg4h 
+IpRIEEDEig4TFsz4TyLDjRctZvT4sKJJkSdFdjSJMCAAIfkECQoA/wAsAAAAAAsAEQAACDQAAQgc 
+KPCfwYMHByJcqHChwYYOISKUSBBAxIoOExbM+E8iw40XLWb0+LCiSZEnRXY0iTAgACH5BAEKAP8A 
+LAAAAAALABEAAAgyAAEIHCjwn8GDBwciXKhwoUGCDv81ZFgwIUSKFyNOdLgRY0SJFTEC4Eiw5EWT 
+IVEiDAgAOw== 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG width=28 SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iMTEuMjYy 
+IiBoZWlnaHQ9IjE3LjM3OSIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgMTEuMjYyIDE3LjM3 
+OSIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZyB0cmFuc2Zvcm09InNjYWxlKDEuMzMzMykiPjx0ZXh0IHRyYW5zZm9ybT0idHJhbnNsYXRl 
+KC0uODc4OTEgMTMuMDM0KSIgZmlsbD0iIzAwMDAwMCIgZm9udC1mYW1pbHk9IidPcGVuIFNhbnMn 
+IiBmb250LXNpemU9IjE4cHgiPjx0c3BhbiB4PSIwIiB5PSIwIj4yPC90c3Bhbj48L3RleHQ+PC9n 
+Pjwvc3ZnPgo= 
+"></p>]]></text></answer>
+  </subquestion>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_macros-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_macros-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_macros-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/LaTeX Macros</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[LaTeX Macros]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>The following commands should not be placed in items: <BR/> and </P><P>Find the \(\rm\LaTeX\) logo </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>\(\rm\TeX\) and \(\rm\LaTeX\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>(tilde) and #</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>$ and &</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>& and §</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>{ and }</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>(space) and (relax)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>(space) and (thinspace)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>… and …</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>€ and €</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>\(\rm\TeX\) and \(\rm\LaTeX\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>_ and \</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_matching-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_matching-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_matching-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,70 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Matching</text>
+  </category>
+</question>
+ 
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Matching]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+    <answer format="html"><text><![CDATA[<p>1</p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+    <answer format="html"><text><![CDATA[<p>2</p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+    <answer format="html"><text><![CDATA[<p>3</p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text></text>
+    <answer format="html"><text><![CDATA[<p>4</p>]]></text></answer>
+  </subquestion>
+</question>
+<question type="matching">
+  <name format="html">
+    <text><![CDATA[Matching]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Question text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>0</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+    <answer><text>1</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+    <answer><text>2</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+    <answer><text>3</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text></text>
+    <answer><text>4</text></answer>
+  </subquestion>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_mathenv-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_mathenv-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_mathenv-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example Quiz</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>\[\begin {array}{c}$1\\2\end {array}\] </P><P>\[\begin {array}{c}$1\\2\end {array}\] </P><P>\(\begin {array}{c}$1\\2\end {array}\) </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>\($\sqrt {25}\)</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>6</p>]]></text>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>7</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>\[$\sqrt {25}\]</p>]]></text></feedback>
+  </answer>
+  <answer fraction="10" format="html">
+    <text><![CDATA[<p>8</p>]]></text>
+  </answer>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>\[\begin {array}{c}$1\\2\end {array}\] </P><P>\[\begin {array}{c}$1\\2\end {array}\] </P><P>\(\begin {array}{c}$1\\2\end {array}\) {1:MULTICHOICE_VS:=\($\sqrt {25\}\)~6~=7#\[$\sqrt {25\}\]~%10%8}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_minted-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_minted-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_minted-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Minted</text>
+  </category>
+</question>
+ 
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[LaTeX Classes]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>In the following \(\rm\LaTeX\) code excerpt, on which line is the class loaded? <PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">2</span><span style="color: #177500">% !TEX TS-program = xelatex</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">2</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right"> </span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">3</span><span style="color: #A90D91">\documentclass{</span>article<span style="color: #A90D91">}</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">3</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">4</span><span style="color: #A90D91">\usepackage</span><span style="color: #836C28">[nostamp]</span><span style="color: #A90D91">{</span>moodle<span style="color: #A90D91">}</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">4</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">5</span><span style="color: #A90D91">\newif\iffvextra</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; fl!
 oat: right">5</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">6</span><span style="color: #A90D91">\fvextratrue</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">6</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">7</span><span style="color: #A90D91">\ifxetex</span> <span style="color: #177500">% FOR XELATEX</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">7</span><BR/></CODE></PRE> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>4</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>yes! <PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">2</span><span style="color: #177500">% !TEX TS-program = xelatex</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">2</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right"> </span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">3</span><mark><span style="color: #A90D91">\documentclass{</span>article<span style="color: #A90D91">}</span></mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">3</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">4</span><span style="color: #A90D91">\usepackage</span><span style="color: #836C28">[nostamp]</span><span style="color: #A90D91">{</span>moodle<span style="color: #A90D91">}</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">4</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">5</span><span style="color: #A90D91">\newif\iffvextra</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">5</span><BR/><span style="!
 font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">6</span><span style="color: #A90D91">\fvextratrue</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">6</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">7</span><span style="color: #A90D91">\ifxetex</span> <span style="color: #177500">% FOR XELATEX</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">7</span><BR/></CODE></PRE></p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>3</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>No. On line 3, there is only a comment.</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>5</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>No. On line 5, the package <CODE>moodle</CODE> is loaded.</p>]]></text></feedback>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Languages]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Select the code written in the Python language. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">2</span><mark><span style="color: #A90D91">if</span> <span style="color: #000000">n</span> <span style="color: #000000"><</span> <span style="color: #1C01CE">0</span>:</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">2</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">3</span>    <span style="color: #A90D91">raise</span> <span style="color: #000000">ValueError</span>(<span style="color: #C41A16">'non negative integer expected'</span>)<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">3</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right"> </span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">4</span><mark><span style="color: #000000">fact</span> <span style="color: #000000">=</span> <span style="color: #1C01CE">1</span></mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">4</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right"> </span><mark></mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16p!
 t; text-align: left; float: right"> </span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">5</span><mark><span style="color: #A90D91">for</span> <span style="color: #000000">i</span> <span style="color: #000000">in</span> <span style="color: #A90D91">range</span>(<span style="color: #1C01CE">2</span>, <span style="color: #000000">n</span> <span style="color: #000000">+</span> <span style="color: #1C01CE">1</span>):</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">5</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">6</span>    <span style="color: #000000">fact</span> <span style="color: #000000">*=</span> <span style="color: #000000">i</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">6</span><BR/></CODE></PRE></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>Indeed, this is Python code.</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="color: #888888">#!/usr/bin/XXXX</span><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">1</span><BR/><mark><span style="color: #008800; font-weight: bold">use</span> <span style="color: #0e84b5; font-weight: bold">strict</span>;</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">2</span><BR/><span style="color: #008800; font-weight: bold">use</span> <span style="color: #0e84b5; font-weight: bold">warnings</span>;<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">3</span><BR/><mark><span style="color: #008800; font-weight: bold">use</span> <span style="color: #0e84b5; font-weight: bold">IO::Handle</span>;</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">4</span><BR/><mark></mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><mark><span style="color: #008800; font-weight: bold">my</span> ( <span style="color: #996633">$remaining</span>, <span style="color: #996633">$tot</span> );</mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">5</span><BR/><mark></mark><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="color: #996633">$remaining</span> <span style="color: #333333">=</span> <span style="color: #996633">$tot</span> <span style="color: #333333">=</span> <span style="color: #007!
 020">shift</span>(<span style="color: #996633">@ARGV</span>);<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">6</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="color: #007020">STDOUT</span><span style="color: #333333">-></span>autoflush(<span style="color: #0000DD; font-weight: bold">1</span>);<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">7</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="color: #008800; font-weight: bold">while</span> ( <span style="color: #996633">$remaining</span> ) {<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">8</span><BR/>  <span style="color: #007020">printf</span> ( <span style="background-color: #fff0f0">"Remaining %s/%s \r"</span>, <span style="color: #996633">$remaining</span><span style="color: #333333">--</span>, <span style="color: #996633">$tot</span> );<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">9</span><BR/>  <span style="color: #007020">sleep</span> <span style="color: #0000DD; font-weight: bold">1</span>;<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">10</span><BR/>}<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">11</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; dis!
 play: inline-block; width: 16pt; text-align: left; float: right"> </span><BR/><span style="color: #008800; font-weight: bold">print</span> <span style="background-color: #fff0f0">"\n"</span>;<span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: left; float: right">12</span><BR/></CODE></PRE></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>No. This is Perl code.</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">1</span><span style="color: #204a87; font-weight: bold">long</span> <span style="color: #000000">some_function</span><span style="color: #000000; font-weight: bold">();</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">2</span><mark><span style="color: #8f5902; font-style: italic">/* int */</span> <span style="color: #000000">other_function</span><span style="color: #000000; font-weight: bold">();</span></mark><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">3</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">4</span><mark><span style="color: #8f5902; font-style: italic">/* int */</span> <span style="color: #000000">calling_function</span><span style="color: #000000; font-weight: bold">()</span></mark><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">5</span><span style="color: #000000; font-weight: bold">{</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">6</span>    <span style="color: #204a87; font-weight: bold">long</span> <span style="color: #000000">test1</span><span style="color: #000000; font-weight: bold">;</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">7</span><mark>    <span style="color: #204a87; font-weight: bold">register</span> <span style="color: #8f5902; font-style: italic">/* int */</span> <span style="color: #000000">te!
 st2</span><span style="color: #000000; font-weight: bold">;</span></mark><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">8</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">9</span>    <span style="color: #000000">test1</span> <span style="color: #ce5c00; font-weight: bold">=</span> <span style="color: #000000">some_function</span><span style="color: #000000; font-weight: bold">();</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">10</span>    <span style="color: #204a87; font-weight: bold">if</span> <span style="color: #000000; font-weight: bold">(</span><span style="color: #000000">test1</span> <span style="color: #ce5c00; font-weight: bold">></span> <span style="color: #0000cf; font-weight: bold">0</span><span style="color: #000000; font-weight: bold">)</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">11</span>          <span style="color: #000000">test2</span> <span style="color: #ce5c00; font-weight: bold">=</span> <span style="color: #0000cf; font-weight: bold">0</span><span style="color: #000000; font-weight: bold">;</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">12</span>    <span style="color: #204a87; font-weight: bold">else</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">13</span>          <span style="color: #000000">test2</span> <span style="color: #ce5c00; font-weight: bold">=</span> <span style="color: #000000">other_function</span><span style="color: #000000; font-weight: bold">();</span><BR/><span style="font-size: 80%; background-color:!
  #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">14</span>    <span style="color: #204a87; font-weight: bold">return</span> <span style="color: #000000">test2</span><span style="color: #000000; font-weight: bold">;</span><BR/><span style="font-size: 80%; background-color: #f0f0f0; padding: 0 5px 0 5px; display: inline-block; width: 16pt; text-align: right">15</span><span style="color: #000000; font-weight: bold">}</span><BR/></CODE></PRE></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>No. This is C code.</p>]]></text></feedback>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_multi-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_multi-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_multi-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,99 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example Quiz</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Text </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Select the following numbers that are prime. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>abc<BR/>def \(\sqrt {2}\)</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>false</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="70" format="html">
+    <text><![CDATA[<p>\(\sqrt {25}\)</p>]]></text>
+  </answer>
+  <answer fraction="-10" format="html">
+    <text><![CDATA[<p><B>68</B></p>]]></text>
+  </answer>
+  <answer fraction="30" format="html">
+    <text><![CDATA[<p>7</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>\(\sqrt {25}\)</p>]]></text></feedback>
+  </answer>
+  <answer fraction="-70" format="html">
+    <text><![CDATA[<p>8</p>]]></text>
+  </answer>
+  <answer fraction="-20" format="html">
+    <text><![CDATA[<p><CODE>nothing</CODE></p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Select the following numbers that are prime. </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>abc<BR/>def \(\sqrt {2}\)</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>\(\sqrt {25}\)</p>]]></text>
+  </answer>
+  <answer fraction="-30" format="html">
+    <text><![CDATA[<p>6</p>]]></text>
+  </answer>
+  <answer fraction="-30" format="html">
+    <text><![CDATA[<p>9</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>\(\sqrt {25}\)</p>]]></text></feedback>
+  </answer>
+  <answer fraction="-70" format="html">
+    <text><![CDATA[<p><OL><LI>False </LI><LI>Wrong</LI></OL></p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_multiple_categories-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_multiple_categories-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_multiple_categories-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Category 1</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Q1]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Text 1 </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+</question>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Category 2</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Q2]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Text 2 </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>C</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>D</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_penalty-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_penalty-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_penalty-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Example</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multiple Choice]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>abc: def </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>abc: def</p>]]></text>
+  </generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>abc: def</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>6</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_point_points-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_point_points-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_point_points-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Ifnum</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[MWE]]></text>
+  </name>
+  <questiontext format="html"><text/></questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[MWE]]></text>
+  </name>
+  <questiontext format="html"><text/></questiontext>
+  <defaultgrade>.5</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[MWE]]></text>
+  </name>
+  <questiontext format="html"><text/></questiontext>
+  <defaultgrade>3.2</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>A</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>B</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_special_characters-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_special_characters-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_special_characters-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Diacritical marks and ligatures</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Å À Â Ã É È Ë Ê Î Ï Ñ Õ Ô Ö Ù Ü Û Ç Ş Ţ Ő Ű Ÿ Ă Ĕ Ğ Ĭ Ŏ Ŭ Č Ď Ě Ľ Ň Ř Š Ť Ž ]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>å à â ã é è ë ê î ï ñ õ ô ö ù ü û ç ş ţ ő ű ÿ ă ĕ ğ ĭ ŏ ŭ č ď ě ľ ň ř š ť ž <BR/> Å À Â Ã É È Ë Ê Î Ï Ñ Õ Ô Ö Ù Ü Û Ç Ş Ţ Ő Ű Ÿ Ă Ĕ Ğ Ĭ Ŏ Ŭ Č Ď Ě Ľ Ň Ř Š Ť Ž <BR/> œ æ ß Œ Æ ẞ Ø Ł « ø ł » ¿ ¡ </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>å à â ã é è ë ê î ï ñ õ ô ö ù ü û ç ş ţ ő ű ÿ ă ĕ ğ ĭ ŏ ŭ č ď ě ľ ň ř š ť ž </p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>Å À Â Ã É È Ë Ê Î Ï Ñ Õ Ô Ö Ù Ü Û Ç Ş Ţ Ő Ű Ÿ Ă Ĕ Ğ Ĭ Ŏ Ŭ Č Ď Ě Ľ Ň Ř Š Ť Ž </p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>Å À Â Ã É È Ë Ê Î Ï Ñ Õ Ô Ö Ù Ü Û Ç Ş Ţ Ő Ű Ÿ Ă Ĕ Ğ Ĭ Ŏ Ŭ Č Ď Ě Ľ Ň Ř Š Ť Ž </p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>å à â ã é è ë ê î ï ñ õ ô ö ù ü û ç ş ţ ő ű ÿ ă ĕ ğ ĭ ŏ ŭ č ď ě ľ ň ř š ť ž </p>]]></text></feedback>
+  </answer>
+</question>
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Å À Â Ã É È Ë Ê Î Ï Ñ Õ Ö Ô Ù Ü Û Ç Ş Ţ Ő Ű Ÿ Ă Ĕ Ğ Ĭ Ŏ Ŭ Č Ď Ě Ľ Ň Ř Š Ť Ž ]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>å à â ã é è ë ê î ï ñ õ ö ô ù ü û ç ş ţ ő ű ÿ ă ĕ ğ ĭ ĭ ŏ ŭ č ď ě ľ ň ř š ť ž <BR/> Å À Â Ã É È Ë Ê Î Ï Ñ Õ Ö Ô Ù Ü Û Ç Ş Ţ Ő Ű Ÿ Ă Ĕ Ğ Ĭ Ŏ Ŭ Č Ď Ě Ľ Ň Ř Š Ť Ž <BR/> œ æ ß Œ Æ ẞ Ø Ł «  ø ł  » ¿ ¡ </p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>å à â ã é è ë ê î ï ñ õ ö ô ù ü û ç ş ţ ő ű ÿ ă ĕ ğ ĭ ĭ ŏ ŭ č ď ě ľ ň ř š ť ž </p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>Å À Â Ã É È Ë Ê Î Ï Ñ Õ Ö Ô Ù Ü Û Ç Ş Ţ Ő Ű Ÿ Ă Ĕ Ğ Ĭ Ŏ Ŭ Č Ď Ě Ľ Ň Ř Š Ť Ž </p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>Å À Â Ã É È Ë Ê Î Ï Ñ Õ Ö Ô Ù Ü Û Ç Ş Ţ Ő Ű Ÿ Ă Ĕ Ğ Ĭ Ŏ Ŭ Č Ď Ě Ľ Ň Ř Š Ť Ž </p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>å à â ã é è ë ê î ï ñ õ ö ô ù ü û ç ş ţ ő ű ÿ ă ĕ ğ ĭ ĭ ŏ ŭ č ď ě ľ ň ř š ť ž </p>]]></text></feedback>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tags-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tags-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tags-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,160 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Moodle Tags</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>æ</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>tic</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>œ</p>]]></text>
+    <feedback format="html"><text><![CDATA[<p>tac</p>]]></text></feedback>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[multiéàî]]></text></tag>
+  </tags>
+</question>
+<question type="shortanswer">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <usecase>0</usecase>
+  <answer fraction="100" format="plain_text">
+    <text>B</text>
+    <feedback format="html"><text><![CDATA[<p>toc</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>C</text>
+    <feedback format="html"><text><![CDATA[<p>«  »</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>*</text>
+  </answer>
+  <tags>
+    <tag><text><![CDATA[quizz-level]]></text></tag>
+  </tags>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>toc</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>2</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p>«  »</p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>3</text>
+    <tolerance>0</tolerance>
+  </answer>
+</question>
+<question type="matching">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p>æ</p>]]></text>
+    <answer><text>oui</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p>œ</p>]]></text>
+    <answer><text>non</text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text></text>
+    <answer><text>Å</text></answer>
+  </subquestion>
+  <tags>
+    <tag><text><![CDATA[måtchïng]]></text></tag>
+  </tags>
+</question>
+<question type="essay">
+  <name format="html">
+    <text><![CDATA[Title]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Å</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <responserequired>0</responserequired>
+  <responseformat>editor</responseformat>
+  <responsefieldlines>15</responsefieldlines>
+  <attachments>0</attachments>
+  <attachmentsrequired>0</attachmentsrequired>
+  <graderinfo format="html"><text><![CDATA[
+    <ul>
+      <li>æyo </li>
+      <li>œ</li>
+    </ul>
+  ]]></text></graderinfo>
+  <responsetemplate format="html"><text/></responsetemplate>
+  <tags>
+    <tag><text><![CDATA[essay]]></text></tag>
+  </tags>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>ÅŒ{1:MULTICHOICE:=chip~%10%chop#yes~chap#no.} »Å{1:SHORTANSWER:=B#toc~=C#«  »~*}« Å{1:NUMERICAL:=1:0~=2:0#«  »~3:0}Œ{1:MULTICHOICE_V:=chip#yes~%10%chop~chap#no.}</P><P>Œ{1:MULTICHOICE_H:=chip#yes~%10%chop~chap#no.}</P><P></p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <tags>
+    <tag><text><![CDATA[cloze]]></text></tag>
+  </tags>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tikz-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tikz-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tikz-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,234 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/TikZ</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAHlBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAACGjDitAAAACXRSTlMAESJEiJm7zO6nttlqAAAAIklEQVQI12NgwAlEgJjJ 
+tRJIMhp4gkXIJAWARFpnmQOmFQA1jwXeV/vvCgAAAABJRU5ErkJggg== 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAVUlEQVQI12NgwAQSHU0MDIyNDPUBDBxfGfgPMLB/B5FAYN8AItcIMDCwdE8EMZlW 
+C4AoObAs91cGnosM3D8Y+D+B2FwODPIHGBinuZwGqmGuMMBiEwCKERKuaM1mNQAAAABJRU5ErkJg 
+gg== 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvd7qAo 
+0mEAAABeSURBVAjXY2DAASI6BIAkhwP7BiAVqsD4AEgtaABRbAENLECKQyiB8wIDA2s7g10CSAPz 
+NbC+KAMQqQUR2sjAEMDAICXAwAbkd7QK+AgwMC7QfneFgYHJgCFCAbvNABJmEbBCn/VAAAAAAElF 
+TkSuQmCC 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iqu8zd7v+y 
+XhgAAABTSURBVAjXY2DABNMc3QMYGN69ewFk7+hQAJILwOIQcklFIZC8xpADlHBg4AYLcjxiYHFg 
+4HjCwPsARHIVMHBeYOAwYJAtYGBoc90BVMHcpoDFJgDhHRLk6uL+ygAAAABJRU5ErkJggg== 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAUElEQVQI12NgwAAREGolmGT8CqbYHoAprglgSl8BTHVCVFwCUxwNYMobTDNe5CsA 
+UtIG9gZAzinHOiCHOyTzThpYzQsHEMn8Gcxhf4CsHQQAyX8PqblssX8AAAAASUVORK5CYII= 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Matching]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAHlBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAACGjDitAAAACXRSTlMAESJEiJm7zO6nttlqAAAAIklEQVQI12NgwAlEgJjJ 
+tRJIMhp4gkXIJAWARFpnmQOmFQA1jwXeV/vvCgAAAABJRU5ErkJggg== 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAVElEQVQI12NgwAUkZjcxMDAuYpxnwMApwCB3gYHvEQPXFwaeRwwcX0DyPJ9ApH4D 
+iNwDIjgOgshMEME6gUGJgcGCgaGIgflGR+cFBt7///9vwLQDABVCEvmq/3YdAAAAAElFTkSuQmCC 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAVUlEQVQI12NgwAQSHU0MDIyNDPUBDBxfGfgPMLB/B5FAYN8AItcIMDCwdE8EMZlW 
+C4AoObAs91cGnosM3D8Y+D+B2FwODPIHGBinuZwGqmGuMMBiEwCKERKuaM1mNQAAAABJRU5ErkJg 
+gg== 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAJ1BMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAilU6eAAAADHRSTlMAESIzRGZ3iLvM3e4/H40nAAAAPUlE 
+QVQI12NgwA08QATjChDJPgNEmnaAyAIQyaYAIs0YQGQBiGRTAJFmDCDSvbz8VClI6QkGONlxuh3T 
+BgCaoQz0SHFqtgAAAABJRU5ErkJggg== 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iqu8zd7v+y 
+XhgAAABTSURBVAjXY2DABNMc3QMYGN69ewFk7+hQAJILwOIQcklFIZC8xpADlHBg4AYLcjxiYHFg 
+4HjCwPsARHIVMHBeYOAwYJAtYGBoc90BVMHcpoDFJgDhHRLk6uL+ygAAAABJRU5ErkJggg== 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAVUlEQVQI12NgwAQSHU0MDIyNDPUBDBxfGfgPMLB/B5FAYN8AItcIMDCwdE8EMZlW 
+C4AoObAs91cGnosM3D8Y+D+B2FwODPIHGBinuZwGqmGuMMBiEwCKERKuaM1mNQAAAABJRU5ErkJg 
+gg== 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAVElEQVQI12NgwAUkZjcxMDAuYpxnwMApwCB3gYHvEQPXFwaeRwwcX0DyPJ9ApH4D 
+iNwDIjgOgshMEME6gUGJgcGCgaGIgflGR+cFBt7///9vwLQDABVCEvmq/3YdAAAAAElFTkSuQmCC 
+"></p>]]></text></answer>
+  </subquestion>
+</question>
+<question type="shortanswer">
+  <name format="html">
+    <text><![CDATA[Short]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAHlBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAACGjDitAAAACXRSTlMAESJEiJm7zO6nttlqAAAAIklEQVQI12NgwAlEgJjJ 
+tRJIMhp4gkXIJAWARFpnmQOmFQA1jwXeV/vvCgAAAABJRU5ErkJggg== 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <usecase>0</usecase>
+  <answer fraction="100" format="plain_text">
+    <text>3</text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvd7qAo 
+0mEAAABeSURBVAjXY2DAASI6BIAkhwP7BiAVqsD4AEgtaABRbAENLECKQyiB8wIDA2s7g10CSAPz 
+NbC+KAMQqQUR2sjAEMDAICXAwAbkd7QK+AgwMC7QfneFgYHJgCFCAbvNABJmEbBCn/VAAAAAAElF 
+TkSuQmCC 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>5</text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAUElEQVQI12NgwAAREGolmGT8CqbYHoAprglgSl8BTHVCVFwCUxwNYMobTDNe5CsA 
+UtIG9gZAzinHOiCHOyTzThpYzQsHEMn8Gcxhf4CsHQQAyX8PqblssX8AAAAASUVORK5CYII= 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAHlBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAACGjDitAAAACXRSTlMAESJEiJm7zO6nttlqAAAAIklEQVQI12NgwAlEgJjJ 
+tRJIMhp4gkXIJAWARFpnmQOmFQA1jwXeV/vvCgAAAABJRU5ErkJggg== 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>3</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvd7qAo 
+0mEAAABeSURBVAjXY2DAASI6BIAkhwP7BiAVqsD4AEgtaABRbAENLECKQyiB8wIDA2s7g10CSAPz 
+NbC+KAMQqQUR2sjAEMDAICXAwAbkd7QK+AgwMC7QfneFgYHJgCFCAbvNABJmEbBCn/VAAAAAAElF 
+TkSuQmCC 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>5</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAUElEQVQI12NgwAAREGolmGT8CqbYHoAprglgSl8BTHVCVFwCUxwNYMobTDNe5CsA 
+UtIG9gZAzinHOiCHOyTzThpYzQsHEMn8Gcxhf4CsHQQAyX8PqblssX8AAAAASUVORK5CYII= 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAHlBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAACGjDitAAAACXRSTlMAESJEiJm7zO6nttlqAAAAIklEQVQI12NgwAlEgJjJ 
+tRJIMhp4gkXIJAWARFpnmQOmFQA1jwXeV/vvCgAAAABJRU5ErkJggg== 
+"> {1:MULTICHOICE_HS:=<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAVUlEQVQI12NgwAQSHU0MDIyNDPUBDBxfGfgPMLB/B5FAYN8AItcIMDCwdE8EMZlW 
+C4AoObAs91cGnosM3D8Y+D+B2FwODPIHGBinuZwGqmGuMMBiEwCKERKuaM1mNQAAAABJRU5ErkJg 
+gg== 
+">#<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvd7qAo 
+0mEAAABeSURBVAjXY2DAASI6BIAkhwP7BiAVqsD4AEgtaABRbAENLECKQyiB8wIDA2s7g10CSAPz 
+NbC+KAMQqQUR2sjAEMDAICXAwAbkd7QK+AgwMC7QfneFgYHJgCFCAbvNABJmEbBCn/VAAAAAAElF 
+TkSuQmCC 
+">~<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iqu8zd7v+y 
+XhgAAABTSURBVAjXY2DABNMc3QMYGN69ewFk7+hQAJILwOIQcklFIZC8xpADlHBg4AYLcjxiYHFg 
+4HjCwPsARHIVMHBeYOAwYJAtYGBoc90BVMHcpoDFJgDhHRLk6uL+ygAAAABJRU5ErkJggg== 
+">#<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAUElEQVQI12NgwAAREGolmGT8CqbYHoAprglgSl8BTHVCVFwCUxwNYMobTDNe5CsA 
+UtIG9gZAzinHOiCHOyTzThpYzQsHEMn8Gcxhf4CsHQQAyX8PqblssX8AAAAASUVORK5CYII= 
+">}</P><P><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAHlBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAACGjDitAAAACXRSTlMAESJEiJm7zO6nttlqAAAAIklEQVQI12NgwAlEgJjJ 
+tRJIMhp4gkXIJAWARFpnmQOmFQA1jwXeV/vvCgAAAABJRU5ErkJggg== 
+"> {1:SHORTANSWER:=3#<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvd7qAo 
+0mEAAABeSURBVAjXY2DAASI6BIAkhwP7BiAVqsD4AEgtaABRbAENLECKQyiB8wIDA2s7g10CSAPz 
+NbC+KAMQqQUR2sjAEMDAICXAwAbkd7QK+AgwMC7QfneFgYHJgCFCAbvNABJmEbBCn/VAAAAAAElF 
+TkSuQmCC 
+">~=5#<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAUElEQVQI12NgwAAREGolmGT8CqbYHoAprglgSl8BTHVCVFwCUxwNYMobTDNe5CsA 
+UtIG9gZAzinHOiCHOyTzThpYzQsHEMn8Gcxhf4CsHQQAyX8PqblssX8AAAAASUVORK5CYII= 
+">}</P><P><IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAVBAMAAACNnGLAAAAAHlBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAACGjDitAAAACXRSTlMAESJEiJm7zO6nttlqAAAAIklEQVQI12NgwAlEgJjJ 
+tRJIMhp4gkXIJAWARFpnmQOmFQA1jwXeV/vvCgAAAABJRU5ErkJggg== 
+"> {1:NUMERICAL:=3:0#<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAALVBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAOrOgAAAADnRSTlMAESIzRFVmd4iZqrvd7qAo 
+0mEAAABeSURBVAjXY2DAASI6BIAkhwP7BiAVqsD4AEgtaABRbAENLECKQyiB8wIDA2s7g10CSAPz 
+NbC+KAMQqQUR2sjAEMDAICXAwAbkd7QK+AgwMC7QfneFgYHJgCFCAbvNABJmEbBCn/VAAAAAAElF 
+TkSuQmCC 
+">~=5:0#<IMG SRC="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAVBAMAAABiXgn+AAAAMFBMVEX///8AAAAAAAAAAAAAAAAA 
+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv3aB7AAAAD3RSTlMAESIzRFVmd4iZqrvM 
+3e5GKvWZAAAAUElEQVQI12NgwAAREGolmGT8CqbYHoAprglgSl8BTHVCVFwCUxwNYMobTDNe5CsA 
+UtIG9gZAzinHOiCHOyTzThpYzQsHEMn8Gcxhf4CsHQQAyX8PqblssX8AAAAASUVORK5CYII= 
+">}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tikz_with_svg-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tikz_with_svg-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tikz_with_svg-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,388 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/TikZ</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NDEz 
+IiBoZWlnaHQ9IjEzLjI4NCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NDEzIDEzLjI4 
+NCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZyB0cmFuc2Zvcm09Im1hdHJpeCgxLjMzMzMgMCAwIC0xLjMzMzMgMCAxMy4yODQpIj48ZyB0 
+cmFuc2Zvcm09InRyYW5zbGF0ZSgyLjQ5MSw0Ljk4MSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRl 
+KC0yLjQ5MSwtMi40OSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAsLTIuNDkxKSI+PHRleHQg 
+dHJhbnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwxLjY2NCkiIGZpbGw9IiMwMDAwMDAiIGZvbnQt 
+ZmFtaWx5PSJMTVJvbWFuMTAiIGZvbnQtc2l6ZT0iOS45NjI2cHgiPjx0c3BhbiB4PSIwIiB5PSIw 
+Ij4xPC90c3Bhbj48L3RleHQ+PC9nPjwvZz48L2c+PC9nPjwvc3ZnPgo= 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NDEz 
+IiBoZWlnaHQ9IjEzLjI4NCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NDEzIDEzLjI4 
+NCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZyB0cmFuc2Zvcm09Im1hdHJpeCgxLjMzMzMgMCAwIC0xLjMzMzMgMCAxMy4yODQpIj48ZyB0 
+cmFuc2Zvcm09InRyYW5zbGF0ZSgyLjQ5MSw0Ljk4MSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRl 
+KC0yLjQ5MSwtMi40OSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAsLTIuNDkxKSI+PHRleHQg 
+dHJhbnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwxLjc3MykiIGZpbGw9IiMwMDAwMDAiIGZvbnQt 
+ZmFtaWx5PSJMTVJvbWFuMTAiIGZvbnQtc2l6ZT0iOS45NjI2cHgiPjx0c3BhbiB4PSIwIiB5PSIw 
+Ij4zPC90c3Bhbj48L3RleHQ+PC9nPjwvZz48L2c+PC9nPjwvc3ZnPgo= 
+"></p>]]></text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi43ODgi 
+IGhlaWdodD0iMTMuMjg0IiB2ZXJzaW9uPSIxLjEiIHZpZXdCb3g9IjAgMCA2Ljc4OCAxMy4yODQi 
+IHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zPSJodHRwOi8vd3d3L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>
+<question type="ddmatch">
+  <name format="html">
+    <text><![CDATA[Matching]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NDEz 
+IiBoZWlnaHQ9IjEzLjI4NCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NDEzIDEzLjI4 
+NCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZyB0cmFuc2Zvcm09Im1hdHJpeCgxLjMzMzMgMCAwIC0xLjMzMzMgMCAxMy4yODQpIj48ZyB0 
+cmFuc2Zvcm09InRyYW5zbGF0ZSgyLjQ5MSw0Ljk4MSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRl 
+KC0yLjQ5MSwtMi40OSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAsLTIuNDkxKSI+PHRleHQg 
+dHJhbnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwxLjY2NCkiIGZpbGw9IiMwMDAwMDAiIGZvbnQt 
+ZmFtaWx5PSJMTVJvbWFuMTAiIGZvbnQtc2l6ZT0iOS45NjI2cHgiPjx0c3BhbiB4PSIwIiB5PSIw 
+Ij4xPC90c3Bhbj48L3RleHQ+PC9nPjwvZz48L2c+PC9nPjwvc3ZnPgo= 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <shuffleanswers>1</shuffleanswers>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NDEz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5PSIw 
+Ij40PC90c3Bhbj48L3RleHQ+PC9nPjwvZz48L2c+PC9nPjwvc3ZnPgo= 
+"></p>]]></text>
+    <answer format="html"><text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NDEz 
+IiBoZWlnaHQ9IjEzLjI4NCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NDEzIDEzLjI4 
+NCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZyB0cmFuc2Zvcm09Im1hdHJpeCgxLjMzMzMgMCAwIC0xLjMzMzMgMCAxMy4yODQpIj48ZyB0 
+cmFuc2Zvcm09InRyYW5zbGF0ZSgyLjQ5MSw0Ljk4MSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRl 
+KC0yLjQ5MSwtMi40OSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAsLTIuNDkxKSI+PHRleHQg 
+dHJhbnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwxLjc3MykiIGZpbGw9IiMwMDAwMDAiIGZvbnQt 
+ZmFtaWx5PSJMTVJvbWFuMTAiIGZvbnQtc2l6ZT0iOS45NjI2cHgiPjx0c3BhbiB4PSIwIiB5PSIw 
+Ij41PC90c3Bhbj48L3RleHQ+PC9nPjwvZz48L2c+PC9nPjwvc3ZnPgo= 
+"> </p>]]></text></answer>
+  </subquestion>
+  <subquestion format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NDEz 
+IiBoZWlnaHQ9IjEzLjI4NCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NDEzIDEzL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idHJhbnNsYXRlKDAsLTIuNDkxKSI+PHRleHQg 
+dHJhbnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwxLjY2NCkiIGZpbGw9IiMwMDAwMDAiIGZvbnQt 
+ZmFtaWx5PSJMTVJvbWFuMTAiIGZvbnQtc2l6ZT0iOS45NjI2cHgiPjx0c3BhbiB4PSIwIiB5PSIw 
+Ij4yPC90c3Bhbj48L3RleHQ+PC9nPjwvZz48L2c+PC9nPjwvc3ZnPgo= 
+"></p>]]></text></answer>
+  </subquestion>
+</question>
+<question type="shortanswer">
+  <name format="html">
+    <text><![CDATA[Short]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NDEz 
+IiBoZWlnaHQ9IjEzLjI4NCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NDEzIDEzLjI4 
+NCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZyB0cmFuc2Zvcm09Im1hdHJpeCgxLjMzMzMgMCAwIC0xLjMzMzMgMCAxMy4yODQpIj48ZyB0 
+cmFuc2Zvcm09InRyYW5zbGF0ZSgyLjQ5MSw0Ljk4MSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRl 
+KC0yLjQ5MSwtMi40OSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAsLTIuNDkxKSI+PHRleHQg 
+dHJhbnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwxLjY2NCkiIGZpbGw9IiMwMDAwMDAiIGZvbnQt 
+ZmFtaWx5PSJMTVJvbWFuMTAiIGZvbnQtc2l6ZT0iOS45NjI2cHgiPjx0c3BhbiB4PSIwIiB5PSIw 
+Ij4xPC90c3Bhbj48L3RleHQ+PC9nPjwvZz48L2c+PC9nPjwvc3ZnPgo= 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <usecase>0</usecase>
+  <answer fraction="100" format="plain_text">
+    <text>3</text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi43ODgi 
+IGhlaWdodD0iMTMuMjg0IiB2ZXJzaW9uPSIxLjEiIHZpZXdCb3g9IjAgMCA2Ljc4OCAxMy4yODQi 
+IHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+ 
+PGcgdHJhbnNmb3JtPSJtYXRyaXgoMS4zMzMzIDAgMCAtMS4zMzMzIDAgMTMuMjg0KSI+PGcgdHJh 
+bnNmb3JtPSJ0cmFuc2xhdGUoMi41NDUsNC45ODEpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgt 
+Mi41NDUsLTIuNDkpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgwLC0yLjQ5MSkiPjx0ZXh0IHRy 
+YW5zZm9ybT0ibWF0cml4KDEsMCwwLC0xLDAsMS43NzMpIiBmaWxsPSIjMDAwMDAwIiBmb250LWZh 
+bWlseT0iTE1Sb21hbjEwIiBmb250LXNpemU9IjkuOTYyNnB4IiBmb250LXN0eWxlPSJpdGFsaWMi 
+Pjx0c3BhbiB4PSIwIiB5PSIwIj4yPC90c3Bhbj48L3RleHQ+PC9nPjwvZz48L2c+PC9nPjwvc3Zn 
+Pgo= 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>5</text>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi43ODgi 
+IGhlaWdodD0iMTMuMjg0IiB2ZXJzaW9uPSIxLjEiIHZpZXdCb3g9IjAgMCA2Ljc4OCAxMy4yODQi 
+IHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+ 
+PGcgdHJhbnNmb3JtPSJtYXRyaXgoMS4zMzMzIDAgMCAtMS4zMzMzIDAgMTMuMjg0KSI+PGcgdHJh 
+bnNmb3JtPSJ0cmFuc2xhdGUoMi41NDUsNC45ODEpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgt 
+Mi41NDUsLTIuNDkpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgwLC0yLjQ5MSkiPjx0ZXh0IHRy 
+YW5zZm9ybT0ibWF0cml4KDEsMCwwLC0xLDAsMi42MykiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFt 
+aWx5PSJMTVJvbWFuMTAiIGZvbnQtc2l6ZT0iOS45NjI2cHgiIGZvbnQtc3R5bGU9Iml0YWxpYyI+ 
+PHRzcGFuIHg9IjAiIHk9IjAiPjQ8L3RzcGFuPjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+ 
+Cg== 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Numerical]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NDEz 
+IiBoZWlnaHQ9IjEzLjI4NCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NDEzIDEzLjI4 
+NCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZyB0cmFuc2Zvcm09Im1hdHJpeCgxLjMzMzMgMCAwIC0xLjMzMzMgMCAxMy4yODQpIj48ZyB0 
+cmFuc2Zvcm09InRyYW5zbGF0ZSgyLjQ5MSw0Ljk4MSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRl 
+KC0yLjQ5MSwtMi40OSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAsLTIuNDkxKSI+PHRleHQg 
+dHJhbnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwxLjY2NCkiIGZpbGw9IiMwMDAwMDAiIGZvbnQt 
+ZmFtaWx5PSJMTVJvbWFuMTAiIGZvbnQtc2l6ZT0iOS45NjI2cHgiPjx0c3BhbiB4PSIwIiB5PSIw 
+Ij4xPC90c3Bhbj48L3RleHQ+PC9nPjwvZz48L2c+PC9nPjwvc3ZnPgo= 
+"> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>3</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi43ODgi 
+IGhlaWdodD0iMTMuMjg0IiB2ZXJzaW9uPSIxLjEiIHZpZXdCb3g9IjAgMCA2Ljc4OCAxMy4yODQi 
+IHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+ 
+PGcgdHJhbnNmb3JtPSJtYXRyaXgoMS4zMzMzIDAgMCAtMS4zMzMzIDAgMTMuMjg0KSI+PGcgdHJh 
+bnNmb3JtPSJ0cmFuc2xhdGUoMi41NDUsNC45ODEpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgt 
+Mi41NDUsLTIuNDkpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgwLC0yLjQ5MSkiPjx0ZXh0IHRy 
+YW5zZm9ybT0ibWF0cml4KDEsMCwwLC0xLDAsMS43NzMpIiBmaWxsPSIjMDAwMDAwIiBmb250LWZh 
+bWlseT0iTE1Sb21hbjEwIiBmb250LXNpemU9IjkuOTYyNnB4IiBmb250LXN0eWxlPSJpdGFsaWMi 
+Pjx0c3BhbiB4PSIwIiB5PSIwIj4yPC90c3Bhbj48L3RleHQ+PC9nPjwvZz48L2c+PC9nPjwvc3Zn 
+Pgo= 
+"></p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>5</text>
+    <tolerance>0</tolerance>
+    <feedback format="html"><text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi43ODgi 
+IGhlaWdodD0iMTMuMjg0IiB2ZXJzaW9uPSIxLjEiIHZpZXdCb3g9IjAgMCA2Ljc4OCAxMy4yODQi 
+IHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+ 
+PGcgdHJhbnNmb3JtPSJtYXRyaXgoMS4zMzMzIDAgMCAtMS4zMzMzIDAgMTMuMjg0KSI+PGcgdHJh 
+bnNmb3JtPSJ0cmFuc2xhdGUoMi41NDUsNC45ODEpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgt 
+Mi41NDUsLTIuNDkpIj48ZyB0cmFuc2Zvcm09InRyYW5zbGF0ZSgwLC0yLjQ5MSkiPjx0ZXh0IHRy 
+YW5zZm9ybT0ibWF0cml4KDEsMCwwLC0xLDAsMi42MykiIGZpbGw9IiMwMDAwMDAiIGZvbnQtZmFt 
+aWx5PSJMTVJvbWFuMTAiIGZvbnQtc2l6ZT0iOS45NjI2cHgiIGZvbnQtc3R5bGU9Iml0YWxpYyI+ 
+PHRzcGFuIHg9IjAiIHk9IjAiPjQ8L3RzcGFuPjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+ 
+Cg== 
+"></p>]]></text></feedback>
+  </answer>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[Cloze]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNi42NDEz 
+IiBoZWlnaHQ9IjEzLjI4NCIgdmVyc2lvbj0iMS4xIiB2aWV3Qm94PSIwIDAgNi42NDEzIDEzLjI4 
+NCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3Zn 
+Ij48ZyB0cmFuc2Zvcm09Im1hdHJpeCgxLjMzMzMgMCAwIC0xLjMzMzMgMCAxMy4yODQpIj48ZyB0 
+cmFuc2Zvcm09InRyYW5zbGF0ZSgyLjQ5MSw0Ljk4MSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRl 
+KC0yLjQ5MSwtMi40OSkiPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAsLTIuNDkxKSI+PHRleHQg 
+dHJhbnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwxLjY2NCkiIGZpbGw9IiMwMDAwMDAiIGZvbnQt 
+ZmFtaWx5PSJMTVJvbWFuMTAiIGZvbnQtc2l6ZT0iOS45NjI2cHgiPjx0c3BhbiB4PSIwIiB5PSIw 
+Ij4xPC90c3Bhbj48L3RleHQ+PC9nPjwvZz48L2c+PC9nPjwvc3ZnPgo= 
+"> {1:MULTICHOICE_HS:=<IMG SRC="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iM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FuIHg9IjAiIHk9IjAiPjQ8L3RzcGFuPjwvdGV4dD48L2c+PC9nPjwvZz48L2c+PC9zdmc+ 
+Cg== 
+">}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tolerance-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tolerance-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_tolerance-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,84 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Tolerance</text>
+  </category>
+</question>
+ 
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Num 1]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Give a number </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1</text>
+    <tolerance>4</tolerance>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>0</text>
+    <tolerance>2</tolerance>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>*</text>
+    <feedback format="html"><text><![CDATA[<p>nope</p>]]></text></feedback>
+  </answer>
+</question>
+<question type="numerical">
+  <name format="html">
+    <text><![CDATA[Num 2]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Give a number </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>1,45E-3</text>
+    <tolerance>1,65e-4</tolerance>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>0</text>
+    <tolerance>0</tolerance>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>*</text>
+    <feedback format="html"><text><![CDATA[<p>nope</p>]]></text></feedback>
+  </answer>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[ClozeNum 1]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Give a number {1:NUMERICAL:=1:4~=0:3~*#nope}Give a number {1:NUMERICAL:=1:4~=0:2~*#nope}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+<question type="cloze">
+  <name format="html">
+    <text><![CDATA[ClozeNum 2]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Give a number {1:NUMERICAL:=1,45e-3:1,65E-4~=0:0~*#nope}</p>]]></text>
+  </questiontext>
+  <defaultgrade>1</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_truefalse-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_truefalse-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_truefalse-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,95 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Truefalse questions</text>
+  </category>
+</question>
+ 
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[Truefalse Test 1]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>This is a matching question. </p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>general feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="0" format="plain_text">
+    <text>true</text>
+    <feedback format="html"><text><![CDATA[<p>Feedback for students choosing ”true”</p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>false</text>
+    <feedback format="html"><text><![CDATA[<p> Feedback for students choosing ”false” </p>]]></text></feedback>
+  </answer>
+</question>
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[Truefalse Test 2]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>This is an essay question. </p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>general feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="0" format="plain_text">
+    <text>true</text>
+    <feedback format="html"><text><![CDATA[<p>Feedback for students choosing ”true” </p>]]></text></feedback>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>false</text>
+    <feedback format="html"><text><![CDATA[<p>Feedback for students choosing ”false”</p>]]></text></feedback>
+  </answer>
+</question>
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[Truefalse Test 3]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Please answer ”True”. </p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>general feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="100" format="plain_text">
+    <text>true</text>
+  </answer>
+  <answer fraction="0" format="plain_text">
+    <text>false</text>
+  </answer>
+</question>
+<question type="truefalse">
+  <name format="html">
+    <text><![CDATA[Truefalse Test 4]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p>Please answer ”False”. </p>]]></text>
+  </questiontext>
+  <defaultgrade>3</defaultgrade>
+  <generalfeedback format="html">
+    <text><![CDATA[<p>general feedback</p>]]></text>
+  </generalfeedback>
+  <penalty>1</penalty>
+  <hidden>0</hidden>
+  <answer fraction="0" format="plain_text">
+    <text>true</text>
+  </answer>
+  <answer fraction="100" format="plain_text">
+    <text>false</text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_verbatim-moodle.ref
===================================================================
--- trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_verbatim-moodle.ref	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/moodle/test/utf8ref/test_verbatim-moodle.ref	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<quiz>
+ 
+<question type="category">
+  <category>
+    <text>$course$/top/Verbatim</text>
+  </category>
+</question>
+ 
+<question type="multichoice">
+  <name format="html">
+    <text><![CDATA[Multi]]></text>
+  </name>
+  <questiontext format="html">
+    <text><![CDATA[<p><PRE style="border-top: thin solid; border-bottom: thin solid"><CODE>% !TeX encoding = UTF-8<BR/>% !TeX spellcheck = en_US<BR/>% !TEX TS-program = xelatex<BR/>\documentclass{article}<BR/>\usepackage[nostamp]{moodle}<BR/>\newif\iffvextra<BR/>\fvextratrue<BR/>\ifxetex % FOR XELATEX<BR/> \usepackage{fontspec}<BR/>\else %% FOR PDFLATEX<BR/> \usepackage[utf8]{inputenc} % necessary<BR/> \usepackage[T1]{fontenc} % necessary<BR/>\fi<BR/></CODE></PRE> </p>]]></text>
+  </questiontext>
+  <defaultgrade>1.0</defaultgrade>
+  <generalfeedback format="html"><text/></generalfeedback>
+  <penalty>0.10</penalty>
+  <hidden>0</hidden>
+  <single>true</single>
+  <shuffleanswers>1</shuffleanswers>
+  <answernumbering>abc</answernumbering>
+  <answer fraction="100" format="html">
+    <text><![CDATA[<p>test</p>]]></text>
+  </answer>
+  <answer fraction="0" format="html">
+    <text><![CDATA[<p>toast</p>]]></text>
+  </answer>
+</question>
+ 
+</quiz>

Added: trunk/Master/texmf-dist/source/latex/moodle/makefile
===================================================================
--- trunk/Master/texmf-dist/source/latex/moodle/makefile	                        (rev 0)
+++ trunk/Master/texmf-dist/source/latex/moodle/makefile	2021-01-05 22:05:39 UTC (rev 57334)
@@ -0,0 +1,90 @@
+PROJECT_NAME=moodle
+FILE_CLEAN=*.sty *.log *.aux *.auxlock *.out *.blg *.bbl *.toc *.xml *.bcf *.synctex.gz *~ *.nav *.snm *.idx *.ilg *.ind _minted-* *.glo *.gls *.dpth
+LATEX=latex
+PDFLATEX=lualatex
+LATEXFLAGS=-interaction=nonstopmode -shell-escape
+DIFFTOOL=meld
+MAKEINDEX=makeindex
+TESTDIR=test
+RECURSIVE_TARGETS= all clean distclean test
+RERUNLATEX= '(There were undefined references|Rerun to get (cross-references|the bars) right)'
+
+ifndef DEBUG
+	DEBUG=> /dev/null
+endif
+
+.DEFAULT_GOAL := all
+
+.PHONY: all clean distclean test dist install
+
+all: $(PROJECT_NAME).pdf $(PROJECT_NAME).sty
+
+clean: $(TESTDIR)/clean
+	rm -rf $(FILE_CLEAN)
+
+distclean: clean
+
+distclean: $(TESTDIR)/distclean
+	rm -rf *.pdf *.xml *.zip
+	rm -rf texmf/ $(@mkdir -p ./$(PROJECT_NAME)/
+
+test: $(TESTDIR)/test
+
+dist: test $(PROJECT_NAME).zip
+	@mv $(PROJECT_NAME).zip $(PROJECT_NAME)_$(shell date +"%Y-%m-%d").zip
+	@mv $(PROJECT_NAME).tds.zip $(PROJECT_NAME)_$(shell date +"%Y-%m-%d").tds.zip
+	@cp $(PROJECT_NAME).pdf $(PROJECT_NAME)_$(shell date +"%Y-%m-%d").pdf
+	@$(MAKE) clean -C .
+
+$(PROJECT_NAME).zip: $(PROJECT_NAME).tds.zip $(PROJECT_NAME).pdf
+	@mkdir -p ./$(PROJECT_NAME)/
+	@cp $(PROJECT_NAME).dtx ./$(PROJECT_NAME)/
+	@cp $(PROJECT_NAME).ins ./$(PROJECT_NAME)/
+	@cp $(PROJECT_NAME).pdf ./$(PROJECT_NAME)/
+	@cp README.ctan ./$(PROJECT_NAME)/README.md
+	zip -r9 $(PROJECT_NAME).zip $(PROJECT_NAME).tds.zip $(PROJECT_NAME)
+
+$(PROJECT_NAME).tds.zip : $(PROJECT_NAME).pdf $(PROJECT_NAME).sty
+	@mkdir -p ./texmf/tex/latex/$(PROJECT_NAME)/
+	@mkdir -p ./texmf/source/latex/$(PROJECT_NAME)/
+	@mkdir -p ./texmf/doc/latex/$(PROJECT_NAME)/
+	@cp $(PROJECT_NAME).sty ./texmf/tex/latex/$(PROJECT_NAME)/
+	@cp $(PROJECT_NAME).dtx ./texmf/source/latex/$(PROJECT_NAME)/
+	@cp $(PROJECT_NAME).ins ./texmf/source/latex/$(PROJECT_NAME)/
+	@cp makefile ./texmf/source/latex/$(PROJECT_NAME)/
+	@cp $(PROJECT_NAME).pdf ./texmf/doc/latex/$(PROJECT_NAME)/
+	@cp README.ctan ./texmf/doc/latex/$(PROJECT_NAME)/README.md
+	@cp LICENSE ./texmf/doc/latex/$(PROJECT_NAME)/
+	@$(MAKE) distclean -C $(TESTDIR)
+	@rsync -avq --exclude='$(TESTDIR)/extra' --exclude='$(TESTDIR)/media' --exclude='$(TESTDIR)/dev_*.tex' $(TESTDIR) ./texmf/doc/latex/$(PROJECT_NAME)
+	@cd texmf/ ; zip -r9 ../$(PROJECT_NAME).tds.zip tex source doc
+	
+install: $(PROJECT_NAME).tds.zip
+	@unzip -d ~/texmf ./$(PROJECT_NAME).tds.zip 
+
+$(PROJECT_NAME).sty: $(PROJECT_NAME).dtx
+
+$(PROJECT_NAME).pdf: $(PROJECT_NAME).dtx $(PROJECT_NAME).gls
+
+%.glo: %.dtx
+	$(PDFLATEX) $(LATEXFLAGS) $< $(DEBUG)
+
+%.gls: %.glo
+	$(MAKEINDEX) -s gglo.ist -o $@ $< $(DEBUG)
+
+%.pdf: %.tex
+	$(PDFLATEX) $(LATEXFLAGS) $< $(DEBUG)
+
+%.pdf: %.dtx
+	$(PDFLATEX) $(LATEXFLAGS) $< $(DEBUG)
+	@if egrep -q $(RERUNLATEX) $(basename $@).log ; then \
+		echo "\trequires a new $(PDFLATEX) pass..."; \
+		$(PDFLATEX) $(LATEXFLAGS) $< $(DEBUG); \
+	fi
+
+%.sty: %.ins
+	rm -rf $@
+	$(LATEX) $(LATEXFLAGS) $< $(DEBUG)
+	
+$(RECURSIVE_TARGETS:%=$(TESTDIR)/%) :
+	@$(MAKE) $(notdir $@) -C $(dir $@)


Property changes on: trunk/Master/texmf-dist/source/latex/moodle/makefile
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Modified: trunk/Master/texmf-dist/source/latex/moodle/moodle.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/moodle/moodle.dtx	2021-01-05 22:04:49 UTC (rev 57333)
+++ trunk/Master/texmf-dist/source/latex/moodle/moodle.dtx	2021-01-05 22:05:39 UTC (rev 57334)
@@ -1,7 +1,8 @@
 % \iffalse meta-comment
 %
 % moodle.dtx
-% Copyright 2016 by Anders O.F. Hendrickson (anders.hendrickson at snc.edu)
+% Copyright 2016 by Anders O.F. Hendrickson (anders.o.f.hendrickson AT gmail.com)
+% and 2019-2021 by Matthieu Guerquin-Kern (guerquin-kern AT crans.org).
 %
 % This work may be distributed and/or modified under the
 % conditions of the LaTeX Project Public License, either version 1.3
@@ -13,7 +14,7 @@
 %
 % This work has the LPPL maintenance status `maintained'.
 % 
-% The Current Maintainer of this work is Anders O.F. Hendrickson.
+% The Current Maintainer of this work is Matthieu Guerquin-Kern.
 %
 % This work consists of the files moodle.dtx and moodle.ins
 % and the derived files moodle.sty and getitems.sty.
@@ -27,14 +28,25 @@
 %<package>\NeedsTeXFormat{LaTeX2e}[1999/12/01]
 %<package>\ProvidesPackage{moodle}
 %<*package>
-    [2016/01/11 v0.5 Moodle quiz XML generation]
+    [2021/01/04 v0.8 Moodle quiz XML generation]
 %</package>
 %
 %<*driver>
-\documentclass{ltxdoc}
-\usepackage{moodle}
-\usepackage{amssymb}
-\usepackage{fancyvrb}
+\documentclass[a4paper]{ltxdoc}
+\usepackage{iftex}
+\ifPDFTeX
+  \usepackage[utf8]{inputenc} % necessary
+  \usepackage[T1]{fontenc} % necessary
+  \usepackage[protrusion=true,expansion]{microtype}
+  \usepackage[ttscale=.875]{libertine}
+\else % assuming LuaLaTeX or XeLaTeX
+  \usepackage{fontspec}
+  \setmainfont[Mapping=tex-text]{Linux Libertine O}
+\fi
+%\usepackage{moodle}[2020/07/09]
+\usepackage{amssymb,metalogo,multirow,threeparttable,booktabs,hyperref,tikz,minted,changelog}
+\usetikzlibrary{arrows,positioning,decorations.text}
+%\usemintedstyle{Wombat}
 \EnableCrossrefs         
 \CodelineIndex
 \OnlyDescription
@@ -41,13 +53,12 @@
 \RecordChanges
 \begin{document}
   \DocInput{moodle.dtx}
-  \PrintChanges
-  %\PrintIndex
+  %\PrintChanges
 \end{document}
 %</driver>
 % \fi
 %
-% \CheckSum{3827}
+% \CheckSum{7442} ^^A Comment \OnlyDescription above to adjust
 %
 % \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
@@ -66,10 +77,8 @@
 %   Right brace   \}     Tilde         \~}
 %
 %
-% \changes{v0.5}{2016/01/05}{Initial version}
+% \GetFileInfo{\jobname.dtx}
 %
-% \GetFileInfo{moodle.sty}
-%
 % \DoNotIndex{\newcommand,\newenvironment,\def}
 % 
 %
@@ -77,8 +86,12 @@
 %        generating Moodle quizzes via \LaTeX%
 %        \thanks{This document
 %                corresponds to \textsf{moodle.sty}~\fileversion, dated \filedate.}}
-% \author{Anders Hendrickson\\ St.~Norbert College, De~Pere, WI, USA \\ \url{anders.hendrickson at snc.edu}}
-% \date{January 11, 2016}
+% \author{Anders Hendrickson\footnote{original author of the package (\texttt{v0.5}), inactive.}\\	
+% \texttt{anders.o.f.hendrickson AT gmail.com} \and
+% Matthieu Guerquin-Kern\footnote{current maintainer, author of the updates (\texttt{v0.6}
+% to \texttt{v0.8}), partially funded by \href{https://www.ensea.fr/en/}{ENSEA Graduate School}, France.}\\
+% \href{mailto:guerquin-kern AT crans.org}{guerquin-kern AT crans.org}}
+% \date{January 4, 2021}
 % 
 % \maketitle
 %
@@ -87,8 +100,8 @@
 % \section{Motivation}
 %
 % The acronym Moodle stands for ``Modular Object-Oriented Dynamic Learning Environment.''
-% It is an open source learning management system employed by many universities, colleges, 
-% and high schools to provide digital access to course materials, such as
+% It is an open source learning management system (LMS) employed by many universities,
+% colleges, and high schools to provide digital access to course materials, such as
 % notes, video lectures, forums, and the like; see
 % \url{https://moodle.com/moodle-lms/} for more information. 
 % One of the many useful
@@ -148,7 +161,7 @@
 % and the PDF may be previewed onscreen or printed out for ease of proofreading.
 % Mathematical graphics can be integrated within the main file through \TikZ,
 % and of course \LaTeX\ macros can be customized.
-% Using the present \textsf{moodle.sty} package,
+% Using the present \textsf{moodle} package,
 % a quiz author can type a quiz using familiar \LaTeX\ syntax and document 
 % structure.  Upon compilation, \LaTeX\ will generate both a well-organized
 % PDF that is easy to proofread and an XML file that can be uploaded directly
@@ -155,14 +168,26 @@
 % to Moodle.  The entire process is far faster than using Moodle's own
 % web-based editor, makes it easier to catch one's mistakes, 
 % and the ultimate source code of one's work is a human-readable |.tex| file 
-% that can be archived, browsed, and edited offline.
+% that can be archived, versioned, browsed, and edited offline.
 % 
+% Strictly speaking, the \textsf{moodle} package does not generate quizzes:
+% it generates question banks that can be imported in the LMS. The teacher
+% still needs to compose manually a quiz from the question banks. Hopefully,
+% two Moodle features supported by the package make this task easier:
+% categories and tags.
+%
+% In this documentation the LMS is referred to as Moodle (uppercase M and
+% roman font) while the \LaTeX\ package that is documented here is referred
+% to as \textsf{moodle} (all lower case and sans serif font).
+% 
 % \section{Workflow}
-% The process of creating a quiz in Moodle using this package is as follows:
+% The process of creating a quiz in Moodle using this package is depicted in
+% Figure~\ref{fig:workflow}. It follows a few steps:
 % \begin{enumerate}
-%   \item Write a \LaTeX\ document using |\usepackage{moodle}| as described below.
-%   \item Compile the document to PDF using pdf\LaTeX.  This will also produce the file
-%         \meta{jobname}|-moodle.xml|.
+%   \item Write a \LaTeX\ document using |\usepackage{moodle}| as described 
+% below.
+%   \item Compile the document to PDF using pdf\LaTeX\, \XeLaTeX\ or \LuaLaTeX.
+% This will also produce the file \meta{jobname}|-moodle.xml|.
 %   \item Open Moodle, navigate to the desired course,
 %         and under ``Question bank'' select ``Import.''
 %   \item Select ``Moodle XML format,'' choose the XML file to upload, and press ``Import.''
@@ -169,7 +194,49 @@
 %   \item After Moodle verifies that the questions have been imported correctly,
 %         you may add them to your quizzes.
 % \end{enumerate}
-% 
+% \begin{figure}[tbp]
+% \centering
+% \begin{tikzpicture}[node distance=1,auto,bend 
+% angle=45,box/.style={rectangle,draw=blue!50,rounded corners=3,top 
+% 	color=white,bottom color=black!20,thick,align=center,text 
+% 	width=2.5cm},elmt/.style={font=\itshape,align=left},
+% cmnt/.style={font=\footnotesize,align=center},
+% bigcmnt/.style={font=\normalsize,align=center},pre/.style={<-,>=stealth',thick},
+% post/.style={->,>=stealth',thick}, prepost/.style={<->,>=stealth',thick}]
+% \draw[white,fill=orange!20,rounded corners=10]
+% (-1.5,-.7)--++(0,1.4)--++(10.3,0)--++(0,-3.3)--++(-6.7,0)--++(-.25,1.725)--cycle;
+% \node[orange!80!black,above] (dev) at (7.5,-2.6) {\textit{Developpement}};
+% \fill[green,fill opacity=.2,rounded corners=10]
+% (-1.5,.7)--++(3,0)--++(0.5,-3.4)--++(6.8,0)--++(0,-2)--++(-10.3,0)--cycle;
+% \node[green!80!black,below] (dev) at (7.5,-2.7) {\textit{Publishing}}; 
+% \node[box,text width=2cm] (tex) {\texttt{.tex} source file};
+% \node[rectangle,fill=white,draw,align=center,text 
+% width=1.5cm,below=of tex] (compfinal) {\LaTeX{}\\ engine};
+% \node[rectangle,fill=white,draw,align=center,text width=1.5cm,right=of tex,xshift=4.5cm]
+% (compdraft) {\LaTeX{}\\ engine};
+% \node[box,right=of compfinal,xshift=.5cm] (pdf) {\texttt{.pdf} file for proofreading};
+% \node[rectangle,fill=white,draw,align=center,text width=2cm,below=of compfinal] (extern) 
+% {Picture\\processing};
+% \draw (pdf|-extern) node[box,anchor=center] (xml) {\texttt{.xml} file\\\footnotesize(pictures embedded)};
+% \draw (compdraft|-xml)
+% node[rectangle,fill=white,draw,align=center,text width=1.5cm,anchor=center] (moodle) 
+% {Moodle\\Server};
+% \draw (tex) edge [post,bend right=10] node[cmnt,pos=.5,left] {\texttt{final}} (compfinal);
+% \draw (tex) edge [post,bend left=10] node[cmnt,pos=.5,below] {\texttt{draft}} (compdraft);
+% \draw (compdraft) edge [post,bend left=10] (pdf);
+% \draw (compfinal) edge [post] (pdf);
+% \draw (compfinal) edge [post,bend left=10] (xml);
+% \draw (compfinal) edge [post,bend right=30] node[cmnt,black!40,pos=.5,text width=1cm,left]
+% {\texttt{tikz}, \texttt{.png}, \texttt{.jpg}} (extern);
+% \draw (extern) edge [post,green,bend right=30] node[cmnt,black!40,pos=.5,below,right]
+% {\texttt{base64}} (compfinal);
+% \draw (pdf) edge [post,red,bend right=15] node[sloped,cmnt,pos=.5,above] {improve} (tex);
+% \draw (xml) edge [post,red] node[cmnt,pos=.5,below] {import} (moodle);
+% \end{tikzpicture}
+% \caption{Block diagram describing a typical workflow using the \textsf{moodle} package.}
+% \label{fig:workflow}
+% \end{figure}
+%
 % \section{Usage}\label{sect:usage}
 % \subsection{Example Document}
 %
@@ -177,35 +244,34 @@
 % and editing Moodle quizzes through the web interface.
 % The |xkeyval| package is used to provide a key-value interface.
 % Here is a simple example document:
-% \begin{verbatim}
+% \begin{VerbatimOut}[gobble=1]{minted.doc.out}
 %   \documentclass[12pt]{article}
-%   \usepackage{moodle}
-%   
+%   \usepackage[section]{moodle}
+%   \moodleregisternewcommands
+%   \newcommand\monomial[1]{x^{#1}}
+%   \newcommand\sillyanswer{What!?}
 %   \begin{document}
-%   
 %   \begin{quiz}{My first quiz}
 %     \begin{numerical}[points=2]{Basic addition}
 %       What is $8+3$?
 %       \item 11
 %     \end{numerical}
-%     
-%     \begin{shortanswer}[case sensitive=true]{Newton's name}
+%     \begin{shortanswer}[usecase]{Newton's name}
 %       What was Newton's first name?
 %       \item Isaac
-%       \item[fraction=0, feedback={No, silly!}] Fig
-%       \item{fraction=0} Sir
+%       \item[fraction=0, feedback={\sillyanswer}] Fig
+%       \item[fraction=0] Sir
 %     \end{shortanswer}
-%     
 %     \begin{multi}[points=3]{A first derivative}
-%       What is the first derivative of $x^3$?
-%       \item  $\frac{1}{4} x^4+C$
-%       \item* $3x^2$
-%       \item  $51$
+%       What is the first derivative of $\monomial{3}$?
+%       \item $\frac{1}{4}\monomial{4}+C$
+%       \item[feedback={yes!}]* $3\monomial{2}$
+%       \item[feedback={\sillyanswer}]  $51$
 %     \end{multi}
 %   \end{quiz}
-%   
 %   \end{document}
-% \end{verbatim}
+% \end{VerbatimOut}
+% \inputminted[gobble=2,frame=lines]{latex}{minted.doc.out}
 % Key features to note in this first example are that a |quiz| environment
 % contains several question environments.
 % Each question takes a name as a mandatory argument, 
@@ -214,22 +280,77 @@
 % such as |itemize| or |enumerate|, in that answers are set off by 
 % |\item|'s, but the question itself is the text that occurs before
 % the first |\item|.
+%
+%^^A \DescribeMacro{\moodleregisternewcommands}\DescribeMacro{\htmlregister}
+%^^A Calling |\moodleregisternewcommands| tells the package to treat
+%^^A specifically the macros defined subsequently.
+%^^A This way, the macros that Moodle's \LaTeX\ renderer does not know
+%^^A about can be properly expanded in the XML file.
+%^^A This mechanism applies only to the macros defined using |\newcommand|
+%^^A and \emph{without} optional argument.
+%^^A Using |\htmlregister|\marg{macroname}, lets you declare a specific
+%^^A macro for expansion. This mechanism, instead, also applies to the
+%^^A macros defined using \TeX's primitive |\def|.
 % 
+% \subsection{Package Options}
 % \DescribeMacro{draft}
-% If the package option |draft| is invoked, by calling |\usepackage[draft]{moodle}|,
-% then no XML file will be generated.  This is especially useful while editing a quiz
-% containing graphics, so as to avoid the time spent converting image files.
+% \DescribeMacro{final}
+% If the package option |draft| is invoked, by calling
+% |\usepackage[draft]{moodle}| or |\documentclass[draft]{...}|, then no
+% XML file will be generated. This is especially useful while editing a
+% quiz containing graphics, so as to avoid the time spent converting
+% image files. The package option |final| might be useful if one wants
+% to avoid the option |draft| to be inherited from the |documentclass|.
 %
-% \newpage
+% \DescribeMacro{handout}
+% If the package option |handout| is invoked (|\usepackage[handout]{moodle}|),
+% the PDF file is generated clean from teacher-only information (answers,
+% points, penalty, feedback, tags) and, hence, can be given  to students for
+% classroom work. In particular, as would Moodle do, answers in
+% \texttt{matching} questions are shuffled and the option \texttt{shuffle}
+% triggers the shuffling of choices offered (\texttt{multi} and 
+% \texttt{matching}). This is achieved thanks to the package
+% \texttt{randomlist}, loaded if the option is invoked.
+% The XML file is generated as usual.
+%
+% \DescribeMacro{nostamp}
+% By default, the package will output a stamp as a comment in the XML
+% file. This stamp contains information gathered about the TeX engine,
+% the operating system used and the package version. For instance:
+% \begin{quote}\small
+% |<!-- This file was generated on 2020-11-30 by LuaLaTeX -->|\\
+% |<!-- running on Linux with the package moodle |\texttt{\fileversion}| -->|
+% \end{quote}
+% The package option
+% |nostamp| prevents this stamp to be written in the XML file.
+%
+% \DescribeMacro{section}
+% \DescribeMacro{section*}
+% \DescribeMacro{subsection}
+% \DescribeMacro{subsection*}
+% If the package option |section| is invoked (|\usepackage[section]{moodle}|),
+% then each quiz is represented by a different \LaTeX\ section. Starred
+% variants correspond to unnumbered sections or subsections. To preserve
+% compatibility with Version 0.5 of this package, the default is |subsection*|.
+% Consequently, |\usepackage{moodle}| is equivalent to
+% |\usepackage[subsection*]{moodle}|.
+%
+% \DescribeMacro{tikz} The package option \texttt{tikz} is described in section
+% \ref{subsec:tikz}.
+%
+% \DescribeMacro{svg} The package option \texttt{svg} is described in section
+% \ref{subsec:svg}.
+%
 % \subsection{Quiz and Question Environments}
 % 
 % \DescribeMacro{quiz}
 % A |.tex| document to generate Moodle quizzes contains one or more
 % |quiz| environments, within which various question environments are nested.
-% The required argument to the |quiz| environment names the ``question bank''
-% to which the questions inside will belong after being uploaded to moodle.
+% The required argument to the |quiz| environment names a category for Moodles
+% ``question bank'': after import, the questions defined in this environment
+% will be gathered in this category.
 % \begin{center}
-% |\begin{quiz}|\oarg{options}\marg{question bank name}%
+% |\begin{quiz}|\oarg{options}\marg{category name}%
 % \end{center}
 % There are no |quiz|-specific options,
 % but any \meta{options} set with |\begin{quiz}|
@@ -236,17 +357,25 @@
 % will be inherited by all questions contained within that |quiz| environment.
 % 
 % \DescribeMacro{\moodleset}
-% Options may also be set at any time with |\moodleset|\marg{options};
-% these changes are local to \TeX-groups.
-% \bigskip
+% Options may also be set outside question environments with
+% |\moodleset|\marg{options}; these changes are local to \TeX-groups.
+%
+% \DescribeMacro{\setcategory}\DescribeMacro{\setsubcategory}
+% Although the |quiz| environment defines a category by its own, one can change
+% the current category inside the quiz environment and in between questions,
+% using the macro |\setcategory|\marg{category name}. A subcategory can also be
+% defined with |\setsubcategory|\marg{subcategory name}. The categories and
+% subcategories are reflected in the PDF file as sections, subsections, or
+% subsubsections, in accordance to the package setting |section|, |section*|,
+% |subsection|, or |subsection*|.
 % 
 % The syntax for each question environment is
 % \begin{quote}
 %   |\begin|\marg{question type}\oarg{question options}\marg{question name} \\
 %   \rule{2em}{0pt}\meta{question text} \\
-%   \rule{2em}{0pt}|\item| \meta{item} \\
+%   \rule{2em}{0pt}|\item|\oarg{item options} \meta{item} \\
 %   \rule{2em}{0pt}\quad$\vdots$ \\
-%   \rule{2em}{0pt}|\item| \meta{item} \\
+%   \rule{2em}{0pt}|\item|\oarg{item options} \meta{item} \\
 %   |\end|\marg{question type}
 % \end{quote}
 % The meaning of the \meta{item}s varies depending on the question type,
@@ -268,13 +397,54 @@
 % \DescribeMacro{fraction}
 % In most question types, it is possible to designate some answers as being
 % worth partial credit---that is, some fraction of a completely correct answer.
-% The |fraction| key may be set to any integer from |0| (entirely wrong) to |100| (entirely correct).
+% The |fraction| key may be set to any of the values given in Table~\ref{tab:fraction}, 
+% from |0| (entirely wrong) to |100| (entirely correct).
 % 
+% \begin{table}[tbp]
+% \centering
+% \caption{\href{https://github.com/moodle/moodle/blob/MOODLE\_310\_STABLE/question/engine/bank.php\#L339}{Valid positive options} for the \texttt{fraction} key: $100\cdot(p/q)$.}
+% \label{tab:fraction}
+% \footnotesize
+% \begin{tabular}{l*{10}{l}}
+% \toprule
+% Denominator $q$ & \multicolumn{10}{c}{Numerator $p$}\\
+% \cmidrule{2-11}
+% & 0 & 1 & 2 & 3 & 4 & 5 & 6 & 7 & 8 & 9\\
+% \cmidrule(lr){1-1}\cmidrule(lr){2-2}\cmidrule(lr){3-3}\cmidrule(lr){4-4}
+% \cmidrule(lr){5-5}\cmidrule(lr){6-6}\cmidrule(lr){7-7}\cmidrule(lr){8-8}
+% \cmidrule(lr){9-9}\cmidrule(lr){10-10}\cmidrule(lr){11-11}
+% 20 & 0&5&&&&&&&&\\\cmidrule(lr){1-1}
+% 10 & &10&20&30&40&50&60&70&80&90\\\cmidrule(lr){1-1}
+% 9 & &11.11111&&&&&&&&100\\\cmidrule(lr){1-1}
+% 8 & &12.5&&&&&&&100&\\\cmidrule(lr){1-1}
+% 7 & &14.28571&&&&&&100&&\\\cmidrule(lr){1-1}
+% 6 & &16.66667&&&&83.33333&100&&&\\\cmidrule(lr){1-1}
+% 5 & &20&&&80&100&&&&\\\cmidrule(lr){1-1}
+% 4 & &25&&75&100&&&&&\\\cmidrule(lr){1-1}
+% 3 & &33.33333&66.66667&100&&&&&&\\\cmidrule(lr){1-1}
+% 2 & &50&100&&&&&&&\\\cmidrule(lr){1-1}
+% 1 & 0&100&&&&&&&&\\\cmidrule(lr){1-1}
+% \bottomrule
+% \end{tabular}
+% \end{table}
+% In questions where several choices can be selected (see |multi| with the option
+% |multiple|), positive fractions must sum up to exactly 100. It is also possible to set
+% negative fractions (from -100 to 0) for wrong choices, in order to prevent the
+% selection of all choices from leading to a good grade.
+% In this case, the value ranging from -100 to 0 must be the opposite of one of the
+% values listed in Table~\ref{tab:fraction}.
+% 
+% \DescribeMacro{fractiontol}
+% The package tries to match the |fraction| key to one of the admissible values.
+% To this end, the tolerance is controlled by the |fractiontol| key. It defaults
+% to |0.01| but may be changed. When no admissible fraction value is matched, the
+% package throws an error.
+%
 % \DescribeMacro{feedback}
 % The |feedback| key sets text that will appear to the student after completing the quiz.
 % For example, one might set 
 % \begin{center}
-%   |feedback={A question like this will appear on the exam.}|
+%   |feedback={This question might show up in the final exam.}|
 % \end{center}
 % The desired feedback should be included in braces.
 % 
@@ -282,13 +452,56 @@
 % question, then that feedback will appear to each student regardless of the student's answer.
 % Answer-specific feedback (perhaps explaining a common mistake)
 % may also be given by setting the |feedback| key \emph{at the individual answer}.
+%
+% \DescribeMacro{tags}
+% The |tags| key sets a keyword for the question that will be taken into account by Moodle for
+% filtering purposes or classification of questions inside the question bank. It is possible
+% for instance to build a quiz with questions cherry-picked among the set of questions holding
+% a particular tag.
+% For example, one might set 
+% \begin{center}
+%   |tags={easy}|
+% \end{center}
+% The desired tag should be included in braces.
+%
+% Tags can be assigned at two levels.  If the |tags| key is set at the quiz level,
+% then that tags will be assigned by default to each question of the quiz.
+% Question-specific tags can be assigned by setting the |tags| key \emph{at the question level}.
+% Since only single tag is supported, the tag a the question-level overrides eventual tags
+% specified at the quiz-level.
 % 
-% \newpage
 % \subsection{Question Types}
 % 
-% We next discuss the various question types supported by \textsf{moodle.sty}
+% We next discuss the various question types supported by \textsf{moodle}
 % and the options that may be set.
+%
+%\subsubsection{True/False}
 % 
+% \DescribeMacro{truefalse}
+% The syntax for a True/False question is as follows:
+% \begin{quote}
+%   |\begin{truefalse}|\oarg{question options}\marg{question name} \\
+%   \rule{2em}{0pt}\meta{question text} \\
+%   \rule{2em}{0pt}|\item*| \meta{feedback when ``true" is chosen} \\
+%   \rule{2em}{0pt}|\item| \meta{feedback when ``false" is chosen} \\
+%   |\end{truefalse}|
+% \end{quote}
+% The correct answer is designated by the asterisk |*| after the |\item|;
+% it need not appear first in the list.
+%
+% Answer-specific feedback can also be defined as an item option, similarly to
+% other types.
+% \begin{quote}
+%   |\begin{truefalse}|\oarg{question options}\marg{question name} \\
+%   \rule{2em}{0pt}\meta{question text} \\
+%   \rule{2em}{0pt}|\item[feedback={|\meta{When ``true" is chosen}|}]*| \\
+%   |\end{truefalse}|
+% \end{quote}
+% Note that, in this example, no feedback is defined for the incorrect answer
+% ``False": the corresponding item can be omitted.
+% 
+% With the True/False question type, the |penalty| key has no effect.
+%
 % \subsubsection{Multiple Choice}
 % 
 % \DescribeMacro{multi}
@@ -319,13 +532,15 @@
 % which mirror the usual \LaTeX\ syntax:
 % |alph|, |Alph|, |arabic|, |roman|, |Roman|, and |none|.
 % Calling |numbering=none| produces an unnumbered list of answers.
-% The Moodle syntax of |abc|, |ABC|, |123|, |iii|, and |IIII| is also acceptable,
-% but note that it requires \emph{four} |I|'s to obtain upper-case Roman numerals this way.
+% The Moodle syntax of |abc|, |ABCD|, |123|, |iii|, and |IIII| is also 
+% acceptable,
+% but note that it requires \emph{four} capital letters to obtain
+% upper-case Roman or alphabetic numerals this way.
 % 
 % \DescribeMacro{fraction}
 % The |fraction| key can be used to designate some wrong answers
 % as being worth partial credit.  For example, a question might read thus:
-% \begin{verbatim}
+% \begin{VerbatimOut}[gobble=1]{minted.doc.out}
 %   \begin{multi}{my question}
 %     Compute $\int 4x^3\,dx$.
 %     \item* $x^4+C$
@@ -332,41 +547,51 @@
 %     \item[fraction=50] $x^4$
 %     \item $12x^2$
 %   \end{multi}
-% \end{verbatim}
+% \end{VerbatimOut}
+% \inputminted[gobble=2,frame=lines]{latex}{minted.doc.out}
 % Thus the asterisk |*| is shorthand for |fraction=100|, 
 % whereas a bare |\item| sets |fraction=0|.
 % 
-% \DescribeMacro{single}\DescribeMacro{multiple}
+% \DescribeMacro{single}
 % By default, the |multi| environment produces
-% a multiple choice question operates with only one correct answer;
+% a multiple choice question with only one correct answer;
 % this is called |single| mode, and on Moodle it appears with radio buttons.
-% It is also possible to write questions with more than one correct answer,
-% asking the user to check all correct answers.
-% To do this, use the key |multiple| or |single=false|.
-% 
+%
+% \DescribeMacro{multiple}
+% It is also possible to write questions with possibly more than one correct answer,
+% asking the user to check all correct answers. To do this, use the key |multiple|
+% or |single=false|.
 % The worth of each correct answers in |multiple| mode may be set by |fraction|,
-% but Moodle will require that all the fractions add up to at least 100.
-% If you simply designate each correct answer with |\item*|, then \textsf{moodle.sty}
-% will divide the 100\% equally among those answers.
-% For example, the following two examples produce equivalent results:
-% \begin{verbatim}
+% but Moodle asks that all the fractions add up to \emph{exactly} 100.
+% If you simply designate each correct answer with |\item*|, then \textsf{moodle}
+% will divide equally among those answers the points lefts for a sum of 100\%.
+% Items that are not given a |fraction| are considered incorrect and selecting them
+% results in negative points such that the sum of all incorrect answers is -100\%.
+% For example, the following two examples are equivalent:
+% \begin{VerbatimOut}[gobble=1]{minted.doc.out}
 %   \begin{multi}[multiple]{my question}
 %     Which numbers are prime?
+%     \item[fraction=20] 2
 %     \item* 5
+%     \item* 7
+%     \item[fraction=-10] 1 
 %     \item 6
-%     \item* 7
 %     \item 8
 %   \end{multi}
-% \end{verbatim}
-% \begin{verbatim}
+%   
 %   \begin{multi}[multiple]{my question}
 %     Which numbers are prime?
-%     \item[fraction=50] 5
-%     \item 6
-%     \item[fraction=50] 7
-%     \item 8
+%     \item[fraction=20] 2
+%     \item[fraction=40] 5
+%     \item[fraction=40] 7
+%     \item[fraction=-10] 1
+%     \item[fraction=-45] 6
+%     \item[fraction=-45] 8
 %   \end{multi}
-% \end{verbatim}
+% \end{VerbatimOut}
+% \inputminted[gobble=2,frame=lines]{latex}{minted.doc.out}
+% Note that, in this example, negative fractions are set for wrong choices. This
+% prevents students selecting all options to obtain a good grade with no merit.
 % 
 % \subsubsection{Numerical}
 %
@@ -387,8 +612,41 @@
 % \begin{quote}\footnotesize
 %   |\item[fraction=0,feedback={You forgot to antidifferentiate!}]| \meta{incorrect answer}
 % \end{quote}
+%
+% \DescribeMacro{tolerance} 
+% The |tolerance| key can be used to specify the validity of answers within some margin.
+% This key can be set at different levels: quiz, question, item.
+% For example, with the question
+% \begin{VerbatimOut}[gobble=1]{minted.doc.out}
+%   \begin{numerical}[tolerance=0.01]{my question}
+%     Approximate value of $\sqrt{2}$?
+%     \item[tolerance={1e-1}] 1.4142
+%     \item[fraction=20,feedback={twice this!}] 7.0711e-1
+%     \item[fraction=0,feedback={Wrong!}] *
+%   \end{numerical}
+% \end{VerbatimOut}
+% \inputminted[gobble=2,frame=lines]{latex}{minted.doc.out}
+% In this example,
+% \begin{itemize}
+%   \item any answer in the range $[1.4042,1.4242]$ will be validated,
+%   \item any answer in the range $[0.69711,0.71711]$ will get the specific feedback
+%         \emph{twice this!} and 20\% of points,
+%   \item any other answer is incorrect and will get the specific feedback
+%         \emph{Wrong!}.
+% \end{itemize}
+%
+% When feedback is to be given for any non-specified answer, one can add a \emph{last} answer
+% item containing the wilcard character |*| only. In this case, the |tolerance| key is irrelevant.
 % 
-% \newpage
+% Both answers and tolerance can be specified with the comma (|,|) as a decimal separator.
+% Exponent notation is accepted. After import, Moodle will recognize indifferently |0.000165|,
+% |0,000165|, |1.65E-4|, |1.65e-4|, |1,65E-4|, and |1,65e-4|.
+%
+% If the \textsf{siunitx} package is loaded, \textsf{moodle} will detect it and
+% numbers will be rendered nicely in the PDF output.
+% 
+% Units, unit-handling and multipliers are currently unsupported.
+%
 % \subsubsection{Short Answer}
 % A short answer question resembles a numerical question: the student is to fill
 % in a text box with a missing word or phrase.
@@ -403,13 +661,14 @@
 % You can make the text box appear as part of the question with the 
 % control sequence |\blank|.  For example,
 % your question might read 
-% \begin{verbatim}
+% \begin{VerbatimOut}[gobble=1]{minted.doc.out}
 %   \begin{shortanswer}{Leibniz}
 %     Newton's rival was Gottfried Wilhelm \blank.
 %     \item Leibniz
 %     \item Leibniz.
 %   \end{shortanswer}
-% \end{verbatim}
+% \end{VerbatimOut}
+% \inputminted[gobble=2,frame=lines]{latex}{minted.doc.out}
 % Note that as the blank occurred at the end of a sentence, 
 % we included two answers, 
 % lest students get the question wrong merely by
@@ -416,12 +675,26 @@
 % including or omitting a period.
 % 
 % \DescribeMacro{case sensitive}\DescribeMacro{usecase}
-% By default, Moodle ignores the distinction between upper- and lower-case letters
-% when grading a short answer question.
+% The default setting when creating a Short Answer question in Moodle
+% is to ignore the distinction between upper- and lower-case letters
+% when grading a short answer question. This default is preserved by
+% \textsf{moodle}.
 % You can make a question case-sensitive with the key |case sensitive| 
 % or its shorter synonym |usecase|.
+%
+% The wildcard character |*| can used to grab answers that match 
+% a specific pattern. For instance:
+% \begin{itemize}
+%   \item ``\emph{Sir Isaac Newton}'', ``\emph{Isaac Newton}'' and
+%         ``\emph{Newton}'' will match the pattern |*Newton|,
+%   \item ``\emph{Gaston}'' and ``\emph{Wellington}'' will match the
+%          pattern |*ton|,
+%   \item ``\emph{Isaac}'' and ``\emph{Isaac Newton}'' will match the
+%          pattern |Isaac*|,
+%   \item any non empty answer will match the pattern |*| (wildcard alone).
+% \end{itemize}
 % 
-% \subsubsection{Essay Questions}
+% \subsubsection{Essay}\label{subsubsect:essay}
 % Instructors may ask essay questions on a Moodle quiz,
 % although Moodle's software is not up to the task of grading them!
 % Instead each essay question answer must be graded manually by the
@@ -443,22 +716,23 @@
 % If the |response required| key is set, Moodle will insist that the student
 % enter something in the blank before accepting the quiz as completed.
 % 
-% \newpage
 % \DescribeMacro{response format}
 % Moodle offers five different ways for students to enter and/or upload their
 % answers to an essay question.  You may choose one of these five options:
 % \begin{description}
-%   \item[{\tt html}] An editor with the ability to format HTML responses
+%   \item[{\ttfamily html}] An editor with the ability to format HTML responses
 %         including markup for italics, boldface, etc.  This is the default.
-%   \item[{\tt file}] A file picker allowing the student to upload a file, such as
-%         a PDF or DOC file, containing the essay.
-%   \item[{\tt html+file}] The same HTML editor as above, but with the ability
-%         to upload files as well.  This permits some students to type answers
-%         directly into the web form, and others to compose their essays in
-%         another program first.
-%   \item[{\tt text}] This editor allows only for entering plain text without any markup.
-%   \item[{\tt monospaced}] This yields a plain text editor, without any markup,
-%         and with a fixed-width font.  This could be useful for entering code snippets, for example.
+%   \item[{\ttfamily file}] A file picker allowing the student to upload a 
+%         file, such as a PDF or DOC file, containing the essay.
+%   \item[{\ttfamily html+file}] The same HTML editor as above, but with the 
+%         ability to upload files as well.  This permits some students to type 
+%         answers directly into the web form, and others to compose their 
+%         essays in another program first.
+%   \item[{\ttfamily text}] This editor allows only for entering plain text 
+%         without any markup.
+%   \item[{\ttfamily monospaced}] This yields a plain text editor, without any 
+%         markup, and with a fixed-width font.  This could be useful for 
+%         entering code snippets, for example.
 % \end{description}
 % 
 % \DescribeMacro{response field lines}
@@ -473,16 +747,16 @@
 % You may also require the student to upload a certain number of attachments
 % by setting |attachments required| to |0|, |1|, |2|, or |3|.
 % 
-% \DescribeMacro{response template}
+% \DescribeMacro{template}
 % Finally, you may preload the essay question with a template that the student
-% will edit and/or type over, with the key |response template=|\marg{template}.
+% will edit and/or type over, with the key |template=|\marg{template}.
 % The \meta{template} should be enclosed in braces.
 % 
-% \subsection{Matching Questions}
+% \subsubsection{Matching}
 % 
 % A matching question offers a series of subquestions
 % and a set of possible answers from which to choose.
-% If there are $m$ questions and $n$ possible answers,
+% If there are $m$ questions and $n\geq m$ possible answers,
 % a matching question will look like this:
 % 
 % \begin{quote}
@@ -508,19 +782,18 @@
 % permute the questions and answers; by default |shuffle=true|.
 % 
 % \DescribeMacro{drag and drop}\DescribeMacro{dd}
-% Moodle has two formats for matching questions.
-% The older matching question offered a dropdown box
-% for choosing the answer to each question;
-% the newer ``drag and drop matching'' format
+% The standard matching question offered by Moodle corresponds to
+% a dropdown box for choosing the answer to each question.
+% There also exists a ``drag and drop matching'' plugin for Moodle that
 % shows all questions in one column,
 % all answers in a second column, and allows students to drag the correct
 % answer to the question using a mouse.
-% To enable drag-and-drop matching, use the key `|drag and drop|' or `|dd|' for 
-% short.  The default is |dd=false|.  If you choose the older format,
-% then due to the limitations of dropdown boxes, no \LaTeX\ or HTML code can be used
-% in the answers.
+% In this package, to enable drag-and-drop matching, use the key
+% `|drag and drop|' or `|dd|' for short.  The default is |dd=false|.
+% If you choose the standard format, then due to the limitations of
+% dropdown boxes, no \LaTeX\ or HTML code can be used in the answers.
 % 
-% \subsection{Cloze Questions}
+% \subsubsection{Cloze Questions and Subquestions}
 % 
 % A ``cloze question'' has one or more subquestions embedded within a passage of text.  
 % For example, you might ask students to fill in several missing words within
@@ -528,10 +801,10 @@
 % To encode cloze questions in \LaTeX\ using this package is easy:
 % you simply nest one or more |multi|, |shortanswer|, or |numerical| environments
 % within a |cloze| environment, as in the following example:
-% \begin{verbatim}
-%   \begin{cloze}{my cloze question} \\
+% \begin{VerbatimOut}[gobble=1]{minted.doc.out}
+%   \begin{cloze}{my cloze question}
 %     Thanks to calculus, invented by Isaac
-%     \begin{shortanswer}
+%     \begin{shortanswer}[usecase]
 %       \item Newton
 %     \end{shortanswer},
 %     we know that the derivative of $x^2$ is
@@ -542,50 +815,164 @@
 %     \end{multi}
 %     and that $\int_0^2 x^2\,dx$ equals
 %     \begin{numerical}
-%       \item[tolerance=0.0004] 2.667
+%       \item[tolerance={4e-4}] 2.667
 %     \end{numerical}.
 %     Thanks, Isaac!
 %   \end{cloze}
-% \end{verbatim}
+% \end{VerbatimOut}
+% \inputminted[gobble=2,frame=lines]{latex}{minted.doc.out}
 % Note that when used as a subquestion within a cloze question,
 % |\begin{multi}| is \emph{not} followed by name in braces;
 % the same is true for the |shortanswer| and |numerical|
 % environments.
 % 
-% \DescribeMacro{vertical}\DescribeMacro{horizontal}
-% Within a cloze question, by default a multiple choice question is implemented
-% as an inline dropdown box.  This is visually compact, but it also prevents the 
-% use of mathematical or HTML formatting.
+% \DescribeMacro{single=true}\DescribeMacro{single=false}\DescribeMacro{multiple}
+% Before Moodle version 3.5, within a cloze question, a multiple choice question
+% was necessarily of type |single|, i.e. with a single good answer. If you intend
+% to export your quiz to Moodle 3.5+, the option |multiple| can be used, when
+% multiple good answers are to be found.
+%
+% \DescribeMacro{vertical}\DescribeMacro{horizontal}\DescribeMacro{inline}
+% Within a cloze question, by default, a multiple choice question is implemented
+% as an |inline| dropdown box. This is visually compact, but it also prevents
+% the use of mathematical or HTML formatting.
 % Adding the option |vertical| displays the subquestion as a vertical column
 % of radio buttons instead; likewise the option |horizontal| creates a horizontal 
 % row of radio buttons.
+% The option |inline| is incompatible with |multiple| or |single=false|
+% (dropdown boxes don't let you pick up several answers!).
+%
+% \DescribeMacro{shuffle}
+% Starting from Moodle version 3.0, within a cloze question, the items of a
+% multiple choice question can be shuffled. Setting |shuffle=false| will
+% guarantee that the answer appear in the order they were typed; the
+% default is |shuffle=true|.
+%
+% \DescribeMacro{case sensitive}\DescribeMacro{usecase}
+% Within a cloze question, the short answer question can be made case sensitive.
+% This option, disabled by default, is selected with |case sensitive| or |usecase|.
 % 
+%\subsubsection{Description}
+% 	
+% The Moodle description type is not really a question. It is more like a label.
+% One can set a |feedback| that the student gets when reviewing the submission.
+% Tags can be set as well.
+% 
+% For descriptions, \textsf{moodle} redefines the existing |description| environment.
+%
+% The syntax for a Description question is as follows:
+% \begin{quote}
+%   |\begin{description}|\oarg{question options}\marg{question name} \\
+%   \rule{2em}{0pt}\meta{question text} \\
+%   |\end{description}|
+% \end{quote}
+%
+% \subsection{Summary of the Key Options}
+% 
+% Table~\ref{tab:key-options} summarizes the key options available at the question
+% and answer levels depending on the question type. For the essay questions,
+% please refer to section~\ref{subsubsect:essay}.
+% 
+% \begin{table}[tbp]
+% \centering
+% \caption{Options offered at the question and answer levels for each question type.}
+% \label{tab:key-options}
+% \small
+% \begin{tabular}{*{14}{l}}
+% \toprule
+% & \multicolumn{10}{l}{Question} & \multicolumn{3}{l}{Answer}\\
+% \cmidrule(lr){2-11}\cmidrule(lr){12-14}
+% Question type & \rotatebox{90}{points} & 
+% \rotatebox{90}{penalty} & \rotatebox{90}{feedback} & \rotatebox{90}{tags} & 
+% \rotatebox{90}{shuffle} & \rotatebox{90}{numbering} & \rotatebox{90}{multiple} &
+% \rotatebox{90}{usecase} & \rotatebox{90}{tolerance} &\rotatebox{90}{dd} &
+% \rotatebox{90}{fraction} & \rotatebox{90}{feedback} & 
+% \rotatebox{90}{tolerance}\\\cmidrule(lr){1-1}\cmidrule(lr){2-2}\cmidrule(lr){3-3}
+% \cmidrule(lr){4-4}\cmidrule(lr){5-5}\cmidrule(lr){6-6}\cmidrule(lr){7-7}
+% \cmidrule(lr){8-8}\cmidrule(lr){9-9}\cmidrule(lr){10-10}\cmidrule(lr){11-11}
+% \cmidrule(lr){12-12}\cmidrule(lr){13-13}\cmidrule(lr){14-14}
+% \href{https://docs.moodle.org/35/en/Multiple_Choice_question_type} 
+% {Multichoice} & $\bullet$ & $\bullet$ & $\bullet$ & $\bullet$ & 
+% $\bullet$ & $\bullet$ & $\bullet$ & & & & $\bullet$ & $\bullet$ \\
+% \href{https://docs.moodle.org/35/en/Numerical_question_type}{Numerical}
+% & $\bullet$ & $\bullet$ & $\bullet$ & $\bullet$ & & & 
+% & & $\bullet$ & & $\bullet$ & $\bullet$ & $\bullet$ \\
+% \href{https://docs.moodle.org/35/en/Short-Answer_question_type}{Short
+% Answer} & $\bullet$ & $\bullet$ & $\bullet$ & $\bullet$ & & & 
+% & $\bullet$ & & & $\bullet$ & $\bullet$ \\
+% \href{https://docs.moodle.org/35/en/Matching_question_type}{Matching}
+% & $\bullet$ & $\bullet$ & $\bullet$ & $\bullet$ & $\bullet$ & & 
+% & & & $\bullet$ & $\bullet$ & \\
+% \href{https://docs.moodle.org/35/en/True/False_question_type}
+% {True/False} & $\bullet$ & & $\bullet$ & $\bullet$ & & & 
+% & & & & & $\bullet$ \\
+% \href{https://docs.moodle.org/35/en/Description_question_type} 
+% {Description} & & & $\bullet$ & $\bullet$ & & & 
+% & & & & & \\
+% ^^A\href{https://docs.moodle.org/35/en/Essay_question_type}{Essay} & \\\hline%
+% \href{https://docs.moodle.org/35/en/Embedded_Answers_(Cloze)_question_type}{Cloze}
+% & $\bullet$ & $\bullet$ & $\bullet$ & $\bullet$ & & & 
+% & & & & & \\\cmidrule(lr){1-1}
+% \hspace{1em}Numerical & $\bullet$ & & & & & & 
+% & &$\bullet$ & & $\bullet$ & $\bullet$ & $\bullet$ \\
+% \hspace{1em}Short Answer & $\bullet$ & & & & & & 
+% & $\bullet$ & & & $\bullet$ & $\bullet$ \\
+% \hspace{1em}Multi (regular) & $\bullet$ & & & & $\bullet$ & & $\bullet$ 
+% & & & & $\bullet$ & $\bullet$ \\
+% \hspace{1em}Multi (horizontal)& $\bullet$ & & & & $\bullet$ & & $\bullet$ 
+% & & & & $\bullet$ & $\bullet$ \\
+% \hspace{1em}Multi (vertical)& $\bullet$ & & & & $\bullet$ & & 
+% & & & & $\bullet$ & $\bullet$ \\
+% \bottomrule
+% \end{tabular}
+% \end{table}
+% 
 % \section{Conversion to HTML}
 % 
 % Questions should be typed as usual for \LaTeX,
-% including |\$| to obtain dollar signs, |$|'s for math shifts,
-% |$$|'s for display math, et cetera.
+% including |\$| to obtain dollar signs, |$|'s or |\(|...|\)| for math shifts,
+% |$$|'s or |\[|...|\]| for display math, et cetera.
 % The package \textsf{moodle.sty} automatically converts
 % this \LaTeX\ code into HTML for web display.
 % 
-% The following table lists \LaTeX\ commands and environments that 
-% will be converted to HTML: 
-% \begin{center}
-%   \begin{tabular}{lll}
-%     |~| & |\#| & |\$| \\
-%     |\&| & |\\| & |\S| \\
-%     |\{| & |\}| & {\tt\catcode`\ =12\relax\catcode`\\=12\relax\ }\\
-%     |\emph| & |\textbf| & |\par| \\
-%     |\ldots| & |\dots| & |\relax| \\
-%     |\euro| & |\texteuro| \\
-%     |\begin{center}| \\
-%     |\begin{enumerate}| \\
-%     |\begin{itemize}| \\
-%     |\begin{tikzpicture}| \\
-%   \end{tabular}
-% \end{center}
-% Single and double quotation marks and the diacritical commands  |\^|, |\'|, |\`|, |\"|, |\~|, and |\H| are also handled,
-% as are the characters |\aa|, |\ae|, |\o|, |\ss|, |\l|, and their capitalizations.
+% Table~\ref{tab:html} lists \LaTeX\ macros, commands, and environments that 
+% are specifically converted to HTML.
+% \begin{table}[tbp]
+% \centering
+% \caption{Conversion of \LaTeX\ material to HTML.}
+% \label{tab:html}
+% \begin{tabular}{llll}
+% \toprule
+% \multicolumn{2}{l}{Macros} & Commands & Environnments \\
+% \cmidrule(lr){1-2}\cmidrule(lr){3-3}\cmidrule(lr){4-4}
+% |~| & |\#| &|\emph{}| & |\begin{center}|\\
+% |\$| & |\&| &|\textbf{}| & |\begin{enumerate}|\\
+% |\\| & |\par| &|\textit{}| & |\begin{itemize}|\\
+% |\&| & |\S| & |\texttt{}| & |\begin{tikzpicture}|\\
+% |\{| & |\}| & |\textsc{}| & \\
+% |\|\textvisiblespace & |\relax| & |\underline{}| &\\
+% |\,| & |\thinspace| & |\textsuperscript{}| & \\
+% |\dots| & |\ldots| & |\up{}| & \\
+% |\euro| & |\texteuro| & |\fup{}| & \\
+% |\TeX| & |\LaTeX|& |\textsubscript{}| & \\
+% |\_| & |\textbackslash| & |\url{}| & \\
+% & & |\href{}{}| & \\
+% & & |\tikz[]{}| & \\
+% & & |\includegraphics[]{}| & \\
+% & & |\verbatiminput{}| & \\
+% & & |\VerbatimInput[]{}| & \\
+% & & |\LVerbatimInput[]{}| & \\
+% & & |\BVerbatimInput[]{}| & \\
+% & & |\inputminted[]{}{}| & \\
+% \bottomrule
+% \end{tabular}
+% \end{table}
+% Single and double quotation marks, french quotation marks, inverted exclamation and
+% question marks, and the diacritical 
+% commands  |\^|, |\'|, |\`|, |\"|, |\~|, |\c|, |\H|, |\u| and |\v| are also handled,
+% as are the characters |\aa|, |\ae|, |\l|, |\oe|, |\o|, |\ss|, and their 
+% capitalizations. See Tables~\ref{tab:diacritical}, \ref{tab:ligatures}, and
+% \ref{tab:other} for more details.
 %   
 % In addition, |<| and |>| will be converted to |<| and |>| \emph{within math mode only}.
 % If they should be typed outside of math mode, they will be passed as typed to
@@ -592,30 +979,43 @@
 % the HTML, and probably interpreted by students' browsers as HTML tags
 % or other unpredicated results.
 % 
-% Be aware that \emph{\textsf{moodle.sty} does not know how to convert any 
+% Be aware that \emph{\textsf{moodle} does not know how to convert any 
 % other \TeX\ or \LaTeX\ commands to HTML.}
 % If other sequences are used, they may be passed verbatim to the XML file
 % or may cause unpredicted results.
+% \DescribeMacro{\htmlregister}The |\htmlregister| command lets you specify
+% the macros that must be expanded in the XML file. It works only when no
+% optional argument is used.
 % 
+% \DescribeMacro{\moodleregisternewcommands} 
+% When the list of macros is long, it becomes cumbersome to record them
+% individually for expansion.
+% Calling |\moodleregisternewcommands| triggers the automatic
+% expansion of macros defined subsequently using |\newcommand|,
+% |\renewcommand|, |\providecommand|, or their starred variants.
+% Again, this works only if the macros are defined \emph{without} optional
+% argument.
+% 
 % If you think of another \LaTeX\ command that should be changed to an HTML equivalent, 
-% please contact the author at \url{anders.hendrickson at snc.edu}
+% please contact the maintainer at \url{guerquin-kern AT crans.org}
 % so that it may be added to a future revision of the package.
 % 
 % \section{Graphics}
-% The \textsf{moodle.sty} package can handle two kinds of graphics seamlessly.
+% The \textsf{moodle} package can handle two kinds of graphics seamlessly.
 % External graphics files may be included with the |\includegraphics| command
-% from the |graphicx| package,
-% and graphics may be generated internally using \TikZ.  In either case, the 
-% graphics will be embedded in base-64 encoding directly within
+% from the |graphicx| package, and graphics may be generated internally using \TikZ. 
+% In either case, the graphics will be embedded in base-64 encoding directly within
 % the Moodle~XML produced.  This prevents the hassle of managing separate
 % graphics files on the Moodle server, as Moodle will store the picture 
 % within the question in the question bank.
 % 
+% \subsection{Default \texttt{includegraphics}}
 % \DescribeMacro{\includegraphics}\DescribeMacro{height}\DescribeMacro{width}
 % When using |\includegraphics|, the only options currently supported 
 % are |height| and |width|.  Attempts to use other |\includegraphics| options,
 % such as |scale| or |angle|, will affect the PDF but not the XML output.
-% The dimensions set by |height| and |width| are \TeX\ dimensions such as |4in| or |2.3cm|.
+% The dimensions set by |height| and |width| are \TeX\ dimensions such as \texttt{4\,in}
+% or \texttt{2.3\,cm}.
 % In order to prepare the image for web viewing, this package converts those 
 % dimensions to pixels using a default of 
 % 103 pixels per inch.\footnote{This
@@ -627,11 +1027,50 @@
 % That value may be changed by setting the |ppi| key (e.g., |ppi=72|); 
 % this is probably best done for the entire document with a |\moodleset| command,
 % rather than image-by-image.
-% 
-% The mechanism used is somewhat fragile and relies upon one \TikZ\ library and three free external programs.
+% \DescribeMacro{\graphicspath}
+% You can use |\graphicspath{{|\emph{path}|}}| to specify a directory where the
+% pictures to be included are located.
+%
+% A special rule was added for the inclusion of GIF pictures (|.gif| extension).
+% These files are passed as-is to the XML, preserving potential animations.
+% However, as pdf\TeX\ engines do not support the GIF format, the picture is
+% passed to the PDF output after a conversion to the PNG format. When the GIF
+% file is animated, only its first frame is passed to the PDF.
+%
+%^^A \DescribeMacro{\DeclareGraphicsAlien} Users may declare other graphic
+%^^A formats with the command |\DeclareGraphicsAlien|\marg{alien extension}
+%^^A \marg{native extension}\marg{command line for conversion}.
+%
+% \subsection{\TikZ\ Pictures}
+% When \TikZ\ is loaded and used to define pictures, \textsf{moodle} invokes
+% the |external| \TikZ\ library, so that each |tikzpicture| environment is compiled
+% to a freestanding PDF file.
+%
+% \subsection{Package Option \texttt{tikz}}\label{subsec:tikz}
+% \DescribeMacro{tikz}
+% The \textsf{moodle} package admits a \texttt{tikz} option which has the following effects:
+% \begin{itemize}
+% \item the package \texttt{tikz} is loaded.
+% \item \texttt{includegraphics} is embedded in a \TikZ\ picture. Consequences are that
+%   \begin{itemize}
+%     \item the pictures encoded in the XML file are resampled. This prevents encoding
+%           images at a higher resolution than rendered by Moodle.
+%     \item the full set of \texttt{includegraphics} options is accessible,
+% e.g.~|scale=.5|, |angle=90|, or |width=.2\textwidth|.
+%   \end{itemize}
+% \item \DescribeMacro{\embedaspict} a macro |\embedaspict{...}| is provided for the
+% inclusion of inline \LaTeX\ material as images. This can serve as a workaround to
+% overcome limitations of this package---like the conversion of tabulars to HTML---
+% or limitations of Moodle itself.
+% For the definition of this macro, the package \texttt{varwidth} is loaded.
+% \item optimizations of the \TikZ-external library are disabled. Compilation might get
+% sensibly slower.
+% \end{itemize}
+%
+% \subsection{External Tools}
+% The mechanisms used for handling graphics are somewhat fragile and rely upon
+% three free external programs.
 % \begin{enumerate}
-%   \item \textsf{moodle.sty} invokes |\usetikzlibrary{external}|,
-%         so that each |tikzpicture| environment is compiled to a freestanding PDF file.
 %   \item GhostScript (\url{www.ghostscript.com}) is used to convert the PDF output
 %         from \TikZ\ into a PNG raster graphics file.
 %         The default command line is presumed to be |gswin64c.exe| 
@@ -639,61 +1078,445 @@
 %         or |gs| (if |\ifwindows| returns false).
 %         If your system requires a different command line to invoke Ghostscript,
 %         \DescribeMacro{\ghostscriptcommand}
-%         you may change it by invoking |\ghostscriptcommand|\marg{executable filename}.
-%   \item When external graphics files such as JPG or GIF are included,
+%         you may change it by invoking:
+%            \begin{quote}
+%             |\ghostscriptcommand|\marg{executable filename}
+%            \end{quote}
+%   \item When external graphics files such as PDF are included,
 %         the open-source ImageMagick software (\url{www.imagemagick.org})
 %         converts each file to PNG format.
 %         The command line for ImageMagick is the nondescript word |convert|,
 %         \DescribeMacro{\imagemagickcommand}
 %         but may be changed by invoking |\imagemagickcommand|\marg{executable filename}.
-%   \item Finally, the OpenSSL toolkit (\url{www.openssl.org}) is used to base64-encode 
-%         the PNG file so that it can be included directly in the text of the XML file.
-%         The command line is presumed to be |openssl|, but can be changed with
-%         \DescribeMacro{\opensslcommand}
-%         |\opensslcommand|\marg{executable filename}.
+%   \item OptiPNG (\url{http://optipng.sourceforge.net/}) is used to optimize the PNG images.
+%         The command line is presumed to be |optipng|, but can be changed with
+%         \DescribeMacro{\optipngcommand} |\optipngcommand|\marg{executable filename}.
 % \end{enumerate}
 % 
 % Please note the following vital points to make the graphics handling work:
 % \begin{itemize}
 %   \item As of now, graphics are only supported when compiling directly to a PDF
-%         with |pdflatex|.  Including PS graphics or using \TikZ\ with the DVI$\to$PS workflow is not
+%         with |pdflatex|. Including PS graphics or using \TikZ\ with the DVI$\to$PS workflow is not
 %         yet supported.
-%   \item Filenames should not contains spaces or special characters like |_| or |\|.
-%   \item You must have Ghostscript, ImageMagick, and OpenSSL installed on your system
-%         to fully use the graphics-handling capabilities of \textsf{moodle.sty}.
+%^^A   \item Filenames should not contains spaces or, under windows, special characters like |_| or |\|.
+%   \item You must have Ghostscript and ImageMagick installed on your system
+%         to fully use the graphics-handling capabilities of \textsf{moodle}.
+%   \item If OptiPNG is not installed, the corresponding system calls will fail with otherwise no
+%         impact on the compilation process: PNG files are passed unoptimized to the XML output.
 %   \item \LaTeX\ must be able to call system commands; that is, |\write18| must be enabled.
 %         For Mik\TeX, this means adding |--enable-write18| to the command line of |pdflatex|;
 %         for \TeX Live, this means adding |--shell-escape=true|.
+%   \item Due to security issues with old versions of Ghostcript, some systems default to a
+%         policy that prevents the conversion of PDF and PS to PNG. Assuming that, as a user of
+%         \textsf{moodle} which requires shell escape capabilities, you either use a sandboxed
+%         environment or trust the files handled at the system-level, you may want to disable this
+%         over-zelous security policy. For example,
+%         \href{https://stackoverflow.com/a/52661288/14608059}{see this}.
+%   \item Users of the |circuitikz| package must enclose their circuits' \TikZ\ code in the
+%         |tikzpicture| environment instead of |circuitikz|. That is required,
+%         as of \TikZ\ 2.1, by the |external| library.
 % \end{itemize}
+%
+% \subsection{Package Option \texttt{svg}}\label{subsec:svg}
+%
+% \paragraph{Important Notice} \emph{The \texttt{svg} option is an experimental feature
+% introduced in \textsf{moodle} v0.8. It has been tested exclusively under Linux, with
+% TeXLive 2020, Inkscape v1.0.1 and Scour 0.38.2.}
 % 
-% \newpage
+% \DescribeMacro{svg} The \textsf{moodle} package admits an experimental \texttt{svg}
+% option which has the following effects:
+% \begin{itemize}
+% \item |\includegraphics| can be used to import SVG graphic files directly
+% (extension |.svg| or |.SVG|). In this case, the SVG file is passed as-is to the
+% XML output and is converted using \href{https://inkscape.org/}
+% {Inkscape} (must be installed) for inclusion in the PDF output.
+% \item the graphic files in PDF format are converted to the SVG format using
+% \href{https://inkscape.org/}{Inkscape} (must be installed), rather than beeing
+% rasterized. Before inclusion to the XML output, the SVG file is optimized using
+% the \href{https://github.com/scour-project/scour}{Scour} utility. This
+% optimization step is optional in the sense that, if the Scour call fails,
+% the unoptimized SVG file will be passed to the XML output.
+% Two processes benefit from this PDF$\to$SVG conversion:
+%   \begin{itemize}
+%     \item inclusion of PDF graphics with |\includegraphics|, and
+%     \item Tikz pictures that are externalized.
+%   \end{itemize}
+% \end{itemize}
+%
+% \DescribeMacro{\PDFtoSVGcommand}\DescribeMacro{\SVGtoPDFcommand}
+% \DescribeMacro{\optiSVGcommand} The call of external tools can be changed using
+% the macros |\PDFtoSVGcommand| \marg{\dots}, |\SVGtoPDFcommand|\marg{\dots} and
+% |\optiSVGcommand|\marg{\dots}.
+%
+% \section{Verbatim Code}
+% Because, for HTML translation, \textsf{moodle} parses the body of questions, the use of 
+% verbatim code results in compilation errors. This is why the use of |\verb|,
+% |\begin{verbatim}| and other standard utilities is not supported.
+%
+% However, using the following three utilities, verbatim code can be imported from an external file:
+% \begin{enumerate}
+%   \item \DescribeMacro{\verbatiminput}|\verbatiminput|\marg{filename} from the \textsf{verbatim}
+%         package inserts verbatim code in both the PDF and the XML for moodle, without fancy additions.
+%   \item \DescribeMacro{\VerbatimInput}The macro |\VerbatimInput|\marg{options}\marg{filename} from
+%         \textsf{fancyvrb} or \textsf{fvextra} does more, with several options and settings offered
+%         (see below).
+%         The variants \DescribeMacro{\BVerbatimInput}|\VBerbatimInput| and
+%         \DescribeMacro{\LVerbatimInput}|\LVerbatimInput| are also supported, with identical
+%         effect on the XML output.
+%         The variants with a star are unsupported and result in errors when used.
+%   \item \DescribeMacro{\inputminted}On top of that |\inputminted|\oarg{options}\marg{lang}
+%         \marg{filename}from the \textsf{minted} package offers syntaxic highlighting tailored to the
+%         specified language.
+% \end{enumerate}
+% The \textsf{moodle} package handles these three commands to pass the code in the output XML.
+%
+% With |\VerbatimInput| and |\inputminted|, the options that are taken care of for XML
+% generation are listed in Table~\ref{tab:verbatim-options}. Using |\fvset|\marg{key=value,...},
+% options can be set globally. Equivalently, with \textsf{minted},
+% |\setminted|\oarg{lang}\marg{key=value,...} is available.
+%
+% \begin{table}[tbp]
+% \centering
+% \begin{threeparttable}[b]
+% \caption{Options and corresponding values considered for XML generation of verbatim material
+% with \texttt{VerbatimInput} and \texttt{inputminted}.}
+% \label{tab:verbatim-options}
+% \begin{tabular}{ll}
+% \toprule
+% Option keys & Possible values\\\cmidrule(lr){1-1}\cmidrule(lr){2-2}
+% ^^A\texttt{commentchar} & \meta{character}\\
+% \texttt{gobble} & \meta{integer}\\
+% \texttt{autogobble}\tnote{1} & \texttt{true} or \texttt{false}\\
+% \texttt{tabsize} & \meta{integer}\\
+% \texttt{numbers} & \texttt{none}, \texttt{left}, \texttt{right}, or \texttt{both}\tnote{2}\\
+% \texttt{firstnumber} & \texttt{auto}, \texttt{last}, or \meta{integer}\\
+% \texttt{firstline} & \meta{integer}\\
+% \texttt{lastline} & \meta{integer}\\
+% \texttt{numberblanklines} & \texttt{true} or \texttt{false}\\
+% \texttt{highlightlines}\tnote{2} & \marg{coma-separated list of integers or ranges}\\
+% \texttt{style}\tnote{1} & \meta{string}\\
+% \bottomrule
+% \end{tabular}
+%\begin{tablenotes}
+%\item[1] \texttt{autogobble}, \texttt{numbers=both}, and \texttt{style} are offered only by \textsf{minted}.
+%\item[2] line highlighting is offered only with \textsf{fvextra} or \textsf{minted} loaded.
+%\end{tablenotes}
+%\end{threeparttable}
+%\end{table}
+%
+% In order to define the verbatim code from the \LaTeX\ document itself, it is still possible
+% to use, outside the scope of the \textsf{moodle} questions, the environments |filecontents*|  (from the
+% \textsf{filecontents} package or \LaTeX\ kernel itself since 2019) or |VerbatimOut|
+% (from the \textsf{fancyvrb} and \textsf{fvextra} packages).
+% 
+% When code decorated with left-side line numbers is placed in question items, the output PDF could
+% show a collision between numbers of the item and the first line. To avoid this, |\LVerbatimInput| or
+% |\BVerbatimInput| can be used. Instead, when \textsf{minted} is used, the ``left-right'' mode can be
+% enforced with the \LaTeX\ command:
+% \begin{quote}
+%   |\RecustomVerbatimEnvironment{Verbatim}{LVerbatim}{}|
+%  \end{quote}
+%
+% When using utilies from \textsf{fancyvrb}, \textsf{fvextra}, or \textsf{minted}, \textsf{moodle} sets
+% framing options for the display of code in the output PDF:
+% \begin{quote}
+%   |\fvset{frame=lines,label={[Beginning of code]End of code},|\\
+%   |       framesep=3mm,numbersep=9pt}|
+% \end{quote}
+% These settings can be overidden using |\fvset| after the preamble.
+%
+% \section{Calculated Questions}
+% Moodle's calculated questions are not supported by this package.
+% 
+% However, as \href{https://github.com/avohns/python-latex-moodle-quiz}{demonstrated by A.
+% Vohns}, an advanced scripting language may be used to generate a series of questions sharing
+% the same prototype.
+% 
+% We suggest to apply a specific tag to these questions. After import in Moodle, when creating
+% a quizz, this tag can be selected to narrow down a random selection of question.
+% This would mimic the behavior of calculated questions while bringing the flexibility of your
+% favorite scripting language.
+% 
+% Here are two examples inspired from the work of A. Wohns. The first one relies on the
+% native Lua capabilities of \LuaLaTeX.
+% \begin{VerbatimOut}[gobble=1]{minted.doc.out}
+%   \begin{quiz}[tags={calculated}]{Example Quiz}
+%   \directlua{
+% \end{VerbatimOut}
+% \inputminted[gobble=2,frame=topline]{latex}{minted.doc.out}
+% \begin{VerbatimOut}[gobble=1]{minted.doc.out}
+%   function clozenum_print(pair,op,result)
+%     tex.print("\\begin{numerical}$"..pair[1].." "..op.." "..pair[2].." 
+%     =$".."\\item ",result,"\\end{numerical}")
+%   end
+%   function cloze_print(pair,points)
+%     tex.print("\\begin{cloze}[points="..points.."]{Arithmetic Quiz 
+%     ("..pair[1]..", "..pair[2]..")}Solve the following tasks!\\\\")
+%     clozenum_print(pair,"+",pair[1]+pair[2])
+%     clozenum_print(pair,"-",pair[1]-pair[2])
+%     clozenum_print(pair,"*",pair[1]*pair[2])
+%     if pair[1]/pair[2]==math.floor(pair[1]/pair[2]) then
+%       clozenum_print(pair,":",math.floor(pair[1]/pair[2]))
+%     end
+%     tex.print("\\end{cloze}")
+%   end
+%   for x = 2,4 do
+%     for y = 2,4 do
+%       if x>y then
+%         if x/y==math.floor(x/y) then points=4 else points=3 end
+%         cloze_print({x,y},points)
+%       end
+%     end
+%   end
+% \end{VerbatimOut}
+% \inputminted[]{lua}{minted.doc.out}
+% \begin{VerbatimOut}[gobble=1]{minted.doc.out}
+%   }
+%   \end{quiz}
+% \end{VerbatimOut}
+% \inputminted[gobble=2,frame=bottomline]{latex}{minted.doc.out}
+% The second example makes use of the \textsf{python} package (|\usepackage{python}|).
+% \begin{VerbatimOut}[gobble=1]{minted.doc.out}
+%   \begin{quiz}[tags={calculated}]{Example Quiz}
+%   \begin{python}
+% \end{VerbatimOut}
+% \inputminted[gobble=2,frame=topline]{latex}{minted.doc.out}
+% \begin{VerbatimOut}[gobble=1]{minted.doc.out}
+%   def clozenum_print(pair,op,result):
+%     print(rf"""\begin{{numerical}}
+%   ${pair[0]} {op} {pair[1]} =$\item {result} 
+%   \end{{numerical}}""")
+%   def cloze_print(pair,points):
+%     print(rf"""\begin{{cloze}}[points={points}]{{Arithmetic Quiz 
+%     {(pair[0],pair[1])}}}Solve the following tasks!\\""")
+%     clozenum_print([x,y],"+",x+y)
+%     clozenum_print([x,y],"-",x-y)
+%     clozenum_print([x,y],"*",x*y)
+%     if pair[0]/pair[1] == pair[0]//pair[1]:
+%       clozenum_print([x,y],":",x//y)
+%     print("\end{cloze}")
+%   for x in range(2,5):
+%     for y in range(2,5):
+%       if x > y:
+%         if x/y == x//y:
+%           points=4
+%         else:
+%           points=3  
+%         cloze_print([x,y],points)
+% \end{VerbatimOut}
+% \inputminted[]{python}{minted.doc.out}
+% \begin{VerbatimOut}[gobble=1]{minted.doc.out}
+%   \end{python}
+%   \end{quiz}
+% \end{VerbatimOut}
+% \inputminted[gobble=2,frame=bottomline]{latex}{minted.doc.out}
+% These two codes yield the same XML content.
+% 
 % \section{Known Limitations and Call for Bug Reports}
-% Some features of Moodle quizzes have not yet been implemented in \textsf{moodle.sty}.
+% Table~\ref{tab:support-limitations} lists some different features supported, limitations, and
+% bugs.
+%
+%\begin{table}[tbp]
+%\centering
+%\begin{threeparttable}[b]
+%\caption{Content enrichment (pictures, equations) support after XML import in Moodle v3.5.7,
+% depending on the question type.}
+%\label{tab:support-limitations}
+%\begin{tabular}{lccc}
+% \toprule
+% & \multicolumn{3}{l}{XML rendering in\dots}\\\cmidrule(lr){2-4}
+%Question type & Question & Answer & Feedback\\\cmidrule(lr){1-1}\cmidrule(lr){2-2}
+%\cmidrule(lr){3-3}\cmidrule(lr){4-4}
+% \href{https://docs.moodle.org/35/en/Multiple_Choice_question_type}{Multichoice}
+%& yes & yes & yes \\
+% \href{https://docs.moodle.org/35/en/Numerical_question_type}{Numerical}
+%& yes & no\tnote{1} & yes \\
+% \href{https://docs.moodle.org/35/en/Short-Answer_question_type}{Short Answer}
+% & yes & no\tnote{1} & yes \\
+% Matching (\href{https://docs.moodle.org/35/en/Matching_question_type}{std})
+%& yes & no\tnote{2} & no\tnote{3} \\
+% Matching (\href{https://docs.moodle.org/35/en/Drag_and_drop_matching_question_type}{dd})
+% & yes & yes\tnote{4} & no\tnote{3} \\
+% \href{https://docs.moodle.org/35/en/Essay_question_type}{Essay}
+%& yes & yes\tnote{5,6} & yes\tnote{5} \\
+% \href{https://docs.moodle.org/35/en/True/False_question_type}{True/False}
+%& yes & no & yes \\
+% \href{https://docs.moodle.org/35/en/Description_question_type}{Description}
+%& yes & $\varnothing$ & yes \\
+%\href{https://docs.moodle.org/35/en/Embedded_Answers_(Cloze)_question_type}{Cloze} &
+%yes & $\varnothing$& $\varnothing$ \\\cmidrule(lr){1-1}
+%\hspace{1em}Numerical & yes & no\tnote{1} & yes \\
+%\hspace{1em}Short Answer & yes & no\tnote{1} & yes\tnote{7} \\
+%\hspace{1em}Multi (regular) & yes & no\tnote{2} & yes\tnote{7} \\
+%\hspace{1em}Multi (horizontal) & yes & yes & yes \\
+%\hspace{1em}Multi (vertical) & yes & yes & yes \\\bottomrule
+%\end{tabular}
+%\begin{tablenotes}
+%\item[1] Moodle prompts the student for an answer and then compares it to the 
+%solutions provided. This is text-only.
+%\item[2] Moodle uses a dropdown list to let one choose among the possible 
+%answers. This forbids either picture inclusion and \LaTeX\ rendering.
+%\item[3] Not supported by Moodle (in this context, answer-specific feedback 
+%represents lots of possible combinations).
+%\item[4] The drag-and-drop-matching plugin seems broken before version 1.6 
+%20190409. Moodle's XML import fails with a \textsf{dmlwriteexception} when 
+%the field content exceeds few hundreds characters. This prevents the inclusion 
+%of most base64 images and maybe some complicated equations.
+%\item[5] For this question type and in the context of XML generation, the 
+%Answer column represents the ``template" while the Feedback column represents 
+%the ``notes for the grader". Obviously, the grading process is not automatic 
+%and there is no answer-specific feedback.
+%\item[6] Picture and \LaTeX\ rendering could be done, but only after 
+%submission and only if the keyval ``response format" is set to ``html".
+%\item[7] Moodle only reveals the feedback when hovering the checkmark or X 
+%mark with the mouse.
+%\end{tablenotes}
+%\end{threeparttable}
+%\end{table}
+%
+% Tables~\ref{tab:diacritical}, \ref{tab:ligatures}, and \ref{tab:other} describe the current
+% support for some special characters, accents and other diacritical marks.
+%
+%\begin{table}[tbp]
+% \centering
+% \caption{Support for diacritical marks 
+% in a UTF8-coded \TeX~document compiled with (pdf)\LaTeX\ (packages 
+% \texttt{inputenc} with option \texttt{utf8} and \texttt{fontenc} with option \texttt{T1}),
+% \LuaLaTeX\ or \XeLaTeX\ (package \texttt{fontspec}).}
+% \label{tab:diacritical}
+% \begin{threeparttable}[t]
+% \begin{tabular}{*{6}{l}}
+% \toprule
+% \multicolumn{4}{l}{Input type} & \multicolumn{2}{l}{Engine support}\\
+% \cmidrule(lr){1-4}\cmidrule(lr){5-6}
+% \multicolumn{2}{l}{Unicode} & \multicolumn{2}{l}{\LaTeX} & \XeLaTeX\ or \LuaLaTeX & (pdf)\LaTeX \\
+% \cmidrule(lr){1-2}\cmidrule(lr){3-4}\cmidrule(lr){5-5}\cmidrule(lr){6-6}
+% \aa & \AA & \verb|\aa| & \verb|\AA| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \`a & \`A & \verb|\`a| & \verb|\`A| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \^a & \^A & \verb|\^a| & \verb|\^A| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \~a & \~A & \verb|\~a| & \verb|\~A| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \'e & \'E & \verb|\'e| & \verb|\'E| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \`e & \`E & \verb|\`e| & \verb|\`E| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \"e & \"E & \verb|\"e| & \verb|\"E| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \^e & \^E & \verb|\^e| & \verb|\^E| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \^i & \^I & \verb|\^i| & \verb|\^I| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \"i & \"I & \verb|\"i| & \verb|\"I| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \~n & \~N & \verb|\~n| & \verb|\~N| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \~o & \~O & \verb|\~o| & \verb|\~O| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \"o & \"O & \verb|\"o| & \verb|\"O| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \^o & \^O & \verb|\^o| & \verb|\^O| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \`u & \`U & \verb|\`u| & \verb|\`U| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \"u & \"U & \verb|\"u| & \verb|\"U| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \^u & \^U & \verb|\^u| & \verb|\^U| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \c{c} & \c{C} & \verb|\c{c}| & \verb|\c{C}| & Unicode and \LaTeX & Unicode and \LaTeX \\
+% \c{s} & \c{S} & \verb|\c{s}| & \verb|\c{S}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \c{t} & \c{T} & \verb|\c{t}| & \verb|\c{T}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \H{o} & \H{O} & \verb|\H{o}| & \verb|\H{O}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \H{u} & \H{U} & \verb|\H{u}| & \verb|\H{U}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \"y & \"Y & \verb|\"y| & \verb|\"Y| & Unicode and \LaTeX & \LaTeX only\\
+% \u{a} & \u{A} & \verb|\u{a}| & \verb|\u{A}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \u{e} & \u{E} & \verb|\u{e}| & \verb|\u{E}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \u{g} & \u{G} & \verb|\u{g}| & \verb|\u{G}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \u{\i} & \u{I} & \verb|\u{\i}| & \verb|\u{I}| & Unicode and \LaTeX & \LaTeX\ only\tnote{1}\\
+% \u{o} & \u{O} & \verb|\u{o}| & \verb|\u{O}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \v{c} & \v{C} & \verb|\v{c}| & \verb|\v{C}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \v{d} & \v{D} & \verb|\v{d}| & \verb|\v{D}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \v{e} & \v{E} & \verb|\v{e}| & \verb|\v{E}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \v{l} & \v{L} & \verb|\v{l}| & \verb|\v{L}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \v{n} & \v{N} & \verb|\v{n}| & \verb|\v{N}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \v{r} & \v{R} & \verb|\v{r}| & \verb|\v{R}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \v{s} & \v{S} & \verb|\v{s}| & \verb|\v{S}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \v{t} & \v{T} & \verb|\v{t}| & \verb|\v{T}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \v{z} & \v{Z} & \verb|\v{z}| & \verb|\v{Z}| & Unicode and \LaTeX & \LaTeX\ only\\
+% \bottomrule
+% \end{tabular}
+% \begin{tablenotes}
+%   \item[1] \XeLaTeX\ renders correctly |\u{i}|, that is, without a superscript dot.
+%            Instead, with (pdf)\LaTeX\ the rendering of |\u{i}| is flawed by the
+%            superposition of the superscript dot and the breve diacritical mark.
+%            Both engines render |\u{\i}| as expected.
+% \end{tablenotes}
+% \end{threeparttable}
+% \end{table}
+%
+%\begin{table}[tbp]
+% \centering
+% \begin{threeparttable}[t]
+% \caption{Support for ligatures in a UTF8-coded \TeX~document compiled with (pdf)\LaTeX\ (packages 
+% \texttt{inputenc} with option \texttt{utf8}, \texttt{fontenc} with option \texttt{T1}),
+% \LuaLaTeX\ or \XeLaTeX\ (package \texttt{fontspec}).}
+% \label{tab:ligatures}
+% \begin{tabular}{llllll}
+% \toprule
+% \multicolumn{4}{l}{Input type} & \multicolumn{2}{l}{Engine support}\\
+% \cmidrule(lr){1-4}\cmidrule(lr){5-6}
+% \multicolumn{2}{l}{Unicode} & \multicolumn{2}{l}{\LaTeX} & \XeLaTeX \ or \LuaLaTeX& (pdf)\LaTeX \\
+% \cmidrule(lr){1-2}\cmidrule(lr){3-4}\cmidrule(lr){5-6}\cmidrule(lr){6-6}
+% \ae & \AE & \verb|\ae| & \verb|\AE| & Unicode and \LaTeX & \LaTeX\ only\\
+% \oe & \OE & \verb|\oe| & \verb|\OE| & Unicode and \LaTeX & \LaTeX\ only\\
+% \ss & \SS & \verb|\ss| & \verb|\SS| & Unicode and \LaTeX\tnote{1} & \LaTeX\ only\tnote{2}\\
+% \bottomrule
+% \end{tabular}
+% \begin{tablenotes}[b]
+%   \item[1] the Libertine font, used in this documentation and available for instance via the
+%            package |libertine|, defines the glyph \SS. Most fonts do not define this glyph.
+%   \item[2] \LaTeX\ defines the \verb|\SS| macro but (pdf)\LaTeX\ renders it as a doubled capital S.
+% \end{tablenotes}
+% \end{threeparttable}
+% \end{table}
+%
+%\begin{table}[tbp]
+% \centering
+% \begin{threeparttable}[b]
+% \caption{Support for other glyphs and punctuation marks in a UTF8-coded \TeX~document compiled
+% with (pdf)\LaTeX\ (packages \texttt{inputenc} with option \texttt{utf8}, \texttt{fontenc} with
+% option \texttt{T1}), \LuaLaTeX\ or \XeLaTeX\ (package \texttt{fontspec}).}
+% \label{tab:other}
+% \begin{tabular}{llllll}
+% \toprule
+% \multicolumn{4}{l}{Input type} & \multicolumn{2}{l}{Engine support}\\
+% \cmidrule(lr){1-4}\cmidrule(lr){5-6}
+% \multicolumn{2}{l}{Unicode} & \multicolumn{2}{l}{\LaTeX} & \XeLaTeX\ or \LuaLaTeX & (pdf)\LaTeX \\
+% \cmidrule(lr){1-2}\cmidrule(lr){3-4}\cmidrule(lr){5-5}\cmidrule(lr){6-6}
+% \l & \L & \verb|\l| & \verb|\L| & Unicode and \LaTeX & \LaTeX\ only\\
+% \o & \O & \verb|\o| & \verb|\O| & Unicode and \LaTeX & \LaTeX\ only\\
+% « & & \verb|\guillemotleft|\tnote{1} & & Unicode and \LaTeX & \LaTeX\ only\\
+% » & & \verb|\guillemotright|\tnote{1} & & Unicode and \LaTeX & \LaTeX\ only\\
+% ¿ & & \verb|\textquestiondown| & & Unicode and \LaTeX & \LaTeX\ only\\
+% ¡ &  & \verb|\textexclamdown| & & Unicode and \LaTeX & \LaTeX\ only\\
+% \bottomrule
+% \end{tabular}
+% \begin{tablenotes}
+%   \item[1] the package |babel| loaded with option |french| defines |\og| and |\fg| for
+%            the same symbols. These are also supported by \textsf{moodle}.
+% \end{tablenotes}
+% \end{threeparttable}
+% \end{table}
+% Some features of Moodle quizzes have not yet been implemented in \textsf{moodle}.
 % Here is a non-exhaustive list.
 % \begin{itemize}
 %   \item Moodle's feature of designating feedback for correct, 
 %         partially correct, and incorrect answers.
-%   \item Calculated questions; that is, automatically generated numerical questions 
-%         using randomly chosen numbers.
+%^^A   \item Calculated questions; that is, automatically generated numerical questions 
+%^^A         using randomly chosen numbers.
 %   \item Hints
-%   \item Keywords
-%   \item So-called ``description'' questions.
-%   \item Shuffled answers in multiple choice cloze subquestions.
+%   \item Multiple keywords (tags) for questions
 % \end{itemize}
-% I have used Version 0.5 for one semester's teaching,
-% but if other users adopt this package, I fully expect them to find bugs.
-% \emph{Please} send all bugs you find to \url{anders.hendrickson at snc.edu},
-% so that I can fix them for subsequent versions.
+% The authors have used this package together with a limited number of colleagues
+% for a few semesters of teaching. If other users adopt this package, we fully expect them
+% to find bugs. \emph{Please} send all bugs you find to \url{guerquin-kern at crans.org},
+% so that we can fix them for subsequent versions.
 % 
 % \section{Compatibility}
-% This package has been written for and tested with the implementation of 
+% This package has been originally written for and tested with the implementation of 
 % Moodle 2.9 run by Moodlerooms for St.~Norbert College in January 2016.
-% Future versions of this package will probably include some support for
-% specifying your version of Moodle in the |.tex| file to help ensure compatability.
+% Since then, it has been successfully combined with Moodle 3.5.
+% Future versions of this package might include some support for
+% specifying your version of Moodle in the |.tex| file to help ensure compatibility.
 % 
 % As the ultimate purpose of this package is the generation of XML files,
-% future versions of \textsf{moodle.sty} will attempt to maintain backwards 
-% compatability with earlier versions of regarding the XML output, apart from
+% future versions of \textsf{moodle} will attempt to maintain backwards 
+% compatability with earlier versions regarding the XML output, apart from
 % bug fixes.  
 % Backwards compatibility of the PDF output is not yet guaranteed, however,
 % in case the author or users discover better ways for the PDF to display 
@@ -700,7 +1523,7 @@
 % the underlying XML data to be proofread.
 % 
 % In other words, compiling your current |.tex| file with a future version 
-% of \textsf{moodle.sty} should produce the same XML file it does now 
+% of \textsf{moodle} should produce the same XML file it does now 
 % (apart from bug fixes),
 % but it might produce a more informative, and hence different,
 % PDF output.
@@ -707,7 +1530,7 @@
 % 
 % 
 % \section{Unrelated Tip: Quality of Moodle \TeX\ Images}
-% This has nothing to do with |moodle.sty|, but is a Frequently Asked Question
+% This has nothing to do with \textsf{moodle}, but is a Frequently Asked Question
 % in is own right.
 % On some servers, at least, Moodle's default ``\TeX\ Filter'' for 
 % displaying mathematical notation is of abysmally poor quality, rending mathematics
@@ -716,6 +1539,119 @@
 % but turn ``MathJax'' \emph{on}.  This forces \TeX\ code to be rendered by MathJax
 % instead of Moodle, producing much higher-quality results.
 % 
+% ^^A\clearpage
+% \changes{v0.5}{2016/01/05}{Initial version}
+% \changes{v0.6}{2019/02/18}{Bux-fixing release}
+% \changes{v0.7}{2020/07/09}{Feature extensions}
+% \changes{v0.8}{2021/01/04}{Bug fixes and feature extensions}
+% \begin{changelog}[title={Version History},author={Matthieu Guerquin-Kern}]
+%   \begin{version}[version=0.8,date=2021-01-04]
+%     \added
+%       \item Support for inclusion of GIF pictures.
+%       \item Added package option |svg| to avoid the rasterization of vector graphics.
+%       \item New macro |\setsubcategory| to define subcategories, reflected in PDF and XML.
+%       \item Package option |handout| for sharing PDF with students.
+%       \item Extensions can be omitted when including pictures.
+%       \item Description question type.
+%       \item \LuaLaTeX\ is now supported (and recommended for UTF8-coded sources).
+%       \item Examples of ways to reproduce the behavior of calculated questions.
+%       \item Command to trigger the automatic recording of new commands.
+%       \item Mechanism to match |fraction| key to values accepted by Moodle.
+%       \item A |fractiontol| key to control the tolerance in this mechanism.
+%       \item Support for inverted punctuation marks |¿| and |¡|.
+%       \item Support for |\_| and |\textbackslash|.
+%       \item Support for the wildcard character as an answer in numerical questions.
+%     \changed
+%       \item Template of Essay questions is now shown in PDF.
+%       \item The macro |\setcategory| is reflected by a new section in PDF.
+%       \item In matching questions, warnings are raised if the number of items is insufficient.
+%       \item Improved display of matching questions in PDF.
+%       \item The package \textsf{iftex} is now required.
+%       \item An error is thrown when |fraction| is set to an invalid value.
+%       \item In numerical questions, the tolerance can be set in exponent form.
+%       \item Nicer PDF rendering of numbers in numerical questions if \textsf{siunitx} is loaded.
+%       \item Included PNG and JPEG files are now directly converted to base64.
+%     \fixed
+%       \item TeX's inline math (|$...$|) can now contain escaped dollar signs (|\$|).
+%       \item Closing braces escaped in cloze subquestions outside math environment.
+%       \item The scope of the |tolerance| key is now respected.
+%   \end{version}
+%   \begin{version}[version=0.7,date=2020-09-06]
+%     \added
+%       \item Support for inclusion of verbatim code.
+%       \item Package option \texttt{tikz}.
+%       \item Support for |\"Y| and |\"y|.
+%       \item New commands converted to XML.
+%       \item Adding a stamp comment in XML, package option offered to disable
+%             this behavior.
+%       \item Support for the |\tikz| command.
+%       \item A different directory can be specified for picture inclusion.
+%       \item Warn user of the \texttt{babel} package set for french that autospacing
+%             must be deactivated.
+%       \item Square bracket math delimiters are recognized and converted properly.
+%       \item Support of breve and caron diacritical marks.
+%     \changed
+%       \item In multi with multiple answers allowed, choosing all options no longer
+%             results in a good grade. An automatic penalty mechanism is introduced.
+%             Can be overridden by manually setting fractions.
+%     \removed
+%       \item Irrelevant \texttt{penalty} tag in cloze subquestions.
+%     \fixed
+%       \item Non-integer fractions can now be specified in cloze subquestions.
+%       \item Signifiantly squeeze PNG images size by skipping ancillary data.
+%       \item Enumerate or itemize environment can now be nested in question items.
+%       \item Several pictures can be included in a question without being mixed
+%             in the XML file.
+%       \item management and rendering of fraction in questions.
+%       \item Correctly handling a \LaTeX\ starting the last item of a question.
+%       \item Closing braces escaped in cloze subquestions. This allows \LaTeX\
+%             equations or images to be included.
+%       \item Image inclusion with MacOS.
+%   \end{version}
+%   \begin{version}[version=0.6b,date=2019-11-27]
+%     \added
+%       \item New package options to set section or subsection at the quiz level.
+%       \item True/False question type is now supported.
+%       \item Moodle tags can now be specified for questions (and rendered in PDF
+%             as well).
+%       \item In cloze questions, the \texttt{multiresponse} subquestion type is
+%             now supported.
+%     \removed
+%       \item External dependency on \texttt{OpenSSL}.
+%       \item Irrelevant tags were written in XML for matching questions.
+%     \fixed
+%       \item \TikZ\ externalization now works when using \XeLaTeX.
+%       \item It is now possible to set points manually among several correct
+%             answers in multichoice questions.
+%       \item General feedbacks can now contain backslashes.
+%       \item Several quizzes can now be defined in a single source file, each
+%             specifying a category for Moodle's question bank.
+%       \item Correct encoding information in now written in XML depending on
+%             the \LaTeX\ compiler used.
+%   \end{version}
+%   \begin{version}[version=0.6a,date=2019-06-21]
+%     \added
+%       \item \XeLaTeX\ is now recommended when using UTF8-encoded sources (support
+%             of accents).
+%       \item Feedbacks are now displayed in the PDF file produced.
+%       \item The \texttt{optipng} utility is used (and required) to reduce the size
+%             of images embedded in the XML file.
+%       \item Question options and settings are now displayed in the PDF file
+%       \item Supporting more \LaTeX\ macros for symbols and accents (mostly
+%             diacritical marks and ligatures).
+%       \item Introduce shuffle options in cloze-multi subquestions.
+%       \item Package option \texttt{final}.
+%     \changed
+%       \item In draft mode, \TikZ\ externalization in no longer triggered.
+%     \fixed
+%       \item In the different question types, the feedback fields are now converted
+%             for HTML allowing \LaTeX\ equation and images.
+%       \item Documentation improvements (limitations and previously undocumented
+%             features).
+%   \end{version}
+%   \shortversion{version=0.5,date=2016-01-05,simple,changes=Initial version,author={Anders O.F. Hendrickson}}
+% \end{changelog}
+%
 % \StopEventually{}
 %
 % \section{Implementation}
@@ -722,13 +1658,35 @@
 % \subsection{Packages, Options, and Utilities}
 %    \begin{macrocode}
 \newif\ifmoodle at draftmode
+\newif\ifmoodle at handout
+\newif\ifmoodle at stampmode
+\newif\ifmoodle at tikz
 \newif\ifmoodle at tikzloaded
+\newif\ifmoodle at svg
+\newif\ifmoodle at section
+\newif\ifmoodle at subsection
+\newif\ifmoodle at numbered
 
 %%DECLARATION OF OPTIONS
 \DeclareOption{draft}{\moodle at draftmodetrue}
+\DeclareOption{handout}{\moodle at handouttrue}
+\DeclareOption{final}{\moodle at draftmodefalse}
+\DeclareOption{nostamp}{\moodle at stampmodefalse}
+\DeclareOption{tikz}{\moodle at tikztrue}
+\DeclareOption{svg}{\moodle at svgtrue}
+\DeclareOption{section}{\moodle at sectiontrue\moodle at numberedtrue}
+\DeclareOption{section*}{\moodle at sectiontrue\moodle at numberedfalse}
+\DeclareOption{subsection}{\moodle at sectionfalse\moodle at numberedtrue}
+\DeclareOption{subsection*}{\moodle at sectionfalse\moodle at numberedfalse}
 
 \moodle at draftmodefalse
+\moodle at handoutfalse
+\moodle at stampmodetrue
+\moodle at tikzfalse
 \moodle at tikzloadedfalse
+\moodle at svgfalse
+\moodle at subsectiontrue
+\moodle at numberedfalse
 
 \ProcessOptions
 
@@ -735,21 +1693,47 @@
 \RequirePackage{environ} %To be able to take environment body as a macro argument
 \RequirePackage{xkeyval} %For key-handling
 \RequirePackage{amssymb} %For \checkmark symbol
-\RequirePackage{trimspaces} %To remove extra spaces from strings
+%\RequirePackage{trimspaces} %To remove extra spaces from strings (loaded by environ)
 \RequirePackage{etex}    %Expansion control, detokenization, etc.
 \RequirePackage{etoolbox}%List management
 \RequirePackage{xpatch}  %To patch commands easily in HTML mode
 \RequirePackage{array}   %For formatting tables in the LaTeX mode of Clozes
 \RequirePackage{ifplatform} % To choose Ghostscript commands
-\RequirePackage{ifpdf} % Needed to know whether we can convert output from PDF to PNG
-
+\@ifpackageloaded{iftex}{}{\RequirePackage{iftex}}
+% iftex already required by recent versions of ifplatform. Needed to know:
+%     1) whether we can convert output from PDF to PNG (ifpdf), 
+%     2) when output pdf is latin1-encoded (ifpdf)
+%     3) when output xml is utf8-encoded (if?tex)
+\@ifundefined{ifpdf}{\RequirePackage{ifpdf}}{}% old iftex would not define the conditional
+\RequirePackage{shellesc} %Luatex-compatible way of getting system access
+\RequirePackage{fancybox} %For fancy LaTeX tags
 \RequirePackage{getitems} %To gather the header and items
+\ifmoodle at handout
+  \RequirePackage[seed=42]{randomlist} %To randomize answers in matching questions
+\fi
+\ifmoodle at svg
+  \RequirePackage{graphicx} %To include graphics
+\fi
 
 \let\xa=\expandafter
 \def\@star{*}%
 \def\@hundred{100}%
+\def\@fifty{50}%
 \def\@moodle at empty{}%
 \def\@relax{\relax}%
+\def\@moodle at par{\par}%
+
+% Taken from https://tex.stackexchange.com/questions/47576/combining-ifxetex-and-ifluatex-with-the-logical-or-operation
+\@ifundefined{ifTUTeX}{
+  \newif\ifTUTeX % a new conditional starts as false
+  \ifnum 0\ifXeTeX 1\fi\ifLuaTeX 1\fi>0%
+    \TUTeXtrue
+  \fi
+}{}%
+\newif\ifpdfoutput % a new conditional starts as false
+\ifnum 0\ifTUTeX 1\fi\ifPDFTeX\ifpdf 1\fi\fi>0%
+   \pdfoutputtrue
+\fi
 %    \end{macrocode}
 % As the package involves a fair bit of file processing,
 % we automate the naming of auxiliary files.
@@ -787,9 +1771,42 @@
 \newwrite\moodle at outfile
 \def\openmoodleout{%
   \immediate\openout\moodle at outfile=\outputfilename\relax
-  \writetomoodle{<?xml version="1.0" encoding="UTF-8"?>}%
+  \ifPDFTeX % latin1-based engines (pdflatex or latex)
+    \writetomoodle{<?xml version="1.0" encoding="iso-8859-1"?>}%
+  \else
+    \ifTUTeX % UTF8-based engines (XeTeX or LuaTeX)
+      \writetomoodle{<?xml version="1.0" encoding="UTF-8"?>}%
+    \else % what shall we do?
+      \writetomoodle{<?xml version="1.0" encoding="UTF-8"?>}%
+      %\stop
+    \fi
+  \fi
+  \ifmoodle at stampmode
+    \def\moodle at stamp{This file was generated on \the\year-\two at digits\month-\two at digits\day}
+    \ifPDFTeX % pdflatex or latex
+      \ifpdf % pdflatex
+        \g at addto@macro{\moodle at stamp}{ by pdfLaTeX }%
+      \else % latex
+        \g at addto@macro{\moodle at stamp}{ by LaTeX }%
+      \fi
+    \else
+      \ifXeTeX % xetex
+        \g at addto@macro{\moodle at stamp}{ by XeLaTeX }%
+      \else
+        \ifLuaTeX % luatex
+          \g at addto@macro{\moodle at stamp}{ by LuaLaTeX }%
+        \else
+          \g at addto@macro{\moodle at stamp}{ a TeX engine }%
+        \fi
+      \fi
+    \fi
+    \writetomoodle{<!-- \moodle at stamp -->}%
+    \def\moodle at stamp{running on \platformname}%
+    \g at addto@macro{\moodle at stamp}{ with the package moodle v0.8 }%
+    \writetomoodle{<!-- \moodle at stamp -->}%
+  \fi
+  \immediate\write\moodle at outfile{}%
   \writetomoodle{<quiz>}%
-  \writetomoodle{ }%
 }%
 \def\closemoodleout{%
   \writetomoodle{ }%
@@ -797,6 +1814,7 @@
   \immediate\closeout\moodle at outfile
 }%
 %    \end{macrocode}
+% 
 % To both make this |.sty| file and the XML output more readable,
 % we create a mechanism for writing to the output file with indents.
 % The macro |\calculateindent|\marg{$n$} globally defines 
@@ -836,27 +1854,71 @@
 % We now create the main |quiz| environment that will contain
 % the questions we write.  It outputs to XML as a |<question type="category">| tag.
 %    \begin{macrocode}
-\newenvironment{quiz}[2][]%
-  {\setkeys{moodle}{#1}%
-   \@moodle at ifgeneratexml{%
-     \openmoodleout%
-     \setcategory{#2}%
-    }{}%
-    \subsection*{#2}%
-    \begin{enumerate}%
-   }
-  {\end{enumerate}%
-   \@moodle at ifgeneratexml{\closemoodleout}{}}
-
-{\catcode`\$=12\catcode`\ =12%
-\gdef\setcategory#1{%
+{\catcode`\$=12\catcode`\ =12% in this context we cannot indent with spaces...
+\gdef\moodle at write@category at xml#1{%
+\@moodle at ifgeneratexml{%
+\writetomoodle{ }%
 \writetomoodle{<question type="category">}%
 \writetomoodle{  <category>}%
-\writetomoodle{    <text>$module$/#1</text>}%
+\writetomoodle{    <text>$course$/top/#1</text>}%
 \writetomoodle{  </category>}%
 \writetomoodle{</question>}%
 \writetomoodle{ }%
+}{}%
 }}%
+\newcommand*\@enumeratename{enumerate}%
+\newenvironment{quiz}[2][]{%
+  \setkeys{moodle}{#1}%
+  \gdef\setcategory##1{%
+    % At first call (end of \begin{quiz}) enumerate is not started yet
+    \ifx\@currenvir\@enumeratename
+      % In case no question is defined between two calls of \setcategory
+      \def\@noitemerr{\@latex at warning{Empty question list}}%
+      \end{enumerate}%
+    \fi
+    \gdef\moodle at currentcategory{##1}%
+    \moodle at write@category at xml{##1}%
+    \ifmoodle at section
+      \ifmoodle at numbered
+        \section{##1}%
+      \else
+        \section*{##1}%
+      \fi
+    \else
+      \ifmoodle at numbered
+        \subsection{##1}%
+      \else
+        \subsection*{##1}%
+      \fi
+    \fi
+    \begin{enumerate}%
+  }%
+  \gdef\setsubcategory##1{%
+    \def\@noitemerr{\@latex at warning{Empty question list}}%
+    \end{enumerate}%
+    \moodle at write@category at xml{\moodle at currentcategory/##1}%
+    \ifmoodle at section
+      \ifmoodle at numbered
+        \subsection{##1}%
+      \else
+        \subsection*{##1}%
+      \fi
+    \else
+      \ifmoodle at numbered
+        \subsubsection{##1}%
+      \else
+        \subsubsection*{##1}%
+      \fi
+    \fi
+    \begin{enumerate}%
+  }%
+  \setcategory{#2}%
+}{%
+  \end{enumerate}%
+  \let\setcategory\relax
+  \let\setsubcategory\relax
+}%
+
 %    \end{macrocode}                       
 % The next utility takes a single macro control sequence |#1|,
 % and allows that macro's current value to persist
@@ -888,6 +1950,19 @@
   }%
 }
 %    \end{macrocode}
+% Now the macros |openmoodleout| and |closemoodleout| are triggered at Begin and End Document, respectively
+%    \begin{macrocode}
+\AfterEndPreamble{
+  \@moodle at ifgeneratexml{%
+    \openmoodleout%
+  }{}%
+}
+\AtEndDocument{
+  \@moodle at ifgeneratexml{%
+    \closemoodleout%
+  }{}%
+}
+%    \end{macrocode}
 %
 % \subsection{Key-Value Pairs for Quiz Questions}
 % 
@@ -902,7 +1977,7 @@
 % to the output XML file.
 % 
 % The ordinary version |\generate at moodle@write at code| passes its output text |#3|
-% through the HTMLizer, producing HTML code, while the starred version 
+% through the HTMLizer, producing HTML code, while the starred variant
 % |\generate at moodle@write at code*| passes |#3| verbatim as text.
 % 
 % For example, 
@@ -951,6 +2026,23 @@
   }%
 }%
 
+\def\generate at moodle@write at html@noptag#1<#2>#3{%
+	% No <P>..</P> introduced
+	% #1 = NAME for \moodle at writeNAME
+	% #2 = HTML tag
+	% #3 = what, exactly, to write
+	\xa\gdef\csname moodle at write#1\endcsname{%
+		\xa\def\xa\test at iii\xa{#3}%
+		\ifx\test at iii\@moodle at empty
+		\writetomoodle[2]{  <#2 format="html"><text/></#2>}%
+		\else
+		\xa\converttohtmlmacro\xa\moodle at htmltowrite\xa{#3}%
+		\writetomoodle[2]{  <#2 format="html">}%
+		\writetomoodle[4]{    <text><![CDATA[\moodle at htmltowrite]]></text>}%
+		\writetomoodle[2]{  </#2>}%
+		\fi
+	}%
+}%
 
 \def\generate at moodle@write at data*#1<#2>#3{%
   % #1 = NAME for \moodle at writeNAME
@@ -961,16 +2053,33 @@
   }%
 }%
 
+\def\generate at moodle@write at tags#1{%
+  % #1 = NAME for \moodle at writeNAME
+  % #3 = what, exactly, to write
+  \xa\gdef\csname moodle at writetags\endcsname{%
+    %\xa\xa\xdef\xa\xa\ds\xa\xa{Encountered '\string #1'}\show\ds
+    \xa\xdef\xa\test at iii\xa{\moodle at tags}%
+    \ifx\test at iii\@moodle at empty\relax\else
+      \xa\converttohtmlmacro\xa\moodle at htmltowrite\xa{\moodle at tags}%
+      \writetomoodle[2]{  <tags>}%
+      \writetomoodle[4]{    <tag><text><![CDATA[\moodle at htmltowrite]]></text></tag>}%
+      \writetomoodle[2]{  </tags>}%
+    \fi
+  }%
+}%
+
 %    \end{macrocode}
 % \subsubsection{Keys for all question types}
 %    \begin{macrocode}
 %% QUESTIONNAME
       \define at cmdkey{moodle}[moodle@]{questionname}{}%
-      \gdef\moodle at writequestionname{%
-        \writetomoodle[2]{<name>}%
-        \writetomoodle[4]{  <text>\moodle at questionname</text>}%
-        \writetomoodle[2]{</name>}%
-      }%
+%      \gdef\moodle at writequestionname{%
+%        \writetomoodle[2]{<name>}%
+%        \writetomoodle[4]{  <text>\moodle at questionname</text>}%
+%        \writetomoodle[2]{</name>}%
+%      }%
+%\generate at moodle@write at code{questionname}<name>{\moodle at questionname}%
+\generate at moodle@write at html@noptag{questionname}<name>{\moodle at questionname}%
 
 %% QUESTIONTEXT
       %I tried to use questiontext as a key, but it doesn't seem to work.
@@ -986,9 +2095,9 @@
       \generate at moodle@write at code{questiontext}<questiontext>{\moodle at questiontext}%{%
 
 %% PENALTY FOR WRONG ATTEMPT
-      \define at cmdkey{moodle}[moodle@]{penalty}[0.1000000]{}%
+      \define at cmdkey{moodle}[moodle@]{penalty}[0.10]{}%
       \generate at moodle@write at code*{penalty}<penalty>{\moodle at penalty}%
-      \moodleset{penalty}%
+      \moodleset{penalty=0.10}%
 
 %% FEEDBACK
       % Moodle allows for feedback tailored to each question,
@@ -1002,7 +2111,7 @@
       \define at cmdkey{moodle}[moodle@]{feedback}[]{}%
       \generate at moodle@write at code{generalfeedback}<generalfeedback>{\moodle at feedback}%
       \generate at moodle@write at code{feedback}<feedback>{\moodle at feedback}%
-      \moodleset{feedback}%
+      \moodleset{feedback={}}%
 
 %% DEFAULT GRADE
       %The next line creates \moodle at defaultgrade,
@@ -1028,7 +2137,14 @@
   \moodle at writehidden%
 }%
 
-% TO DO: 'tags' (i.e., keywords)
+%% TAGS
+      %The next line creates \moodle at tags,
+      %which defines a "tag" (i.e., keyword) for the question.
+      %Key calls like [tags={random}] set \moodle at tags.
+      \define at cmdkey{moodle}[moodle@]{tags}[]{}%
+      \generate at moodle@write at tags{\csname moodle at tags\endcsname}%
+      \moodleset{tags}%
+% TODO: handle multiple 'tags' for one question
 
 %    \end{macrocode}
 % \subsubsection{Keys for all answers}
@@ -1039,6 +2155,11 @@
       %the XML within the answer tag, like <answer fraction="75">.
       \moodleset{fraction=100} %This sets the default.
 %    \end{macrocode}
+%    \begin{macrocode}
+%% FRACTIONTOL -- the tolerance for fractions with respect to valid values
+      \define at cmdkey{moodle}[moodle@]{fractiontol}[0.1]{}%
+      \moodleset{fractiontol=0.1} %This sets the default.
+%    \end{macrocode}
 % \subsubsection{Keys for multiple choice questions}
 %    \begin{macrocode}
 
@@ -1045,7 +2166,7 @@
 %% SINGLE and MULTIPLE -- for multichoice, is there 1 right answer or more than 1?
       \define at boolkey{moodle}[moodle@]{single}[true]{}%
       \generate at moodle@write at code*{single}<single>{\ifmoodle at single true\else false\fi}%
-      \moodleset{single}%
+      \moodleset{single=true}%
       %The key 'multiple' is an antonym to 'single'.
       \define at boolkey{moodle}[moodle@]{multiple}[true]{\ifmoodle at multiple\moodle at singlefalse\else\moodle at singletrue\fi}%
 
@@ -1054,15 +2175,15 @@
       \generate at moodle@write at code*{shuffle}<shuffleanswers>{\ifmoodle at shuffle 1\else 0\fi}%
       \moodleset{shuffle=true}%
 
-%% TO DO: CORRECTFEEDBACK
-%% TO DO: PARTIALLYCORRECTFEEDBACK
-%% TO DO: INCORRECTFEEDBACK
-%% TO DO: NUMCORRECT key
+%% TODO: CORRECTFEEDBACK
+%% TODO: PARTIALLYCORRECTFEEDBACK
+%% TODO: INCORRECTFEEDBACK
+%% TODO: NUMCORRECT key
 
 %% NUMBERING -- for numbering of multichoice questions
       \define at choicekey{moodle}{numbering}%
                        {alpha,alph,Alpha,Alph,arabic,roman,Roman,%
-                        abc,ABC,123,iii,IIII,none}[abc]{%
+                        abc,ABCD,123,iii,IIII,none}[abc]{%
                         \def\moodle at numbering{#1}%
                         \def\test@@i{#1}%
                         \ifx\test@@i\@moodle at alpha
@@ -1070,9 +2191,9 @@
                         \ifx\test@@i\@moodle at alph
                           \def\moodle at numbering{abc}\fi
                         \ifx\test@@i\@moodle at Alpha
-                          \def\moodle at numbering{ABC}\fi
+                          \def\moodle at numbering{ABCD}\fi
                         \ifx\test@@i\@moodle at Alph
-                          \def\moodle at numbering{ABC}\fi
+                          \def\moodle at numbering{ABCD}\fi
                         \ifx\test@@i\@moodle at arabic
                           \def\moodle at numbering{123}\fi
                         \ifx\test@@i\@moodle at roman
@@ -1094,7 +2215,7 @@
       \def\@moodle at roman{roman}%
       \def\@moodle at Roman{Roman}%      
       \def\@moodle at abc{abc}%
-      \def\@moodle at ABC{ABC}%
+      \def\@moodle at ABCD{ABCD}%
       \def\@moodle at arabicnumbers{123}%
       \def\@moodle at iii{iii}%
       \def\@moodle at IIII{IIII}%
@@ -1103,7 +2224,7 @@
         \ifx\moodle at numbering\@moodle at abc
           \renewcommand\theenumii{\alph{enumii}}%
         \fi
-        \ifx\moodle at numbering\@moodle at ABC
+        \ifx\moodle at numbering\@moodle at ABCD
           \renewcommand\theenumii{\Alph{enumii}}%
         \fi
         \ifx\moodle at numbering\@moodle at arabicnumbers
@@ -1119,7 +2240,7 @@
           \renewcommand\labelenumii{$\bullet$~}%
         \fi
       }
-      %TO DO: * In the PDF, how should 'none' in a multi look different from 
+      %TODO: * In the PDF, how should 'none' in a multi look different from 
       %         short answer or numerical options?
       %       * Instead of \theenumi and \labelenumi,
       %         use \@enumdepth to automatically set the correct depth.
@@ -1140,7 +2261,7 @@
       %tolerance is given within the answer tag,
       %like <answer fraction=100 tolerance=0.03>.
 
-% TO DO: implement unit-handling for numerical questions!
+% TODO: implement unit-handling for numerical questions!
 %    \end{macrocode}
 % \subsubsection{Keys for short answer questions}
 %    \begin{macrocode}
@@ -1215,7 +2336,7 @@
 
 %% RESPONSE REQUIRED
       \define at boolkey{moodle}[moodle@]{response required}[true]{}%
-      % TO DO: Make synonym 'required'
+      % TODO: Make synonym 'required'
       \generate at moodle@write at code*{responserequired}<responserequired>{\csname ifmoodle at response required\endcsname 1\else 0\fi}%
       \moodleset{response required=false}%
 
@@ -1245,7 +2366,7 @@
 
 %% RESPONSE TEMPLATE
       \define at key{moodle}{template}{\long\def\moodle at responsetemplate{#1}}%
-      \generate at moodle@write at code{responsetemplate}<responsetemplate>{\moodle at responsetemplate}
+      \generate at moodle@write at html@noptag{responsetemplate}<responsetemplate>{\moodle at responsetemplate}
       \moodleset{template={}}%
 %    \end{macrocode}
 % \subsubsection{Hint tags}
@@ -1269,7 +2390,7 @@
       }%
       \moodleset{clearwrong=false}%
 
-% TO DO: Implement hints
+% TODO: Implement hints
 %    \end{macrocode}
 %
 % \subsection{Answer handling}
@@ -1305,23 +2426,8 @@
 % \subsubsection{Not yet implemented}
 % 
 %    \begin{macrocode}
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%% TRUE/FALSE QUESTIONS %%%%%%%%%%%%%%%%%
 
-% TODO: implement the \writetruefalsequestion
-% and a front-end.
-
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%% DESCRIPTION 'QUESTIONS' %%%%%%%%%%%%%
-
-% TODO: implement the \writedescription and a suitable front-end.
-%       Should this be \begin{description}...\end{description},
-%       or should \begin{quiz}...\end{quiz} just scoop up all
-%       text outside question environments and package it in descriptions?
-
-
-
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %% CALCULATED %%%%%%%%%%%%%%%%%%%%%%%%%%
 
 % TODO: I don't think I really want to handle this.  Not now.
@@ -1354,7 +2460,34 @@
 % \end{Verbatim}
 % 
 %    \begin{macrocode}
-\def\moodle at makefrontend#1{%
+
+\def\moodle at makelatextagbox#1{%
+%  \ifmoodle at tikzloaded
+%    \tikzset{external/export next=false}
+%    \tikz[baseline]{\node[draw,minimum height=1.2em,rounded corners,fill=black!20] {\tiny #1};}
+%  % Fancy but interferes with the tikzexternalize counter
+%  \else
+    \Ovalbox{\tiny #1}
+    %\ovalbox{\tiny #1}
+    %\shadowbox{\tiny #1}
+%  \fi
+}%
+
+\def\moodle at makelatextag@qtype#1{%
+  \doublebox{\tiny \textsc{#1}}
+}%
+
+\def\moodle at makelatextag@value#1#2{%
+  \moodle at makelatextagbox{\csname moodle@#1\endcsname~#2}
+}%
+
+\def\moodle at makelatextag@key#1{%
+  \moodle at makelatextagbox{\csname moodle@#1\endcsname}
+}%
+
+\def\moodle at marks#1{point\ifdim#1pt=1pt \else s\fi}
+
+\def\moodle at makefrontend#1#2{%
   \NewEnviron{#1}[2][]{%
     \bgroup
       \setkeys{moodle}{##1,questionname={##2}}%
@@ -1361,13 +2494,29 @@
       \expandafter\gatheritems\xa{\BODY}%
       \let\moodle at questionheader=\gatheredheader
       %First, the LaTeX processing
-      \item \textbf{\moodle at questionname}\par
+      \item \textbf{\moodle at questionname}
+      \ifmoodle at handout
+        \moodle at makelatextag@qtype{#1}
+      \else
+        \xa\xdef\xa\test at iii\xa{\moodle at tags}%
+        \ifx\test at iii\@moodle at empty\relax\else
+          \hfill tags: \texttt{\moodle at tags}
+        \fi
+        \par
+        \noindent
+        \moodle at makelatextag@qtype{#1}
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+        \moodle at makelatextag@value{penalty}{penalty}
+      \fi
+      #2\par
       \noindent
       \moodle at questionheader
+      \edef\moodle at generalfeedback{\expandonce\moodle at feedback}
       \csname moodle@#1 at latexprocessing\endcsname
       %Now, writing information to XML
       \@moodle at ifgeneratexml{%
         \xa\questiontext\xa{\moodle at questionheader}% Save the question text.
+        \csname write#1question\endcsname
         \bgroup
           \gdef\moodle at answers@xml{}%
           \setkeys{moodle}{feedback={}}%
@@ -1374,7 +2523,9 @@
           \xa\loopthroughitemswithcommand\xa{\csname save#1answer\endcsname}%
           \passvalueaftergroup{\moodle at answers@xml}%
         \egroup
-        \csname write#1question\endcsname
+        \moodle at writeanswers%
+        \moodle at writetags%
+        \writetomoodle{</question>}%
       }{}%
     \egroup
   }%
@@ -1381,21 +2532,70 @@
 }
 %    \end{macrocode}
 %
+% \subsubsection{Description Question Front-End}
+% Description and essay questions are the only question types whose front end
+% is not yet created by |\moodle at makefrontend|.
+% This is because of what need to be done with their contents.
+%
+% Description blocks can be empty. In this case, nothing is done.
+%
+%    \begin{macrocode}
+\let\description\relax% remove the meaning of existing \description and \enddescription
+\let\enddescription\relax
+\NewEnviron{description}[2][]{%
+  \bgroup
+    \setkeys{moodle}{#1,questionname={#2}}%
+    \let\moodle at questiontext=\BODY
+    \trim at spaces@in\moodle at questiontext
+    \ifx\moodle at questiontext\@empty\relax\else%
+      %First, the LaTeX processing.
+      \item \textbf{\moodle at questionname}
+      \ifmoodle at handout\else
+        \xa\xdef\xa\test at iii\xa{\moodle at tags}%
+        \ifx\test at iii\@moodle at empty\relax\else
+          \hfill tags: \texttt{\moodle at tags}%
+        \fi
+        \par
+        \noindent
+      \fi
+      \moodle at makelatextag@qtype{description}\par
+      \noindent
+      \moodle at questiontext\par
+      \ifmoodle at handout\else
+        \ifx\moodle at feedback\@empty\relax\else
+          \fbox{\parbox{\linewidth}{\emph{\moodle at feedback}}}%
+        \fi
+      \fi
+      %Now, writing information to memory.
+      \@moodle at ifgeneratexml{%
+        \writetomoodle{<question type="description">}%
+        \moodle at writecommondata
+        \moodle at writetags%
+        \writetomoodle{</question>}%
+      }{}%
+    \fi
+  \egroup
+}%
+%    \end{macrocode}
+%
 % \subsubsection{Essay Question Front-End}
-% The essay question is the only question type whose front end
-% is not yet created by |\moodle at makefrontend|.
-% This is because of what it must do with its |\item|'s.
+% The front end is not yet created by |\moodle at makefrontend| because of
+% what must must be done with the |\item|'s.
 % 
 %    \begin{macrocode}
 \def\moodle at essay@latexprocessing{%
   % Moodle cannot automatically grade an essay, 
   % but if the user puts \item's in, we can list them in an itemize as notes.
+  \par\noindent \emph{Notes for grader:}
+  \moodle at questionheader
   \ifnum\c at numgathereditems>0\relax
-    \par\noindent Notes: (not included in XML)
     \begin{itemize} \setlength\itemsep{0pt}\setlength\parskip{0pt}%
       \loopthroughitemswithcommand{\moodle at print@essay at answer}%
     \end{itemize}%
   \fi
+  \ifx\moodle at generalfeedback\@empty\relax\else%
+    \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+  \fi
 }
 
 \NewEnviron{essay}[2][]{%
@@ -1404,13 +2604,35 @@
     \expandafter\gatheritems\expandafter{\BODY}%
     \let\moodle at questionheader=\gatheredheader
     %First, the LaTeX processing.
-      \item \textbf{\moodle at questionname}\par
+      \item \textbf{\moodle at questionname}
+      \ifmoodle at handout
+        \moodle at makelatextag@qtype{essay}
+      \else
+        \xa\xdef\xa\test at iii\xa{\moodle at tags}%
+        \ifx\test at iii\@moodle at empty\relax\else
+          \hfill tags: \texttt{\moodle at tags}
+        \fi
+        \par
+        \noindent
+        \moodle at makelatextag@qtype{essay}
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+        \moodle at makelatextag@value{penalty}{penalty}
+        \moodle at makelatextag@key{responseformat}
+      \fi
+      \par
       \noindent
-      \moodle at questionheader
-      \csname moodle at essay@latexprocessing\endcsname
+      \ifx\moodle at responsetemplate\@empty\relax\else%
+        \par\noindent \emph{Template:}
+        \par\fbox{\parbox{\linewidth}{\moodle at responsetemplate}}\par
+      \fi
+      \edef\moodle at generalfeedback{\expandonce\moodle at feedback}
+      \ifmoodle at handout\else
+        \csname moodle at essay@latexprocessing\endcsname
+      \fi
     %Now, writing information to memory.
     \@moodle at ifgeneratexml{%
       \xa\questiontext\xa{\moodle at questionheader}% Save the question text.
+      \writeessayquestion
       \bgroup
         \gdef\moodle at answers@xml{}%
         %
@@ -1430,12 +2652,15 @@
         %
         \passvalueaftergroup{\moodle at answers@xml}%
       \egroup
-      \writeessayquestion
+      \moodle at writeanswers% The 'answers' XML really contains the grader info.
+      \moodle at writeresponsetemplate%
+      \moodle at writetags%
+      \writetomoodle{</question>}%
     }{}%
   \egroup
 }%
 
-%%%% TO DO
+%%%% TODO
 %%%% To make essay work will be tough.
 %%%% Every line from \ifnum\c at numgathereditems=0\relax through its \else and \fi,
 %%%% with the exception of
@@ -1477,9 +2702,6 @@
     \moodle at writeresponsefieldlines%
     \moodle at writeattachmentsallowed%
     \moodle at writeattachmentsrequired%
-    \moodle at writeanswers% The 'answers' XML really contains the grader info.
-    \moodle at writeresponsetemplate%
-  \writetomoodle{</question>}%
 }%
 
 \def\moodle at print@essay at answer#1{%
@@ -1488,6 +2710,7 @@
 
 
 \def\moodle at savegraderinfo#1{%
+  %\def\ds{#1}\show\ds
   \bgroup
     \moodle at savegraderinfo@int#1\moodle at answer@rdelim
     \passvalueaftergroup{\moodle at answers@xml}%
@@ -1498,7 +2721,8 @@
   \moodle at savegraderinfo@int at int%
 }%
 \def\moodle at savegraderinfo@int at int#1\moodle at answer@rdelim{%
-  \xa\converttohtmlmacro\xa\moodle at answertext@html\xa{#1}%
+  \def\moodle at answertext{#1}
+  \xa\converttohtmlmacro\xa\moodle at answertext@html\xa{\moodle at answertext}%
   %\trim at spaces@in\moodle at answertext
   \ifnum\c at numgathereditems>1\relax
     \addto at xml[6]{\moodle at answers@xml}{<li>\moodle at answertext@html</li>}%
@@ -1512,17 +2736,21 @@
 % 
 %    \begin{macrocode}
 \def\blank{\rule{1in}{0.5pt}}%
-% TO DO: Make an optional argument for width?  This wouldn't affect Moodle,
+% TODO: Make an optional argument for width?  This wouldn't affect Moodle,
 %        only the appearance in the PDF.  It doesn't seem worth it.
 
-% \NewEnviron{shortanswer}[2][]{%
+%\NewEnviron{shortanswer}[2][]{%
 %   \bgroup
 %     \setkeys{moodle}{#1,questionname={#2}}%
 %     \expandafter\gatheritems\xa{\BODY}%
 %     \let\moodle at questionheader=\gatheredheader
 %     %First, the LaTeX processing.
-%       \bigskip\par\noindent
-%       \fbox{\textbf{\moodle at questionname}}\par
+%       \item \textbf{\moodle at questionname}
+%       \csname ifmoodle at case sensitive\endcsname
+%         \framebox{\tiny Case-Sensitive}\relax
+%       \fi
+%       \framebox{\tiny\csname moodle at default grade\endcsname~points}
+%       \framebox{\tiny\csname moodle at penalty\endcsname~penalty}\par
 %       \noindent
 %       \moodle at questionheader
 %       \csname moodle at shortanswer@latexprocessing\endcsname
@@ -1532,7 +2760,8 @@
 %       \bgroup
 %         \gdef\moodle at answers@xml{}%
 %         \setkeys{moodle}{feedback={}}%
-%         \xa\loopthroughitemswithcommand\xa{\csname saveshortansweranswer\endcsname}%
+%         \xa\loopthroughitemswithcommand\xa{\csname 
+%         saveshortansweranswer\endcsname}%
 %         \passvalueaftergroup{\moodle at answers@xml}%
 %       \egroup
 %       \csname writeshortanswerquestion\endcsname
@@ -1540,16 +2769,33 @@
 %   \egroup
 % }%
 
-\moodle at makefrontend{shortanswer}%
+\moodle at makefrontend{shortanswer}{\moodle at makelatextag@shortanswer}%
 
 % LATEX PROCESSING
-\def\moodle at shortanswer@latexprocessing{%
-  \begin{itemize} \setlength\itemsep{0pt}\setlength\parskip{0pt}%
-    \loopthroughitemswithcommand{\moodle at print@shortanswer at answer}%
-  \end{itemize}%
+
+\def\moodle at makelatextag@shortanswer{%
+  \csname ifmoodle at case sensitive\endcsname
+    \moodle at makelatextagbox{Case-Sensitive}\relax
+  \else
+    \moodle at makelatextagbox{Case-Insensitive}\relax
+  \fi
 }
 
+\ifmoodle at handout
+  \let\moodle at shortanswer@latexprocessing\relax
+\else
+  \def\moodle at shortanswer@latexprocessing{%
+    \begin{itemize} \setlength\itemsep{0pt}\setlength\parskip{0pt}%
+      \loopthroughitemswithcommand{\moodle at print@shortanswer at answer}%
+    \end{itemize}%
+    \ifx\moodle at generalfeedback\@empty\relax\else%
+      \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+    \fi
+  }
+\fi
+
    \def\moodle at print@shortanswer at answer#1{%
+       \let\moodle at feedback=\@empty
        \moodle at print@shortanswer at answer@int#1\@rdelim
    }%
    \newcommand\moodle at print@shortanswer at answer@int[1][]{%
@@ -1558,10 +2804,14 @@
    }%
    \def\moodle at print@shortanswer at answer@int at int#1\@rdelim{%
      \ifx\moodle at fraction\@hundred
-       \item #1\quad$\checkmark$%
+       \item #1$~\checkmark$%
      \else
-       \item #1\quad (\moodle at fraction\%)%
+       \moodle at checkfraction
+       \item #1$~(\moodle at fraction\%)$%
      \fi
+     \ifx\moodle at feedback\@empty\relax\else
+       \hfill \emph{$\rightarrow$ \moodle at feedback}
+     \fi
    }%
 
 % SAVING ANSWERS TO MEMORY
@@ -1577,10 +2827,14 @@
    }%
    \def\saveshortansweranswer at int@int#1\moodle at answer@rdelim{%
      \def\moodle at answertext{#1}%
+     \trim at spaces@in\moodle at answertext
+     \moodle at checkfraction
      \addto at xml[2]{\moodle at answers@xml}{<answer fraction="\moodle at fraction" format="plain_text">}%
      \addto at xml[4]{\moodle at answers@xml}{  <text>\moodle at answertext</text>}%
      \ifx\moodle at feedback\@empty\relax\else
-       \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback</p>]]></text></feedback>}%
+       \trim at spaces@in\moodle at feedback
+       \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{\moodle at feedback}%
+       \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback@html</p>]]></text></feedback>}%
      \fi
      \addto at xml[2]{\moodle at answers@xml}{</answer>}%
    }%
@@ -1590,8 +2844,6 @@
   \writetomoodle{<question type="shortanswer">}%
     \moodle at writecommondata%
     \moodle at writeusecase%
-    \moodle at writeanswers%
-  \writetomoodle{</question>}%
 }%
 %    \end{macrocode}
 %
@@ -1598,17 +2850,34 @@
 % \subsubsection{Numerical Question Front-End}
 % 
 %    \begin{macrocode}
-\moodle at makefrontend{numerical}%
+\moodle at makefrontend{numerical}{\moodle at makelatextag@numerical}%
 
 % LATEX PROCESSING
-\def\moodle at numerical@latexprocessing{%
-      \begin{itemize} \setlength\itemsep{0pt}\setlength\parskip{0pt}%
-        \loopthroughitemswithcommand{\moodle at print@numerical at answer}%
-      \end{itemize}%
+
+\def\moodle at makelatextag@numerical{}
+
+\AtEndPreamble{
+  \@ifpackageloaded{siunitx}{\def\moodle at printnum{\num[omit-uncertainty,copy-decimal-marker]}}{\let\moodle at printnum\trim at spaces}%
 }
 
+\ifmoodle at handout
+  \let\moodle at numerical@latexprocessing\relax
+\else
+  \def\moodle at numerical@latexprocessing{%
+    \begin{itemize} \setlength\itemsep{0pt}\setlength\parskip{0pt}%
+      \loopthroughitemswithcommand{\moodle at print@numerical at answer}%
+    \end{itemize}%
+    \ifx\moodle at generalfeedback\@empty\relax\else%
+      \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+    \fi
+  }
+\fi
+
    \def\moodle at print@numerical at answer#1{%
-       \moodle at print@numerical at answer@int#1\@rdelim
+       \let\moodle at feedback=\@empty
+       \bgroup
+         \moodle at print@numerical at answer@int#1\@rdelim
+       \egroup
    }%
    \newcommand\moodle at print@numerical at answer@int[1][]{%
      \setkeys{moodle}{#1}%
@@ -1615,16 +2884,24 @@
      \moodle at print@numerical at answer@int at int%
    }%
    \def\moodle at print@numerical at answer@int at int#1\@rdelim{%
-     \ifdim0pt=\moodle at tolerance pt\relax
-       \def\moodle at numericalprint@tolerance{}%
+     \xdef\test at i{\trim at spaces{#1}}%
+     \ifx\test at i\@star
+       \item \test at i
      \else
-       \edef\moodle at numericalprint@tolerance{\noexpand\pm\moodle at tolerance}%
+       \item \moodle at printnum{#1}%
+       \ifnum\z@=\moodle at tolerance\else
+         $\,\pm\,$\moodle at printnum{\moodle at tolerance}%
+       \fi
      \fi
      \ifx\moodle at fraction\@hundred
-       \item $#1\moodle at numericalprint@tolerance\quad\checkmark$%
+       $~\checkmark$%
      \else
-       \item $#1\moodle at numericalprint@tolerance$\quad (\moodle at fraction\%)%
+       \moodle at checkfraction
+       $~(\moodle at fraction\%)$%
      \fi
+     \ifx\moodle at feedback\@empty\relax\else
+       \hfill \emph{$\rightarrow$ \moodle at feedback}%
+     \fi
    }%
 
 % SAVING ANSWERS TO MEMORY
@@ -1640,11 +2917,17 @@
    }%
    \def\savenumericalanswer at int@int#1\moodle at answer@rdelim{%
      \def\moodle at answertext{#1}%
+     \trim at spaces@in\moodle at answertext
+     \moodle at checkfraction
      \addto at xml[2]{\moodle at answers@xml}{<answer fraction="\moodle at fraction" format="plain_text">}%
      \addto at xml[4]{\moodle at answers@xml}{  <text>\moodle at answertext</text>}%
-     \addto at xml[4]{\moodle at answers@xml}{  <tolerance>\moodle at tolerance</tolerance>}%
+     \ifx\moodle at answertext\@star\else
+       \addto at xml[4]{\moodle at answers@xml}{  <tolerance>\moodle at tolerance</tolerance>}%
+     \fi
      \ifx\moodle at feedback\@empty\relax\else
-       \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback</p>]]></text></feedback>}%
+       \trim at spaces@in\moodle at feedback
+       \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{\moodle at feedback}%
+       \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback@html</p>]]></text></feedback>}%
      \fi
      \addto at xml[2]{\moodle at answers@xml}{</answer>}%
    }%
@@ -1654,8 +2937,6 @@
 \gdef\writenumericalquestion{%
   \writetomoodle{<question type="numerical">}%
     \moodle at writecommondata%
-    \moodle at writeanswers%
-  \writetomoodle{</question>}%
 }%
 %    \end{macrocode}
 %
@@ -1670,57 +2951,155 @@
 %   \item 11
 % \end{multi}%
 
-\moodle at makefrontend{multi}
+\moodle at makefrontend{multi}{\moodle at makelatextag@multi}%
 
 % LATEX PROCESSING
+
+\def\moodle at makelatextag@multi{%
+  \ifmoodle at multiple
+    \moodle at makelatextagbox{Multiple}\relax%
+  \else
+    \moodle at makelatextagbox{Single}\relax%
+  \fi
+  \ifmoodle at handout\else
+    \ifmoodle at shuffle
+      \moodle at makelatextagbox{Shuffle}\relax%
+    \fi
+  \fi
+}
+
 \def\moodle at multi@latexprocessing{%
-      \moodle at countcorrectanswers
-      \begin{enumerate}\moodle at obeynumberingstyle
-                       %\renewcommand{\theenumi}{\alph{enumi}}%
-                       \setlength\itemsep{0pt}\setlength\parskip{0pt}%
-        \loopthroughitemswithcommand{\moodle at print@multichoice at answer}%
-      \end{enumerate}%
+  \moodle at countcorrectanswers%
+  \ifmoodle at handout\NewList{answerlist}\fi
+  \begin{enumerate}\moodle at obeynumberingstyle%
+    %\renewcommand{\theenumi}{\alph{enumi}}%
+    \setlength\itemsep{0pt}\setlength\parskip{0pt}%
+    \loopthroughitemswithcommand{\moodle at print@multichoice at answer}%
+    \ifmoodle at handout
+      \ifmoodle at shuffle
+        \let\moodle at multi@loop=\ForEachRandomItem
+      \else
+        \let\moodle at multi@loop=\ForEachFirstItem
+      \fi
+      \moodle at multi@loop{answerlist}{Answer}{\Answer}%
+    \fi
+  \end{enumerate}%
+  \ifmoodle at handout\else
+    \ifx\moodle at generalfeedback\@empty\relax\else%
+      \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+    \fi
+  \fi
 }
   \def\moodle at print@multichoice at answer#1{%
-    \moodle at print@multichoice at answer@int#1\@rdelim
+    \let\moodle at feedback=\@empty%
+    \moodle at print@multichoice at answer@int#1 \@rdelim%
   }%
   \newcommand\moodle at print@multichoice at answer@int[1][]{%
-    \setkeys{moodle}{fraction=0,#1}%
-    \moodle at print@multichoice at answer@int at int
+    \let\moodle at fraction\@empty%
+    \setkeys{moodle}{#1}%
+    \moodle at print@multichoice at answer@int at int%
   }%
   \def\moodle at print@multichoice at answer@int at int#1#2\@rdelim{%
     \def\test at i{#1}%
-    \ifmoodle at single
-      \ifx\test at i\@star
-        \item #2$~\checkmark$%
+    \def\test at ii{#2}%
+    \def\moodle at answertext{\item }%
+    \ifx\test at i\@star%
+      \g at addto@macro\moodle at answertext{#2}%
+      \ifmoodle at single%
+        \setkeys{moodle}{fraction=100}%
       \else
-        \item #1#2%
+        \setkeys{moodle}{fraction=\moodle at autopoints}%
       \fi
     \else
-      \ifx\test at i\@star
-        \item #2%
-        \setkeys{moodle}{fraction=\moodle at autopoints}%
-      \else
-        \item #1#2%
+      \g at addto@macro\moodle at answertext{#1#2}%
+    \fi
+    \trim at spaces@in\moodle at answertext%
+    \trim at spaces@in\moodle at answertext%
+    \ifmoodle at handout\else
+      \ifmoodle at single%
+        \ifx\moodle at fraction\@empty\relax%
+          \setkeys{moodle}{fraction=0}%
+        \fi
+        \ifx\moodle at fraction\@hundred%
+          \trim at spaces@in\moodle at answertext%
+          \g at addto@macro\moodle at answertext{$~\checkmark$}%
+        \else
+          \moodle at checkfraction
+          \ifdim0pt=\moodle at fraction pt\relax\else%
+            \g at addto@macro\moodle at answertext{$~(\moodle at fraction\%)$}%
+          \fi
+        \fi
+      \else% multiple
+        \ifx\moodle at fraction\@empty\relax%
+          \setkeys{moodle}{fraction=\moodle at autosanctions}%
+        \fi
+        \moodle at checkfraction
+        \g at addto@macro\moodle at answertext{$~(\moodle at fraction\%)$}%
       \fi
-      $~(\moodle at fraction\%)$
     \fi
+    \ifmoodle at handout
+      \def\temp{\InsertLastItem{answerlist}}%
+      \xa\temp\xa{\moodle at answertext}%
+    \else
+      \ifx\moodle at feedback\@empty\relax\else%
+        \g at addto@macro\moodle at answertext{\hfill \emph{$\rightarrow$ \moodle at feedback}}%
+      \fi
+      \moodle at answertext
+    \fi
   }%
 
-% COMMON UTILITY: COUNTING CORRECT ANSWERS
-   \newcounter{moodle at numcorrectanswers}%
+% COMMON UTILITY: COUNTING CORRECT ANSWERS (AND A BIT MORE...)
+   \newcounter{moodle at numcorrectanswers}% count the stars
+   \newcounter{moodle at numincorrectanswers}% count the items without fraction key indicated
    \newlength{\moodle at pointspercorrect}%
+   \newlength{\moodle at pointsperincorrect}%
+   \newlength{\moodle at sumofpositivefractions}% sums user-set positive fractions
+   \newlength{\moodle at sumofnegativefractions}% sums user-set negative fractions
    \def\moodle at countcorrectanswers{%
      \setcounter{moodle at numcorrectanswers}{0}%
+     \setcounter{moodle at numincorrectanswers}{0}%
      \global\setlength{\moodle at pointspercorrect}{100pt}%
+     \global\setlength{\moodle at pointsperincorrect}{-100pt}%
+     \global\setlength{\moodle at sumofpositivefractions}{0pt}%
+     \global\setlength{\moodle at sumofnegativefractions}{0pt}%
      \loopthroughitemswithcommand{\moodle at countcorrectanswers@a}%
-     \ifnum0=\c at moodle@numcorrectanswers\relax
-       \PackageError{moodle}{No correct answers given for multiple choice question.}{Please mark at least one answer correct.}%
-       \gdef\moodle at autopoints{0}%
+     \global\advance\moodle at pointspercorrect by-\moodle at sumofpositivefractions\relax%
+     \def\ds{\strip at pt\moodle at sumofpositivefractions}%
+     \ifnum0=\c at moodle@numcorrectanswers\relax%
+       % autopoints will never be used but we check if the sum of positive fractions is 100%
+       \ifdim\moodle at pointspercorrect<-\moodle at fractiontol pt\relax%
+         \PackageWarning{moodle}{Positive fractions sum up to more than 100 (here: \ds)}%
+       \else
+         \ifdim\moodle at pointspercorrect>\moodle at fractiontol pt\relax%
+           \PackageError{moodle}{Positive fractions sum up to less than 100 (here: \ds)}%
+         \fi
+       \fi
      \else
-       \global\divide\moodle at pointspercorrect by \c at moodle@numcorrectanswers\relax
-       \edef\moodle at autopoints{\strip at pt\moodle at pointspercorrect}%
+       \ifdim0pt<\moodle at pointspercorrect\relax\else%
+         % we have starred items so the sum of user-set positive fractions must be less than 100%
+         % otherwise, starred items would lead to penalties
+         \PackageError{moodle}{Positive fractions sum up to 100 or more (here: \ds):
+                                there is no positive points left to be given to starred items.}%
+       \fi
+       \global\divide\moodle at pointspercorrect by \c at moodle@numcorrectanswers\relax%
      \fi
+     \gdef\moodle at autopoints{\strip at pt\moodle at pointspercorrect}%
+     \global\advance\moodle at pointsperincorrect by-\moodle at sumofnegativefractions\relax%
+     \def\ds{\strip at pt\moodle at sumofnegativefractions}%
+     \ifnum0=\c at moodle@numincorrectanswers\relax%
+       % autosanctions will never be used and
+       % we do not care about the sum of negative fractions (might be less than -100)
+     \else
+       \ifdim0pt<\moodle at pointsperincorrect\relax%
+         % we have items without fractions set: to prevent auto sanctions from becoming bonuses,
+         % such items are neutralized.
+         \PackageWarning{moodle}{Negative fractions sum up to -100 or less (here: \ds):
+                                  items with no fraction key set will be considered as neutral.}%
+         \global\setlength{\moodle at pointsperincorrect}{0pt}%
+       \fi
+       \global\divide\moodle at pointsperincorrect by \c at moodle@numincorrectanswers\relax%
+     \fi
+     \gdef\moodle at autosanctions{\strip at pt\moodle at pointsperincorrect}%
    }
    \def\moodle at countcorrectanswers@a#1{%
      %The grouping is to keep key answer-specific key changes local.
@@ -1729,8 +3108,11 @@
      \egroup
    }%
    \newcommand\moodle at countcorrectanswers@b[1][]{%
-     \setkeys{moodle}{fraction=0,#1}%
-     \moodle at countcorrectanswers@c%
+     %\ifx&#1&%
+       \let\moodle at fraction\@empty%
+       \setkeys{moodle}{#1}%
+       \moodle at countcorrectanswers@c%
+     %\fi
    }%
    \def\moodle at countcorrectanswers@c#1#2\moodle at answer@rdelim{%
      \def\test at i{#1}%
@@ -1737,26 +3119,68 @@
      \ifx\test at i\@star
        \stepcounter{moodle at numcorrectanswers}%
      \else
-       \global\addtolength{\moodle at pointspercorrect}{-\moodle at fraction pt}%
+       \ifx\moodle at fraction\@empty\relax%
+         \stepcounter{moodle at numincorrectanswers}%
+       \else
+         \ifdim0pt<\moodle at fraction pt\relax%
+           \global\addtolength{\moodle at sumofpositivefractions}{\moodle at fraction pt}%
+         \else
+           \global\addtolength{\moodle at sumofnegativefractions}{\moodle at fraction pt}%
+         \fi
+       \fi
      \fi
    }%
-   \def\moodle at setautopoints#1pt{%
-     \gdef\moodle at autopoints{#1}%
+   \newlength{\test at fraction}%
+   \newlength{\test at lower}%
+   \newlength{\test at upper}%
+   \def\moodle at fractionerror{%
+     \def\ds{\moodle at fraction}%
+     \PackageError{moodle}{the current fraction is not a valid value (here: \ds)}%
    }
-
-% TODO: What if rounding errors make the percentages not add to 100%?  Will Moodle complain?
-% TODO: Verify that negative scores are handled correctly.
+   {\catcode`|=3\relax
+   \gdef\moodle at validfractionlist{0|5|10|11.11111|12.5|14.28571|16.66667|20|25|30|33.33333|40|50|60|66.66667|70|75|80|83.33333|90|100}}%
+   \def\moodle at isfractionnear#1{%
+     \setlength{\test at lower}{#1 pt}%
+     \addtolength{\test at lower}{-\moodle at fractiontol pt}%
+     \setlength{\test at upper}{#1 pt}%
+     \addtolength{\test at upper}{\moodle at fractiontol pt}%
+     \ifdim\test at upper>\test at fraction\relax
+       \ifdim\test at lower<\test at fraction\relax
+         \gdef\test at fractionmatched{#1}%
+       \fi
+     \fi
+   }
+   \def\moodle at checkfraction{%
+     %\def\test at i{#1}%
+     \setlength{\test at fraction}{\moodle at fraction pt}%
+     % take the absolute value
+     \ifdim0pt>\test at fraction\relax%
+       \setlength{\test at fraction}{-\moodle at fraction pt}%
+     \fi
+     % test if the fraction is an admissible value
+     \let\test at fractionmatched\@empty
+     \forlistloop{\moodle at isfractionnear}{\moodle at validfractionlist}%
+     \ifx\test at fractionmatched\@empty\relax
+       \moodle at fractionerror%
+     \fi
+     \ifdim\moodle at fraction pt<-\moodle at fractiontol pt\relax%
+       \setkeys{moodle}{fraction=-\test at fractionmatched}%
+     \else
+       \setkeys{moodle}{fraction=\test at fractionmatched}%
+     \fi
+   }
 % TODO: Put these macros in same order as other sections'.
 
 % SAVING ANSWERS TO MEMORY
 \def\savemultianswer#1{%
   \bgroup
-    \savemultianswer at int#1\moodle at answer@rdelim
+    \savemultianswer at int#1 \moodle at answer@rdelim
     \passvalueaftergroup{\moodle at answers@xml}%
   \egroup
 }%
   \newcommand\savemultianswer at int[1][]{%
-    \setkeys{moodle}{fraction=0,#1}%
+    \let\moodle at fraction\@empty%
+    \setkeys{moodle}{#1}%
     \savemultianswer at int@int%
   }%
   \def\savemultianswer at int@int#1#2\moodle at answer@rdelim{%
@@ -1771,12 +3195,23 @@
     \else
       \def\moodle at answertext{#1#2}%
     \fi
+    \ifx\moodle at fraction\@empty\relax%
+      \ifmoodle at single\relax
+        \setkeys{moodle}{fraction=0}%
+      \else% multiple
+        \setkeys{moodle}{fraction=\moodle at autosanctions}%
+      \fi
+    \fi
     \trim at spaces@in\moodle at answertext
+    \trim at spaces@in\moodle at answertext
+    \moodle at checkfraction
     \addto at xml[2]{\moodle at answers@xml}{<answer fraction="\moodle at fraction" format="html">}%
     \xa\converttohtmlmacro\xa\moodle at answertext@html\xa{\moodle at answertext}%
     \addto at xml[4]{\moodle at answers@xml}{  <text><![CDATA[<p>\moodle at answertext@html</p>]]></text>}%
     \ifx\moodle at feedback\@empty\relax\else
-      \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback</p>]]></text></feedback>}%
+      \trim at spaces@in\moodle at feedback
+      \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{\moodle at feedback}%
+      \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback@html</p>]]></text></feedback>}%
     \fi
     \addto at xml[2]{\moodle at answers@xml}{</answer>}%
   }%
@@ -1788,50 +3223,351 @@
     \moodle at writesingle%
     \moodle at writeshuffle%
     \moodle at writeanswernumbering%
-    \moodle at writeanswers%
-  \writetomoodle{</question>}%
 }%
 %    \end{macrocode}
 %
-% \subsubsection{Matching Question Front-End}
+% \subsubsection{True/False Question Front-End}
 % 
 %    \begin{macrocode}
-\let\answer=\hfill
+% True/False has structure
+% \begin{truefalse}[options]{name}%
+%   This is a matching question.
+%   \item[feedback={feedback for student answering incorrectly "true"}] % first item is for true
+%   \item* this is an other way of specifying answer-specific feedback
+% \end{truefalse}%
 
-\moodle at makefrontend{matching}
+%\moodle at makefrontend{truefalse}{}% We dont use the generic frontend because truefalse has no tunable penalty
 
+\NewEnviron{truefalse}[2][]{%
+    \bgroup
+      \setkeys{moodle}{#1,questionname={#2}}%
+      \expandafter\gatheritems\xa{\BODY}%
+      \let\moodle at questionheader=\gatheredheader
+      %First, the LaTeX processing
+      \item \textbf{\moodle at questionname}
+      \ifmoodle at handout
+        \moodle at makelatextag@qtype{truefalse}
+      \else
+        \xa\xdef\xa\test at iii\xa{\moodle at tags}%
+        \ifx\test at iii\@moodle at empty\relax\else
+          \hfill tags: \texttt{\moodle at tags}
+        \fi
+        \par
+        \noindent
+        \moodle at makelatextag@qtype{truefalse}
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+      \fi
+      \par
+      \noindent
+      \moodle at questionheader
+      \edef\moodle at generalfeedback{\expandonce\moodle at feedback}
+      \moodle at truefalse@latexprocessing
+      %Now, writing information to XML
+      \@moodle at ifgeneratexml{%
+        \setkeys{moodle}{penalty=1}%
+        \xa\questiontext\xa{\moodle at questionheader}% Save the question text.
+        \csname writetruefalsequestion\endcsname
+        \bgroup
+          \gdef\moodle at answers@xml{}%
+          \setkeys{moodle}{feedback={}}%
+          \xa\loopthroughitemswithcommand\xa{\xa\savetruefalseanswer}%
+          \ifnum\c at numgathereditems=1\relax%
+            \setcounter{currentitemnumber}{2}%
+            \savetruefalseanswer{}
+          \fi
+          \passvalueaftergroup{\moodle at answers@xml}%
+        \egroup
+        \moodle at writeanswers%
+        \moodle at writetags%
+        \writetomoodle{</question>}%
+      }{}%
+    \egroup
+  }%
+
 % LATEX PROCESSING
-\def\moodle at matching@latexprocessing{%
+
+\def\moodle at truefalse@latexprocessing{%
+%  \ifnum\c at numgathereditems>2\relax%
+%    \PackageError{moodle}{Expecting at max two answers with truefalse type}
+%  \fi
+  \setcounter{moodle at numcorrectanswers}{0}%
+  \begin{itemize} \setlength\itemsep{0pt}\setlength\parskip{0pt}%
+    \loopthroughitemswithcommand{\moodle at print@truefalse at answer}%
+    \ifnum\c at currentitemnumber=2%
+      \item \textbf{False}%
+    \fi
+  \end{itemize}
+  \ifmoodle at handout\else
+    \ifx\moodle at generalfeedback\@empty\relax\else%
+      \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+    \fi
+  \fi
+  \ifnum\c at moodle@numcorrectanswers=0\relax%
+    \PackageError{moodle}{No answer is explicitly marked as correct (*). Be sure one answer leads to points.}%
+  \fi
+  \ifnum\c at moodle@numcorrectanswers>1\relax%
+    \PackageError{moodle}{Two answers are explicitly marked as correct (*). Be sure only one answer leads to points.}%
+  \fi
+}
+
+   \def\moodle at print@truefalse at answer#1{% here # is all what comes after "\item", that is "[options]* text"
+       \let\moodle at feedback=\@empty
+       \moodle at print@truefalse at answer@int#1\@rdelim % add an end delimiter:
+   }%
+   \newcommand\moodle at print@truefalse at answer@int[1][]{% with the optional argument, catch options and set them as keys
+     \setkeys{moodle}{#1}%
+     \moodle at print@truefalse at answer@int at int% applies to the rest: "* text\@rdelim"
+   }%
+   \def\moodle at print@truefalse at answer@int at int#1\@rdelim{% this is just to treat appart the case where nothing follows
+     \def\test at i{#1}
+     \trim at spaces@in\test at i
+     \ifx\test at i\@empty\relax
+       \moodle at print@truefalse at answer@int at int@empty
+     \else
+       \moodle at print@truefalse at answer@int at int@int#1\@rdelim
+     \fi
+   }%
+   \def\moodle at print@truefalse at answer@int at int@empty{%
+     \ifnum\c at currentitemnumber=1%
+	\def\moodle at answertext{True}%
+     \fi
+     \ifnum\c at currentitemnumber=2%
+	\def\moodle at answertext{False}%
+     \fi
+     \item \textbf{\moodle at answertext}%
+     \ifmoodle at handout\else
+       \ifx\moodle at feedback\@empty\relax\else
+         ~\hfill \emph{$\rightarrow$ \moodle at feedback}%
+       \fi
+     \fi
+   }%
+   \def\moodle at print@truefalse at answer@int at int@int#1#2\@rdelim{%
+     \ifnum\c at currentitemnumber=1%
+	\def\moodle at answertext{True}%
+     \fi
+     \ifnum\c at currentitemnumber=2%
+	\def\moodle at answertext{False}%
+     \fi
+     \item \textbf{\moodle at answertext}%
+     \ifnum\c at currentitemnumber<3%
+       \def\test at i{#1}%
+       %\trim at spaces@in\test at i
+       \ifx\test at i\@star
+         \ifmoodle at handout\else
+           ~$\checkmark$%
+         \fi
+         \stepcounter{moodle at numcorrectanswers}%
+       \else
+         ~%
+       \fi
+       \ifmoodle at handout\else
+         \ifx\moodle at feedback\@empty\relax
+           \def\test at ii{#2}%
+           \trim at spaces@in\test at ii
+           \ifx\test at ii\@empty\relax\else
+             \ifx\test at i\@star%
+               \hfill \emph{$\rightarrow$ #2}%
+             \else%
+               \hfill \emph{$\rightarrow$ #1#2}%
+             \fi
+           \fi
+         \else
+           \hfill \emph{$\rightarrow$ \moodle at feedback}%
+         \fi
+       \fi
+     \fi
+   }%
+
+% SAVING ANSWERS TO MEMORY
+\def\savetruefalseanswer#1{%
   \bgroup
-    \let\answer=\hfill
-    \begin{enumerate}\renewcommand{\theenumi}{\alph{enumi}}\setlength\itemsep{0pt}\setlength\parskip{0pt}%
-      \loopthroughitemswithcommand{\moodle at print@matching at answer}%
-    \end{enumerate}%
+    \savetruefalseanswer at int#1\moodle at answer@rdelim
+    \passvalueaftergroup{\moodle at answers@xml}%
   \egroup
-}
-   \long\def\moodle at print@matching at answer#1{%
-     \moodle at print@matching at answer@int#1\@rdelim
+}%
+   \newcommand\savetruefalseanswer at int[1][]{%
+     \setkeys{moodle}{#1}%
+     \savetruefalseanswer at int@int%
    }%
-   \newcommand\moodle at print@matching at answer@int[1][]{%
-     \moodle at print@matching at answer@int at int\relax
+   \def\savetruefalseanswer at int@int#1\moodle at answer@rdelim{%
+     \def\test at i{#1}
+     \trim at spaces@in\test at i
+     \ifx\test at i\@empty\relax
+       \savetruefalseanswer at int@int at empty
+     \else
+       \savetruefalseanswer at int@int at int#1\moodle at answer@rdelim
+     \fi
    }%
-   \long\def\moodle at print@matching at answer@int at int#1\answer#2\@rdelim{%
-       \item #1\hfill #2%
+   \def\savetruefalseanswer at int@int at empty{%
+     \setkeys{moodle}{fraction=0}%
+     \ifnum\c at currentitemnumber=1%
+	\def\moodle at answertext{true}%
+     \fi
+     \ifnum\c at currentitemnumber=2%
+	\def\moodle at answertext{false}%
+     \fi
+     \ifnum\c at currentitemnumber<3%
+       \addto at xml[2]{\moodle at answers@xml}{<answer fraction="\moodle at fraction" format="plain_text">}%
+       \addto at xml[4]{\moodle at answers@xml}{  <text>\moodle at answertext</text>}%
+       \ifx\moodle at feedback\@empty\relax\else
+         \trim at spaces@in\moodle at feedback
+         \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{\moodle at feedback}%
+         \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback@html</p>]]></text></feedback>}%
+       \fi
+       \addto at xml[2]{\moodle at answers@xml}{</answer>}%
+     \fi
    }%
+   \def\savetruefalseanswer at int@int at int#1#2\moodle at answer@rdelim{%
+     \def\test at i{#1}%
+     \ifx\test at i\@star
+       \setkeys{moodle}{fraction=100}%
+     \else
+       \setkeys{moodle}{fraction=0}%
+     \fi
+     \ifnum\c at currentitemnumber=1%
+	\def\moodle at answertext{true}%
+     \fi
+     \ifnum\c at currentitemnumber=2%
+	\def\moodle at answertext{false}%
+     \fi
+     \ifnum\c at currentitemnumber<3%
+       \addto at xml[2]{\moodle at answers@xml}{<answer fraction="\moodle at fraction" format="plain_text">}%
+       \addto at xml[4]{\moodle at answers@xml}{  <text>\moodle at answertext</text>}%
+       \ifx\moodle at feedback\@empty\relax
+         \def\test at ii{#2}
+         \ifx\test at ii\@empty\relax\else
+           \ifx\test at i\@star
+             \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{#2}%
+           \else%
+             \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{#1#2}%
+           \fi%
+           \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback@html</p>]]></text></feedback>}%
+         \fi
+       \else
+         \trim at spaces@in\moodle at feedback
+         \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{\moodle at feedback}%
+         \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback@html</p>]]></text></feedback>}%
+       \fi
+       \addto at xml[2]{\moodle at answers@xml}{</answer>}%
+     \fi
+   }%
 
+% WRITING QUESTION TO XML FILE
+\gdef\writetruefalsequestion{%
+  \writetomoodle{<question type="truefalse">}%
+    \moodle at writecommondata%
+}%
+%    \end{macrocode}
+%
+% \subsubsection{Matching Question Front-End}
+% 
+%    \begin{macrocode}
+%\let\answer=\hfill
 
+\moodle at makefrontend{matching}{\moodle at makelatextag@matching}%
+
+% LATEX PROCESSING
+
+\def\moodle at makelatextag@matching{%
+  \ifmoodle at handout\else
+    \ifmoodle at draganddrop
+      \moodle at makelatextagbox{Drag and drop}\relax%
+    \fi
+    \ifmoodle at shuffle
+      \moodle at makelatextagbox{Shuffle}\relax%
+    \fi
+  \fi
+}
+
+\def\moodle at matching@latexprocessing{%
+  \bgroup
+    %\let\answer=\hfill
+    \par%\noindent
+    \ifmoodle at handout
+      \NewList{questionlist}
+      \NewList{answerlist}
+    \fi
+    \def\matching at table@text{}%
+    %  \ifnum\c at numgathereditems>2\relax%
+%    \PackageError{moodle}{Expecting at max two answers with truefalse type}
+%  \fi
+    \setcounter{moodle at numcorrectanswers}{0}% Here this counter is for "questions" (items on the left column)
+    \loopthroughitemswithcommand{\moodle at print@matching at answer}%
+    \ifnum\c at numgathereditems<3%
+      \PackageWarning{moodle}{Moodle expects at least three "answers" with matching type}
+    \fi
+    \ifnum\c at moodle@numcorrectanswers<2%
+      \PackageWarning{moodle}{Moodle expects at least two "questions" with the matching type}
+    \fi
+    \ifmoodle at handout
+      \ifmoodle at shuffle
+        \let\moodle at matching@loop=\ForEachRandomItem
+      \else
+        \let\moodle at matching@loop=\ForEachFirstItem
+      \fi
+      \moodle at matching@loop{questionlist}{Question}{
+        \xdef\test at i{\Question}%
+        \ExtractRandomItem{answerlist}{Answer}%
+        \ifx\test at i\@empty
+          \xdef\matching at table@text{\expandonce\matching at table@text & & $\bullet$~\expandonce\Answer\\}%
+        \else
+          \xdef\matching at table@text{\expandonce\matching at table@text\expandonce\Question~$\bullet$ & & $\bullet$~\expandonce\Answer\\}%
+        \fi
+      }%
+    \fi
+    \begin{tabular}{@{}>{\raggedleft}p{.45\linewidth}p{.1\linewidth}p{.45\linewidth}@{}}%
+      \matching at table@text
+    \end{tabular}%
+    \par
+    \ifmoodle at handout\else
+      \ifx\moodle at generalfeedback\@empty\relax\else%
+        \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+      \fi
+    \fi
+  \egroup
+}
+
+\long\def\moodle at print@matching at answer#1{%
+  \moodle at print@matching at answer@int#1 \@rdelim
+}%
+\newcommand\moodle at print@matching at answer@int[1][]{%
+  \moodle at print@matching at answer@int at int
+}%
+\long\def\moodle at print@matching at answer@int at int#1\answer#2\@rdelim{%
+  %\typeout{\string#1 \answer \string#2}%
+  \def\test at i{#1}%
+  \trim at spaces@in\test at i
+  \ifmoodle at handout
+    \ifx\test at i\@empty
+      \InsertLastItem{questionlist}{\@empty}%
+    \else
+      \InsertLastItem{questionlist}{#1}%
+    \fi
+    \InsertLastItem{answerlist}{#2}%
+  \else
+    \ifx\test at i\@empty
+      \g at addto@macro\matching at table@text{&&$\bullet$~#2\\}%
+    \else
+      \stepcounter{moodle at numcorrectanswers}%
+      \xa\g at addto@macro\xa\matching at table@text\xa{\test at i~$\bullet$&\leavevmode\cleaders\hb at xt@.44em{\hss$\cdot$\hss}\hfill\kern\z@&$\bullet$~#2\\}%
+    \fi
+  \fi
+}%
+
+
 % SAVING ANSWERS TO MEMORY
 \long\def\savematchinganswer#1{%
   \bgroup
-    \savematchinganswer at int#1\moodle at answer@rdelim%
+    \savematchinganswer at int#1 \moodle at answer@rdelim%
     \passvalueaftergroup{\moodle at answers@xml}%
   \egroup
 }%
    \newcommand\savematchinganswer at int[1][]{%
      \setkeys{moodle}{#1}%
-     \xa\savematchinganswer at int@int\space%
+     \savematchinganswer at int@int%\space
    }%
    \long\def\savematchinganswer at int@int#1\answer#2\moodle at answer@rdelim{%
+     %\typeout{\string#1 \answer \string#2}%
      % Note that #1 may simply be \relax.
      \def\moodle at subquestiontext{#1}%
      \def\moodle at subanswertext{#2}%
@@ -1854,9 +3590,12 @@
 %       \show\moodle at subanswertext
        \addto at xml[4]{\moodle at answers@xml}{  <answer><text>\moodle at subanswertext</text></answer>}%
      \fi
-     \ifx\moodle at feedback\@empty\relax\else
-       \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback</p>]]></text></feedback>}%
-     \fi
+%     \ifx\moodle at feedback\@empty\relax\else
+%       \trim at spaces@in\moodle at feedback
+%       \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{\moodle at feedback}%
+%       \addto at xml[4]{\moodle at answers@xml}{  <feedback 
+%format="html"><text><![CDATA[<p>\moodle at feedback@html</p>]]></text></feedback>}%
+%     \fi
      \addto at xml[2]{\moodle at answers@xml}{</subquestion>}%
    }%
 
@@ -1868,12 +3607,9 @@
     \writetomoodle{<question type="matching">}%
   \fi
     \moodle at writecommondata%
-    \moodle at writesingle%
+%    \moodle at writesingle% %irrelevant for the matching type
     \moodle at writeshuffle%
-    \moodle at writeanswernumbering%
-    \moodle at writeanswers%
-  \writetomoodle{</question>}%
-%  \gdef\moodle at answ
+%    \moodle at writeanswernumbering% %irrelevant for the matching type
 }%
 %    \end{macrocode}
 %
@@ -1896,6 +3632,8 @@
 % LATEX PROCESSING
 % SAVING ANSWERS TO MEMORY
 
+\newif\ifmoodle at clozemode
+\moodle at clozemodefalse
 \NewEnviron{cloze}[2][]{%
   \bgroup
     \setkeys{moodle}{default grade=1}%
@@ -1903,9 +3641,30 @@
     % A cloze question won't have any \item's in it, so we just use \BODY.
     \moodle at enableclozeenvironments
     %First, the LaTeX processing.
-      \item \textbf{\moodle at questionname}\par
+      \item \textbf{\moodle at questionname}
+      \ifmoodle at handout
+        \moodle at makelatextag@qtype{cloze}
+      \else
+        \xa\xdef\xa\test at iii\xa{\moodle at tags}%
+        \ifx\test at iii\@moodle at empty\relax\else
+          \hfill tags: \texttt{\moodle at tags}
+        \fi
+        \par
+        \noindent
+        \moodle at makelatextag@qtype{cloze}
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+        \moodle at makelatextag@value{penalty}{penalty}
+      \fi
+      \par
       \noindent
       \BODY
+      \edef\moodle at generalfeedback{\expandonce\moodle at feedback}
+      %\csname moodle at cloze@latexprocessing\endcsname
+      \ifmoodle at handout\else
+        \ifx\moodle at generalfeedback\@empty\relax\else%
+          \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+        \fi
+      \fi
     %Now, writing information to memory.
     \@moodle at ifgeneratexml{%
       \xa\questiontext\xa{\BODY}% Save the question text as HTML.
@@ -1927,6 +3686,7 @@
 \gdef\writeclozequestion{%
   \writetomoodle{<question type="cloze">}%
     \moodle at writecommondata%
+    \moodle at writetags%
   \writetomoodle{</question>}%
 }%
 %    \end{macrocode}
@@ -1934,7 +3694,6 @@
 % \subsubsection{Cloze Multiple Choice Questions}
 % 
 %    \begin{macrocode}
-% TODO: Guard against [single=false] option
 
 \NewEnviron{clozemulti}[1][]{%
   \bgroup
@@ -1947,40 +3706,88 @@
       \def\moodle at clozemulti@output{}%
       \xa\g at addto@macro\xa\moodle at clozemulti@output\xa{\moodle at questionheader}%
       \def\clozemulti at coding{}%
-      \edef\clozemulti at coding{\otherlbrace\csname moodle at default grade\endcsname:}%
+      \edef\clozemulti at coding{\csname moodle at default grade\endcsname:}%
+      \ifmoodle at multiple
+        \PackageWarning{moodle}{Cloze Multiresponse only supported by Moodle 3.5+}
+        \g at addto@macro{\clozemulti at coding}{MULTIRESPONSE}%
+      \else
+        \g at addto@macro{\clozemulti at coding}{MULTICHOICE}%
+      \fi
       \ifcase\moodle at multi@mode\relax
-        % Case 0: dropdown box style
-        \g at addto@macro{\clozemulti at coding}{MULTICHOICE:}%
+         % Case 0: dropdown box style
+         \ifmoodle at shuffle
+           \g at addto@macro{\clozemulti at coding}{_}%
+         \fi
       \or
         % Case 1: vertical style
-        \g at addto@macro{\clozemulti at coding}{MULTICHOICE_V:}%
+        \ifmoodle at multiple
+          \PackageError{moodle}{Vertical mode (dropdown box) incompatible with multiresponse.}
+        \else
+          \g at addto@macro{\clozemulti at coding}{_V}%
+        \fi
       \else
         % Case 2: horizontal radio buttons
-        \g at addto@macro{\clozemulti at coding}{MULTICHOICE_H:}%
+        \g at addto@macro{\clozemulti at coding}{_H}%
       \fi
+      \ifmoodle at shuffle
+        \PackageWarning{moodle}{Cloze Multi Shuffling only supported by Moodle 3.0+}
+        \g at addto@macro{\clozemulti at coding}{S:}%
+      \else
+        \g at addto@macro{\clozemulti at coding}{:}%
+      \fi
       \bgroup
         \setkeys{moodle}{feedback={}}%
         \loopthroughitemswithcommand{\saveclozemultichoiceanswer}%
       \egroup
-      \xa\g at addto@macro\xa\clozemulti at coding\xa{\otherrbrace}%
-      \xa\g at addto@macro\xa\moodle at clozemulti@output\xa{\clozemulti at coding}%
+      %\xa\g at addto@macro\xa\clozemulti at coding\xa{\clozerbrace}%
+      \xa\g at addto@macro\xa\moodle at clozemulti@output\xa{\xa\clozelbrace\clozemulti at coding\clozerbrace}%
+      %\show\moodle at clozemulti@output
       \xa\gdef\xa\htmlize at afteraction@hook\xa{\moodle at clozemulti@output}%
       \def\endclozemulti at code{\htmlize at patchendenvironment}%
     \else
       %LaTeX version
       \moodle at questionheader% %Any introductory text just continues to be typeset.
+      \par
+      \noindent
+      \moodle at makelatextag@qtype{multi}
+      \ifmoodle at handout\else
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+        \moodle at makelatextag@multi
+      \fi
       \def\cloze at multichoice@table at text{}%
+      \ifmoodle at handout\NewList{answerlist}\fi
+      %\let\moodle at feedback=\@empty
       \loopthroughitemswithcommand{\moodle at print@clozemultichoice at answer}%
+      \ifmoodle at handout
+        \ifmoodle at shuffle
+          \let\moodle at clozemult@loop=\ForEachRandomItem
+        \else
+          \let\moodle at clozemult@loop=\ForEachFirstItem
+        \fi
+        \moodle at clozemult@loop{answerlist}{Answer}{
+          \xdef\cloze at multichoice@table at text{\expandonce\cloze at multichoice@table at text\expandonce\Answer}%
+        }%
+      \fi
       \ifcase\moodle at multi@mode\relax
         %Case 0: dropdown box style
-        \begin{tabular}[t]{|l|}\firsthline% (\firsthline is from the array package.)
+        \par\noindent
+        \ifmoodle at handout
+          \begin{tabular}[t]{|p{.45\linewidth}|}
+        \else 
+          \begin{tabular}[t]{|p{.45\linewidth}|p{.45\linewidth}|}
+%          answer & feedback \\\hline\hline
+        \fi
+          \firsthline% (\firsthline is from the array package.)
           \cloze at multichoice@table at text%
         \end{tabular}%
+        \par%
       \or
         %Case 1: vertical style
+        \par\noindent
         \begin{itemize}\setlength\itemsep{0pt}\setlength\parskip{0pt}%
           \cloze at multichoice@table at text%
         \end{itemize}%
+        \par%
       \else
         %Case 2: horizontal radio buttons
         \par{\cloze at multichoice@table at text}\par%
@@ -1994,12 +3801,15 @@
 
 
 \def\moodle at print@clozemultichoice at answer#1{%
-  \moodle at print@clozemultichoice at answer@int#1\@rdelim%
+  \let\moodle at feedback=\@empty
+  \moodle at print@clozemultichoice at answer@int#1 \@rdelim%
 }%
 \newcommand\moodle at print@clozemultichoice at answer@int[1][]{%
+  \setkeys{moodle}{fraction=0,#1}%
   \moodle at print@clozemultichoice at answer@int at int%
 }%
 \def\moodle at print@clozemultichoice at answer@int at int#1#2\@rdelim{%
+  \def\moodle at answertext{}%
   % Case 0: "(answer) \\ \hline"
   % Case 1: "\item (answer)"
   % Case 2: "$\bullet~$(answer)\hfill"
@@ -2006,28 +3816,60 @@
   \ifcase\moodle at multi@mode\relax
     \relax% Case 0
   \or
-    \g at addto@macro\cloze at multichoice@table at text{\item}% Case 1
+    \g at addto@macro\moodle at answertext{\item}% Case 1
   \else
-    \g at addto@macro\cloze at multichoice@table at text{$\bullet~$}% Case 2
+    \g at addto@macro\moodle at answertext{$\bullet~$}% Case 2
   \fi
   \def\test at i{#1}%
   \ifx\test at i\@star
-     \g at addto@macro\cloze at multichoice@table at text{#2$~\checkmark$}%
+    \setkeys{moodle}{fraction=100}%
+    \g at addto@macro\moodle at answertext{#2}%
   \else
-     \g at addto@macro\cloze at multichoice@table at text{#1#2}%
+    \g at addto@macro\moodle at answertext{#1#2}%
   \fi
+  \trim at spaces@in\moodle at answertext
+  \trim at spaces@in\moodle at answertext
+  \ifmoodle at handout\else
+    \ifx\moodle at fraction\@hundred
+      \g at addto@macro\moodle at answertext{$~\checkmark$}%
+    \else
+      \moodle at checkfraction
+      \ifdim0pt=\moodle at fraction pt\relax\else
+        \xdef\moodle at answertext{\expandonce\moodle at answertext$~(\moodle at fraction\%)$}%
+      \fi
+    \fi
+  \fi
   \ifcase\moodle at multi@mode\relax
-    \g at addto@macro{\cloze at multichoice@table at text}{\\ \hline}% Case 0
-  \or
-    \relax% Case 1
+  % Case 0
+    \ifmoodle at handout\else
+      \xdef\moodle at answertext{\expandonce\moodle at answertext &\expandonce\emph{\expandonce\moodle at feedback}}%
+    \fi
+    \g at addto@macro\moodle at answertext{\\\hline}
+  \or % Case 1
+    \ifmoodle at handout\else
+      \ifx\moodle at feedback\@empty\relax\else
+        \xdef\moodle at answertext{\expandonce\moodle at answertext \hfill \expandonce\emph{$\rightarrow$ \expandonce\moodle at feedback}}%
+      \fi
+    \fi
+  \else % otherwise
+    \ifmoodle at handout\else
+      \ifx\moodle at feedback\@empty\relax\else
+        \xdef\moodle at answertext{\expandonce\moodle at answertext\,\expandonce\emph{$\rightarrow$ \expandonce\moodle at feedback}}%
+      \fi
+    \fi
+    \g at addto@macro\moodle at answertext{\hfill}% Case 2
+  \fi
+  \ifmoodle at handout
+    \def\temp{\InsertLastItem{answerlist}}%
+    \xa\temp\xa{\moodle at answertext}%
   \else
-    \g at addto@macro{\cloze at multichoice@table at text}{\hfill}% Case 2
+    \xdef\cloze at multichoice@table at text{\expandonce\cloze at multichoice@table at text\expandonce\moodle at answertext}%
   \fi
 }%
 
 \def\saveclozemultichoiceanswer#1{%
   \bgroup
-    \saveclozemultichoiceanswer at int#1\moodle at answer@rdelim
+    \saveclozemultichoiceanswer at int#1 \moodle at answer@rdelim
   \egroup
 }%
 \newcommand\saveclozemultichoiceanswer at int[1][]{%
@@ -2046,17 +3888,18 @@
     \def\moodle at answertext{#1#2}%
   \fi
   \trim at spaces@in\moodle at answertext
+  \trim at spaces@in\moodle at answertext
   \ifx\moodle at fraction\@hundred
     \g at addto@macro\clozemulti at coding{=}%
-  \fi
-  \ifnum0<\moodle at fraction\relax
-    \ifnum\moodle at fraction<100\relax
+  \else
+    \moodle at checkfraction
+    \ifdim0pt=\moodle at fraction pt\relax\else
       \xdef\clozemulti at coding{\expandonce\clozemulti at coding\otherpercent\moodle at fraction\otherpercent}%
     \fi
   \fi
   \xdef\clozemulti at coding{\expandonce\clozemulti at coding\expandonce\moodle at answertext}%
   \ifx\moodle at feedback\@empty\else
-    \xdef\clozemulti at coding{\expandonce\clozemulti at coding\otherbackslash\otherhash\moodle at feedback}%
+    \xdef\clozemulti at coding{\expandonce\clozemulti at coding\otherbackslash\otherhash\expandonce\moodle at feedback}%
   \fi
 }%
 %    \end{macrocode}
@@ -2075,23 +3918,35 @@
       \def\moodle at clozenumerical@output{}%
       \xa\g at addto@macro\xa\moodle at clozenumerical@output\xa{\moodle at questionheader}%
       \def\clozenumerical at coding{}%
-      \edef\clozenumerical at coding{\otherlbrace\csname moodle at default grade\endcsname:NUMERICAL:}%
+      \edef\clozenumerical at coding{\csname moodle at default grade\endcsname:NUMERICAL:}%
       \bgroup
         \setkeys{moodle}{feedback={}}%
         \loopthroughitemswithcommand{\saveclozenumericalanswer}%
       \egroup
-      \xa\g at addto@macro\xa\clozenumerical at coding\xa{\otherrbrace}%
-      \xa\g at addto@macro\xa\moodle at clozenumerical@output\xa{\clozenumerical at coding}%
+      %\xa\g at addto@macro\xa\clozenumerical at coding\xa{\otherrbrace}%
+      \xa\g at addto@macro\xa\moodle at clozenumerical@output\xa{\xa\clozelbrace\clozenumerical at coding\clozerbrace}%
       \xa\gdef\xa\htmlize at afteraction@hook\xa{\moodle at clozenumerical@output}%
       \def\endclozenumerical at code{\htmlize at patchendenvironment}%
     \else
       %LaTeX version
       \moodle at questionheader% %Any introductory text just continues to be typeset.
-      \def\cloze at numerical@table at text{}%
-      \loopthroughitemswithcommand{\moodle at print@clozenumerical at answer}%
-      \begin{tabular}[t]{|ll|}\firsthline
-        \cloze at numerical@table at text\hline%
-      \end{tabular}%
+      \par
+      \noindent
+      \moodle at makelatextag@qtype{numerical}
+      \ifmoodle at handout\else
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+        \moodle at makelatextag@numerical
+        \par
+        \noindent
+        \def\cloze at numerical@table at text{}%
+        \loopthroughitemswithcommand{\moodle at print@clozenumerical at answer}%
+        \begin{tabular}[t]{|p{.45\linewidth}|p{.45\linewidth}|}
+          \firsthline% (\firsthline is from the array package.)
+%         answer & feedback \\\hline\hline
+          \cloze at numerical@table at text%
+        \end{tabular}%
+        \par%
+      \fi
       \def\endclozenumerical at code{\relax}%
     \fi
     \passvalueaftergroup\endclozenumerical at code%
@@ -2100,6 +3955,7 @@
 }[\endclozenumerical at code]%
 
 \def\moodle at print@clozenumerical at answer#1{%
+  \let\moodle at feedback=\@empty
   \bgroup
     \moodle at print@clozenumerical at answer@int#1\@rdelim
   \egroup
@@ -2110,17 +3966,23 @@
 }%
 \def\moodle at print@clozenumerical at answer@int at int#1\@rdelim{%
   \ifx\moodle at fraction\@hundred
-    \def\moodle at clozenumericalprint@fraction{$\checkmark$}%
+    \def\moodle at clozenumericalprint@fraction{$~\checkmark$}%
   \else
-    \edef\moodle at clozenumericalprint@fraction{(\moodle at fraction\%)}%
+    \moodle at checkfraction
+    \edef\moodle at clozenumericalprint@fraction{$(~\moodle at fraction\%)$}%
   \fi
-  \ifdim0pt=\moodle at tolerance pt\relax
+  \ifnum\z@=\moodle at tolerance
     \def\moodle at clozenumericalprint@tolerance{}%
   \else
-    \edef\moodle at clozenumericalprint@tolerance{\noexpand\pm\moodle at tolerance}%
+    \edef\moodle at clozenumericalprint@tolerance{$\,\pm\,$\moodle at printnum{\moodle at tolerance}}%
   \fi
-  \xdef\moodle at clozenumericalprint@line{$#1\moodle at clozenumericalprint@tolerance$ & \moodle at clozenumericalprint@fraction}%
-  \xa\g at addto@macro\xa\cloze at numerical@table at text\xa{\moodle at clozenumericalprint@line \\}%
+  \xdef\test at i{\trim at spaces{#1}}%
+  \ifx\test at i\@star
+    \xdef\moodle at clozenumericalprint@line{#1~\moodle at clozenumericalprint@fraction & \expandonce\emph{\expandonce\moodle at feedback}}%
+  \else
+    \xdef\moodle at clozenumericalprint@line{\moodle at printnum{#1}\moodle at clozenumericalprint@tolerance~\moodle at clozenumericalprint@fraction & \expandonce\emph{\expandonce\moodle at feedback}}%
+  \fi
+  \xa\g at addto@macro\xa\cloze at numerical@table at text\xa{\moodle at clozenumericalprint@line \\\hline}%
 }%
 
 
@@ -2142,15 +4004,20 @@
   \trim at spaces@in\moodle at answertext
   \ifx\moodle at fraction\@hundred
     \g at addto@macro\clozenumerical at coding{=}%
-  \fi
-  \ifnum0<\moodle at fraction\relax
-    \ifnum\moodle at fraction<100\relax
+  \else
+    \moodle at checkfraction
+    \ifdim0pt=\moodle at fraction pt\relax\else
       \xdef\clozenumerical at coding{\expandonce\clozenumerical at coding\otherpercent\moodle at fraction\otherpercent}%
     \fi
   \fi
-  \xdef\clozenumerical at coding{\expandonce\clozenumerical at coding\moodle at answertext:\moodle at tolerance}%
+  \ifx\moodle at answertext\@star
+    \xdef\clozenumerical at coding{\expandonce\clozenumerical at coding\moodle at answertext}%
+  \else
+    \xdef\clozenumerical at coding{\expandonce\clozenumerical at coding\moodle at answertext:\moodle at tolerance}%
+  \fi
   \ifx\moodle at feedback\@empty\else
-    \xdef\clozenumerical at coding{\expandonce\clozenumerical at coding\otherbackslash\otherhash\moodle at feedback}%
+    %\trim at spaces@in\moodle at feedback
+    \xdef\clozenumerical at coding{\expandonce\clozenumerical at coding\otherbackslash\otherhash\expandonce\moodle at feedback}%
   \fi
 }%
 %    \end{macrocode}
@@ -2177,29 +4044,38 @@
       \xa\g at addto@macro\xa\moodle at clozeshortanswer@output\xa{\moodle at questionheader}%
       \def\clozeshortanswer at coding{}%
       \ifnum\count0=1\relax
-        \edef\clozeshortanswer at coding{\otherlbrace\csname moodle at default grade\endcsname:SHORTANSWER_C:}%
+        \edef\clozeshortanswer at coding{\csname moodle at default grade\endcsname:SHORTANSWER_C:}%
       \else
-        \edef\clozeshortanswer at coding{\otherlbrace\csname moodle at default grade\endcsname:SHORTANSWER:}%
+        \edef\clozeshortanswer at coding{\csname moodle at default grade\endcsname:SHORTANSWER:}%
       \fi
       \bgroup
         \setkeys{moodle}{feedback={}}%
         \loopthroughitemswithcommand{\saveclozeshortansweranswer}%
       \egroup
-      \xa\g at addto@macro\xa\clozeshortanswer at coding\xa{\otherrbrace}%
-      \xa\g at addto@macro\xa\moodle at clozeshortanswer@output\xa{\clozeshortanswer at coding}%
+      %\xa\g at addto@macro\xa\clozeshortanswer at coding\xa{\otherrbrace}%
+      \xa\g at addto@macro\xa\moodle at clozeshortanswer@output\xa{\xa\clozelbrace\clozeshortanswer at coding\clozerbrace}%
       \xa\gdef\xa\htmlize at afteraction@hook\xa{\moodle at clozeshortanswer@output}%
       \def\endclozeshortanswer at code{\htmlize at patchendenvironment}%
     \else
       %LaTeX version
       \moodle at questionheader% %Any introductory text just continues to be typeset.
-      \def\cloze at shortanswer@table at text{}%
-      \loopthroughitemswithcommand{\moodle at print@clozeshortanswer at answer}%
-      \ifnum\count0=1\relax
-        \marginpar{\tiny\mbox{(Case-Sensitive)}}%
+      \par
+      \noindent
+      \moodle at makelatextag@qtype{shortanswer}
+      \ifmoodle at handout\else
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+        \moodle at makelatextag@shortanswer
+        \par
+        \noindent
+        \def\cloze at shortanswer@table at text{}%
+        \loopthroughitemswithcommand{\moodle at print@clozeshortanswer at answer}%
+        \begin{tabular}[t]{|p{.45\linewidth}|p{.45\linewidth}|}
+          \firsthline% (\firsthline is from the array package.)
+%         answer & feedback \\\hline\hline
+          \cloze at shortanswer@table at text%
+        \end{tabular}%
+        \par%
       \fi
-      \begin{tabular}[t]{|ll|}\firsthline
-        \cloze at shortanswer@table at text\hline%
-      \end{tabular}%
       \def\endclozeshortanswer at code{\relax}%
     \fi
     \passvalueaftergroup\endclozeshortanswer at code%
@@ -2208,6 +4084,7 @@
 }[\endclozeshortanswer at code]%
 
 \def\moodle at print@clozeshortanswer at answer#1{%
+  \let\moodle at feedback=\@empty
   \bgroup
     \moodle at print@clozeshortanswer at answer@int#1\@rdelim
   \egroup
@@ -2218,12 +4095,13 @@
 }%
 \def\moodle at print@clozeshortanswer at answer@int at int#1\@rdelim{%
   \ifx\moodle at fraction\@hundred
-    \def\moodle at clozeshortanswerprint@fraction{$\checkmark$}%
+    \def\moodle at clozeshortanswerprint@fraction{$~\checkmark$}%
   \else
-    \edef\moodle at clozeshortanswerprint@fraction{(\moodle at fraction\%)}%
+    \moodle at checkfraction
+    \edef\moodle at clozeshortanswerprint@fraction{$~(\moodle at fraction\%)$}%
   \fi
-  \xdef\moodle at clozeshortanswerprint@line{#1 & \moodle at clozeshortanswerprint@fraction}%
-  \xa\g at addto@macro\xa\cloze at shortanswer@table at text\xa{\moodle at clozeshortanswerprint@line \\}%
+  \xdef\moodle at clozeshortanswerprint@line{#1~\moodle at clozeshortanswerprint@fraction & \expandonce\emph{\expandonce\moodle at feedback}}%
+  \xa\g at addto@macro\xa\cloze at shortanswer@table at text\xa{\moodle at clozeshortanswerprint@line \\\hline}%
 }%
 
 
@@ -2245,15 +4123,15 @@
   \trim at spaces@in\moodle at answertext
   \ifx\moodle at fraction\@hundred
     \g at addto@macro\clozeshortanswer at coding{=}%
-  \fi
-  \ifnum0<\moodle at fraction\relax
-    \ifnum\moodle at fraction<100\relax
+  \else
+    \moodle at checkfraction
+    \ifdim0pt=\moodle at fraction pt\relax\else
       \xdef\clozeshortanswer at coding{\expandonce\clozeshortanswer at coding\otherpercent\moodle at fraction\otherpercent}%
     \fi
   \fi
   \xdef\clozeshortanswer at coding{\expandonce\clozeshortanswer at coding\moodle at answertext}%
   \ifx\moodle at feedback\@empty\else
-    \xdef\clozeshortanswer at coding{\expandonce\clozeshortanswer at coding\otherbackslash\otherhash\moodle at feedback}%
+    \xdef\clozeshortanswer at coding{\expandonce\clozeshortanswer at coding\otherbackslash\otherhash\expandonce\moodle at feedback}%
   \fi
 }%
 %    \end{macrocode}
@@ -2270,15 +4148,20 @@
  \catcode`\&=12\gdef\otherampersand{&}%
  \catcode`\^=12\gdef\othercaret{^}%
  \catcode`\$=12\gdef\otherdollar{$}%
- \catcode`\%=12\gdef\otherpercent{%}}%
+ \catcode`\%=12\gdef\otherpercent{%}
+ \catcode`\%=12\gdef\otherlbracket{[}
+ \catcode`\%=12\gdef\otherrbracket{]}}%
 {\catcode`\ =12\gdef\otherspace{ }}%
-{\tt\catcode`\|=0\catcode`\\=12\relax|gdef|otherbackslash{\}}%
+{\ttfamily\catcode`\|=0\catcode`\\=12\relax|gdef|otherbackslash{\}}%
 {\catcode`\[=1\catcode`\]=2\catcode`\{=12\catcode`\}=12%
- \gdef\otherlbrace[{]\gdef\otherrbrace[}]]
+ \gdef\otherlbrace[{]\gdef\otherrbrace[}]\gdef\clozelbrace[{]\gdef\clozerbrace[}]]%
 
-
 \edef\@otherlbrace{\otherlbrace}%
 \edef\@otherrbrace{\otherrbrace}%
+\edef\@otherlbracket{\otherlbracket}%
+\edef\@otherrbracket{\otherrbracket}%
+\edef\@clozelbrace{\clozelbrace}%
+\edef\@clozerbrace{\clozerbrace}%
 \edef\@otherdollar{\otherdollar}%
 \edef\@otherbackslash{\otherbackslash}%
 \edef\@othertilde{\othertilde}%
@@ -2381,9 +4264,16 @@
 %    \end{macrocode}
 %
 % \subsection{Level-Tracking}
+%
+% \subsubsection{TeX groups}
+% While parsing, we'll need to keep track of how deeply nested in \TeX\ groups we are.
+%    \begin{macrocode}
+\newcount\grouplevel
+%    \end{macrocode}
+%
+% \subsubsection{Math mode}
 % While parsing, we'll need to keep track of whether
-% we are in math mode (and how many levels deep the math mode might be nested),
-% and also how deeply nested in \TeX\ groups we are.
+% we are in math mode (and how many levels deep the math mode might be nested).
 %    \begin{macrocode}
 \newcount\moodle at mathmodedepth
 \moodle at mathmodedepth=0\relax
@@ -2393,12 +4283,15 @@
   \else
     #2%
   \fi
-}
+}%
+%    \end{macrocode}
+%
+% \subsubsection{Nested Lists}
+% While parsing, we'll need to keep track levels of nested list.
+%    \begin{macrocode}
+\newcount\moodle at listdepth
+\moodle at listdepth=0\relax
 
-\newcount\grouplevel
-
-\newif\ifhtmlizer at active
-\htmlizer at activefalse
 %    \end{macrocode}
 %
 % \subsection{Separation}
@@ -2436,6 +4329,8 @@
 % \subsection{Main Code: the HTMLizer}
 % 
 %    \begin{macrocode}
+\newif\ifhtmlizer at active
+\htmlizer at activefalse
 \newif\ifhtmlize at actioncs
 \newif\ifhtmlize at expandcs
 \newif\ifhtmlize at passcs
@@ -2456,7 +4351,7 @@
   \advance\grouplevel by 1\relax
   \bgroup
     \ultradetokenize at to@macro\htmlize at texttoscan{#1}%
-    \xa\htmlize at recursive@i\htmlize at texttoscan\@htmlize at stop\@htmlize at stop\@htmlize at stop\htmlize at rdelim@i
+    \xa\htmlize at recursive@i\htmlize at texttoscan\@htmlize at stop\@htmlize at stop\@htmlize at stop\htmlize at rdelim@i%
   \egroup
   \advance\grouplevel by -1\relax
 }%
@@ -2502,7 +4397,13 @@
         \gdef\htmlize at scrap{\converttohtml at int}%
         \xa\g at addto@macro\xa\htmlize at scrap\xa{\xa{\htmlize at blockinbraces}}%
         \g at addto@macro\htmlize at scrap{\g at addto@macro\htmlize at output}%
-        \xa\g at addto@macro\xa\htmlize at scrap\xa{\xa{\otherrbrace}}%
+        \ifmoodle at clozemode
+          \xa\g at addto@macro\xa\htmlize at scrap\xa{\xa{\otherbackslash\otherrbrace}}%
+%          \moodle at ifmathmode{\xa\g at addto@macro\xa\htmlize at scrap\xa{\xa{\otherbackslash}}}%
+%                            {}%
+        \else
+          \xa\g at addto@macro\xa\htmlize at scrap\xa{\xa{\otherrbrace}}%
+        \fi
         \g at addto@macro\htmlize at scrap{\htmlize at recursive@i}%
         \xa\g at addto@macro\xa\htmlize at scrap\xa{\htmlize at remainder@detokenized\@htmlize at stop\@htmlize at stop\@htmlize at stop\htmlize at rdelim@i}%
         % Okay, that's done.  It's stored in a global macro.
@@ -2519,10 +4420,10 @@
           \htmlize at displaymathshift@replace#1#2#3\htmlize at rdelim@iii%
         \else
           % Single dollar sign, so we're entering inline math mode.
-          % We grab everything between $$...$$, sanitize it, and add it verbatim to
+          % We grab everything between $...$, sanitize it, and add it verbatim to
           % our output.
           \htmlize at inlinemathshift@replace#1#2#3\htmlize at rdelim@iii%
-        \fi
+        \fi% \ifx\test at ii\@otherdollar
         % Now we resume work.
         % The \htmlize at xxxxxxmathshift@replace macro stored the remaining text in \htmlize at remaining@text.
         % Note that since we never detokenized and retokenized #1#2#3, 
@@ -2647,9 +4548,9 @@
                 %\edef\ds{Must pass on \xa\string\@htmlize at cs}\show\ds
                 \g at addto@macro\htmlize at output{#1}%
                 \def\htmlize at next@i{\htmlize at recursive@i#2#3\htmlize at rdelim@i}%
-              \fi
-            \fi
-          \fi
+              \fi% \ifhtmlize at expandcs
+            \fi% \ifhtmlize at actioncs
+          \fi% \ifx\@htmlize at cs\@@begin at cs
         \else%
           \ifx\test at i\@othertilde%
             % The ~ becomes non-breaking space  
@@ -2664,7 +4565,7 @@
               \else
                 \g at addto@macro\htmlize at output{\otherampersand lsquo;}%
                 \def\htmlize at next@i{\htmlize at recursive@i#2#3\htmlize at rdelim@i}%
-              \fi
+              \fi% \ifx\test at ii\@lsinglequote%
             \else
               \ifx\test at i\@rsinglequote%
                 \ifx\test at ii\@rsinglequote%
@@ -2674,7 +4575,7 @@
                 \else
                   \g at addto@macro\htmlize at output{\otherampersand rsquo;}%
                   \def\htmlize at next@i{\htmlize at recursive@i#2#3\htmlize at rdelim@i}%
-                \fi
+                \fi% \ifx\test at ii\@rsinglequote%
               \else
                 \ifx\test at i\@doublequote
                   \g at addto@macro\htmlize at output{\otherampersand rdquo;}%
@@ -2689,20 +4590,20 @@
                       \moodle at ifmathmode{\g at addto@macro\htmlize at output{\otherampersand gt;}}%
                                         {\g at addto@macro\htmlize at output{>}}%
                       \def\htmlize at next@i{\htmlize at recursive@i#2#3\htmlize at rdelim@i}%
-                    \else                                      
+                    \else
                       % Default case: write first token to output, call self on remaining tokens.
                       \g at addto@macro\htmlize at output{#1}%
                       \def\htmlize at next@i{\htmlize at recursive@i#2#3\htmlize at rdelim@i}%
-                    \fi
-                  \fi
-                \fi
-              \fi
-            \fi
-          \fi
-        \fi
-      \fi
-    \fi
-  \fi
+                    \fi% \ifx\test at i\@gt
+                  \fi% \ifx\test at i\@lt
+                \fi% \ifx\test at i\@doublequote
+              \fi% \ifx\test at i\@rsinglequote%
+            \fi% \ifx\test at i\@lsinglequote%
+          \fi% \ifx\test at i\@othertilde%
+        \fi% \ifx\test at i\@otherbackslash%
+      \fi% \ifx\test at i\@otherdollar%
+    \fi% \ifx\test at i\@otherlbrace%
+  \fi% \ifx\test at i\@@htmlize at stop
   \htmlize at next@i
 }%
 
@@ -2721,16 +4622,38 @@
 \edef\inlinemathleftdelim{\otherbackslash(}%
 \def\inlinemathrightdelim#1{\advancemathmodecounter{-1}%
                             \g at addto@macro\htmlize at output{\otherbackslash)}}%
-\edef\displaymathleftdelim{<CENTER>\otherbackslash[}%
+\edef\displaymathleftdelim{\otherbackslash[}%
 \def\displaymathrightdelim#1{\advancemathmodecounter{-1}%
-                             \g at addto@macro\htmlize at output{\otherbackslash]</CENTER>}}%
+                             \g at addto@macro\htmlize at output{\otherbackslash]}}%
+\long\def\htmlize at inlinemath@recursive at i#1#2#3\htmlize at rdelim@i{%
+  % inspired by \htmlize at recursive@i
+  \def\test at i{#1}%
+  \ifx\test at i\@@htmlize at stop
+    \let\htmlize at next@i=\relax
+  \else
+    \ifx\test at i\@otherbackslash
+        \g at addto@macro\mathtext{#1#2}%
+        \def\htmlize at next@i{\xa\htmlize at inlinemath@recursive at i#3\htmlize at rdelim@i}%
+    \else
+      \ifx\test at i\@otherdollar
+        \let\htmlize at next@i=\relax
+        \g at addto@macro\aftertext{#2#3}%
+      \else
+        \g at addto@macro\mathtext{#1}%
+        \def\htmlize at next@i{\xa\htmlize at inlinemath@recursive at i#2#3\htmlize at rdelim@i}%
+      \fi
+    \fi
+  \fi
+  \htmlize at next@i
+}
 {\catcode`\$=12\relax%
-  \gdef\htmlize at inlinemathshift@replace$#1$#2\htmlize at rdelim@iii{%
+  \gdef\htmlize at inlinemathshift@replace#1#2\htmlize at rdelim@iii{%
     %\def\ds{inline math shift has '#1' and '#2'}\show\ds
     \xa\g at addto@macro\xa\htmlize at output\xa{\inlinemathleftdelim}%
     \advancemathmodecounter{1}%
-    \def\mathtext{#1}%
-    \def\aftertext{#2}%
+    \gdef\mathtext{}%
+    \gdef\aftertext{}%
+    \htmlize at inlinemath@recursive at i#2\htmlize at rdelim@i%
     \xdef\htmlize at remaining@text{\expandonce\mathtext%
                                  \otherbackslash inlinemathrightdelim{}%
                                  \expandonce\aftertext}%
@@ -2746,6 +4669,7 @@
                                  \expandonce\aftertext}%
   }%
 }
+
 %    \end{macrocode}
 % 
 % \subsection{Engines for Control Sequences}
@@ -2847,6 +4771,25 @@
   \xa\g at addto@macro\xa\htmlize at activate@css\xa{\htmlize at scrap}%
   \xa\def\csname html@\string#1\endcsname% %And this \def\html@\oldcsname is follows by the remainder of the definition.
 }
+\def\html at action@newcommand#1[#2][#3]#4{%
+  %\message{>>> Defining #1[#2][#3]{...} ^^J}
+  \ifmoodle at draftmode
+  \else
+    \xa\html at action@def\csname #1\endcsname{\csname moodle@#1 at int\endcsname}%
+  \fi
+  % Note that \htmlize at do@actioncs will 'patch' this by putting 
+  % '\xa\htmlize at proceedwiththerest\htmlize at afteraction@hook'
+  % at the end.  We want those 3 tokens to occur instead after
+  % the graphics filename.
+  \xa\csdef{moodle@#1 at int}##1##2##3{\csname moodle@#1 at int@int\endcsname}%
+  % This gobbles up those three spurious tokens,
+  % which we will re-insert after our work is done.
+  \xa\newcommand\csname moodle@#1 at int@int\endcsname[#2][#3]{%
+    #4%
+    % Now we re-insert the code to get the HTMLizing going again.
+    \xa\htmlize at proceedwiththerest\htmlize at afteraction@hook
+  }%
+}
 %    \end{macrocode}
 % 
 % \subsubsection{Engine for expansion control sequences}
@@ -2868,6 +4811,24 @@
 }
 \let\htmlregister=\htmlize at record@expand
 %    \end{macrocode}
+% Often users define a list of macros at the end of the preamble.
+% It can be cumbersome to record individually these macros for expansion.
+% By calling |\moodleregisternewcommands| they trigger the automatic
+% expansion of macros defined subsequently using |\newcommand|,
+% |\renewcommand|, |\providecommand| or their starred variants.
+%    \begin{macrocode}
+\def\moodleregisternewcommands{%
+  %% INSPIRED FROM 
+  %https://tex.stackexchange.com/questions/73271/how-to-redefine-or-patch-the-newcommand-command
+  \newcommand*{\saved at ifdefinable}{}
+  \let\saved at ifdefinable\@ifdefinable
+  \renewcommand{\@ifdefinable}[2]{%
+    \saved at ifdefinable{##1}{##2}%
+    \htmlregister{##1}
+  }%
+  \let\@@ifdefinable\@ifdefinable
+}%
+%    \end{macrocode}
 % On the other hand, if an alternate version of the macro is 
 % needed for HTML purposes, you can define its HTML version with
 % |\html at def\mymacro...|
@@ -2901,20 +4862,50 @@
 \htmlize at record@environment{shortanswer}
 
 \html at newenvironment{center}{\xdef\htmlize at afteraction@hook{<CENTER>\expandonce\BODY</CENTER>}}%
-\html at newenvironment{enumerate}{%
-    \xa\gatheritems\xa{\BODY}%
-    \gdef\htmlize at afteraction@hook{<OL>}%
-    \loopthroughitemswithcommand{\moodle at itemtoLI}%
-    \g at addto@macro\htmlize at afteraction@hook{</OL>}%
+
+\def\moodle at save@getitems at state{%
+  \global\xa\xdef\csname moodle at currentitemnumber@level@\the\moodle at listdepth\xa\endcsname\xa{\thecurrentitemnumber}%
+  \global\xa\xdef\csname moodle at numgathereditems@level@\the\moodle at listdepth\xa\endcsname\xa{\thenumgathereditems}%
+  \moodle at saveitems{\thenumgathereditems}%
 }%
-\html at newenvironment{itemize}{%
-    \xa\gatheritems\xa{\BODY}%
-    \gdef\htmlize at afteraction@hook{<UL>}%
-    \loopthroughitemswithcommand{\moodle at itemtoLI}%
-    \g at addto@macro\htmlize at afteraction@hook{</UL>}%
+\def\moodle at restore@getitems at state{%
+  \setcounter{numgathereditems}{\csname moodle at numgathereditems@level@\the\moodle at listdepth\endcsname}%
+  \setcounter{currentitemnumber}{\csname moodle at currentitemnumber@level@\the\moodle at listdepth\endcsname}%
+  \moodle at restoreitems{\thenumgathereditems}%
 }%
+\def\moodle at saveitems#1{%
+  \ifnum#1>0%
+    \global\csletcs{moodle at level@\the\moodle at listdepth @item@#1}{getitems at item@#1}%
+    \xa\moodle at saveitems\xa{\number\numexpr#1-1\expandafter}%
+  \fi
+}%
+\def\moodle at restoreitems#1{%
+  \ifnum#1>0%
+    \global\csletcs{getitems at item@#1}{moodle at level@\the\moodle at listdepth @item@#1}%
+    \global\xa\let\csname moodle at level@\the\moodle at listdepth @item@#1\endcsname=\@undefined
+    \xa\moodle at restoreitems\xa{\number\numexpr#1-1\expandafter}%
+  \fi
+}%
+\def\moodle at makelistenv#1#2{%
+  \html at newenvironment{#1}{%
+    \advance\moodle at listdepth by 1\relax
+    \moodle at save@getitems at state%
+      \xa\gatheritems\xa{\BODY}%
+      \gdef\htmlize at afteraction@hook{<#2>}%
+      \loopthroughitemswithcommand{\moodle at itemtoLI}%
+      \g at addto@macro\htmlize at afteraction@hook{</#2>}%
+    \moodle at restore@getitems at state%
+    \advance\moodle at listdepth by -1\relax
+  }%
+}%
+
+\moodle at makelistenv{enumerate}{OL}%
+\moodle at makelistenv{itemize}{UL}%
+
 \def\moodle at itemtoLI#1{%
-  \g at addto@macro\htmlize at afteraction@hook{<LI>#1</LI>}%
+  \g at addto@macro\htmlize at afteraction@hook{<LI>#1}%
+  \trim at spaces@in\htmlize at afteraction@hook%
+  \g at addto@macro\htmlize at afteraction@hook{</LI>}%
 }%
 
 %    \end{macrocode}
@@ -2925,11 +4916,15 @@
 \def\advancemathmodecounter#1{%
   \global\advance\moodle at mathmodedepth by #1\relax
 }
+\def\openclozemode{%
+  \global\moodle at clozemodetrue\relax
+}
+\def\endclozemode{%
+  \global\moodle at clozemodefalse\relax
+}
 \htmlize at record@action{\advancemathmodecounter}%
-
-
-
-
+\htmlize at record@action{\openclozemode}%
+\htmlize at record@action{\endclozemode}%
 \htmlize at record@action{\relax}%
 
 \html at action@def\#{\g at addto@macro\htmlize at output{\otherhash}}%
@@ -2942,15 +4937,32 @@
   }%
 \html at action@def\}{%
     \moodle at ifmathmode{\g at addto@macro\htmlize at output{\otherbackslash\otherrbrace}}%
-                      {\g at addto@macro\htmlize at output{\otherrbrace}}%
+                      {\ifmoodle at clozemode\g at addto@macro\htmlize at output{\otherbackslash}\fi
+                       \g at addto@macro\htmlize at output{\otherrbrace}}%
   }%
+\html at action@def\[{%
+    \advancemathmodecounter{1}
+    \g at addto@macro\htmlize at output{\otherbackslash\otherlbracket}%
+  }%
+\html at action@def\]{%
+    \g at addto@macro\htmlize at output{\otherbackslash\otherrbracket}%
+    \advancemathmodecounter{-1}
+  }%
+\html at action@def\({%
+    \advancemathmodecounter{1}
+    \g at addto@macro\htmlize at output{\otherbackslash(}%
+  }%
+\html at action@def\){%
+    \g at addto@macro\htmlize at output{\otherbackslash)}%
+    \advancemathmodecounter{-1}
+  }%
 \html at action@def\ldots{%
     \moodle at ifmathmode{\g at addto@macro\htmlize at output{\string\ldots}}%
-                      {\g at addto@macro\htmlize at output{...}}%
+                      {\g at addto@macro\htmlize at output{\otherampersand hellip\othersemicol}}%
   }%
 \html at action@def\dots{%
     \moodle at ifmathmode{\g at addto@macro\htmlize at output{\string\dots}}%
-                      {\g at addto@macro\htmlize at output{...}}%
+                      {\g at addto@macro\htmlize at output{\otherampersand hellip\othersemicol}}%
   }%
 \html at action@def\ {%
     \moodle at ifmathmode{\g at addto@macro\htmlize at output{\otherbackslash\otherspace}}%
@@ -2959,13 +4971,26 @@
 \html at action@def\${%
      \g at addto@macro\htmlize at output{\otherdollar}%
   }%
-
 \html at action@def\clozetilde{%
     \xa\g at addto@macro\xa\htmlize at output\xa{\othertilde}%
   }%
+\html at action@def\clozelbrace{%
+    \openclozemode
+    \xa\g at addto@macro\xa\htmlize at output\xa{\otherlbrace}%
+  }%
+\html at action@def\clozerbrace{%
+    \xa\g at addto@macro\xa\htmlize at output\xa{\otherrbrace}%
+    \endclozemode
+  }%
+\html at action@def\TeX{%
+    \g at addto@macro\htmlize at output{\otherbackslash(\otherbackslash rm\otherbackslash TeX\otherbackslash)}
+  }%
+\html at action@def\LaTeX{%
+    \g at addto@macro\htmlize at output{\otherbackslash(\otherbackslash rm\otherbackslash LaTeX\otherbackslash)}
+  }%
 
+{\catcode`;=12\relax\gdef\othersemicol{;}}
 
-
 %Diacritical marks over vowels
 {\catcode`|=3\relax
  \gdef\htmlize at vowels{a|e|i|o|u|A|E|I|O|U|}}
@@ -2974,7 +4999,7 @@
   \g at addto@macro\htmlize at activate@css{%
     \def#1##1{%
       \ifinlist{##1}{\htmlize at vowels}%
-        {\g at addto@macro\htmlize at output{\otherampersand##1#2;}}%
+        {\g at addto@macro\htmlize at output{\otherampersand##1#2\othersemicol}}%
         {\xa\g at addto@macro\htmlize at output\xa{\string#1##1}}%
     }%
   }%
@@ -2981,9 +5006,17 @@
 }
 \htmlize at define@diacritic{\^}{circ}%
 \htmlize at define@diacritic{\'}{acute}%
-\htmlize at define@diacritic{\"}{uml}%
 \htmlize at define@diacritic{\`}{grave}%
 
+%Diaeresis/Tréma/Umlaut
+{\catcode`|=3\relax
+ \gdef\htmlize at diaeresis{a|e|i|o|u|y|A|E|I|O|U|Y|}}
+\html at action@def\"#1{%
+    \ifinlist{#1}{\htmlize at diaeresis}%
+      {\g at addto@macro\htmlize at output{\otherampersand#1uml\othersemicol}}%
+      {\xa\g at addto@macro\htmlize at output\xa{\string\"#1}}%
+}%
+
 %Hungarian long-umlaut diacritics
 \def\@o{o}\def\@O{O}\def\@u{u}\def\@U{U}%
 \html at action@def\H#1{%
@@ -2990,16 +5023,16 @@
   \bgroup
     \def\test at i{#1}%
     \ifx\test at i\@O
-      \def\toadd{\otherampersand\otherhash337;}%
+      \def\toadd{\otherampersand\otherhash336\othersemicol}%
     \else
       \ifx\test at i\@o
-        \def\toadd{\otherampersand\otherhash337;}%
+        \def\toadd{\otherampersand\otherhash337\othersemicol}%
       \else
-        \ifx\test at i\U
-          \def\toadd{\otherampersand\otherhash368;}%
+        \ifx\test at i\@U
+          \def\toadd{\otherampersand\otherhash368\othersemicol}%
         \else
-          \ifx\test at i\u
-            \def\toadd{\otherampersand\otherhash369;}%
+          \ifx\test at i\@u
+            \def\toadd{\otherampersand\otherhash369\othersemicol}%
           \else
             \def\toadd{\otherbackslash\otherlbrace#1\otherrbrace}%
           \fi
@@ -3010,6 +5043,39 @@
   \egroup
 }%
 
+%Cedilla
+\def\@c{c}\def\@C{C}\def\@s{s}\def\@S{S}\def\@t{t}\def\@T{T}%
+\html at action@def\c#1{%
+	\bgroup
+	  \def\test at i{#1}%
+	  \ifx\test at i\@c
+	    \def\toadd{\otherampersand ccedil\othersemicol}%
+	  \else
+	    \ifx\test at i\@C
+	      \def\toadd{\otherampersand Ccedil\othersemicol}%
+	    \else
+	      \ifx\test at i\@s
+	        \def\toadd{\otherampersand\otherhash351\othersemicol}%
+	      \else
+	        \ifx\test at i\@S
+	          \def\toadd{\otherampersand\otherhash350\othersemicol}%
+	        \else
+	          \ifx\test at i\@t
+	            \def\toadd{\otherampersand\otherhash355\othersemicol}%
+	          \else
+	            \ifx\test at i\@T
+	              \def\toadd{\otherampersand\otherhash354\othersemicol}%
+	            \else
+	              \def\toadd{\otherbackslash\otherlbrace#1\otherrbrace}%
+	            \fi
+	          \fi
+	        \fi
+	      \fi
+	    \fi
+	  \fi
+	  \xa\g at addto@macro\xa\htmlize at output\xa{\toadd}%
+	\egroup
+}%
 
 %Tilde over a, n, o
 {\catcode`|=3\relax
@@ -3016,17 +5082,79 @@
  \gdef\htmlize at tilde{A|N|O|a|n|o|}}
 \html at action@def\~#1{%
     \ifinlist{#1}{\htmlize at tilde}%
-      {\g at addto@macro\htmlize at output{\otherampersand#1tilde;}}%
+      {\g at addto@macro\htmlize at output{\otherampersand#1tilde\othersemicol}}%
       {\xa\g at addto@macro\htmlize at output\xa{\string\~#1}}%
-  }%
+}%
+
+% breve diacritics
+{\catcode`|=3\relax
+ \gdef\htmlize at breve{A|G|U|a|g|u|}}
+\def\@e{e}\def\@E{E}\def\@i{i}\def\@ii{\i}\def\@I{I}\def\@o{o}\def\@O{O}%
+\html at action@def\u#1{%
+  \ifinlist{#1}{\htmlize at breve}%
+     {\g at addto@macro\htmlize at output{\otherampersand#1breve\othersemicol}}%
+     {
+      \bgroup
+        \def\test at i{#1}%
+        \ifx\test at i\@E
+          \def\toadd{\otherampersand\otherhash276\othersemicol}%
+        \else
+          \ifx\test at i\@e
+            \def\toadd{\otherampersand\otherhash277\othersemicol}%
+          \else
+            \ifx\test at i\@I
+              \def\toadd{\otherampersand\otherhash300\othersemicol}%
+            \else
+              \ifx\test at i\@i
+                \def\toadd{\otherampersand\otherhash301\othersemicol}%
+              \else
+                \ifx\test at i\@ii
+                  \def\toadd{\otherampersand\otherhash301\othersemicol}%
+                \else
+                  \ifx\test at i\@O
+                    \def\toadd{\otherampersand\otherhash334\othersemicol}%
+                  \else
+                    \ifx\test at i\@o
+                      \def\toadd{\otherampersand\otherhash335\othersemicol}%
+                    \else
+                      \def\toadd{\otherbackslash\otherlbrace#1\otherrbrace}%
+                    \fi
+                  \fi
+                \fi
+              \fi
+            \fi
+          \fi
+        \fi
+        \xa\g at addto@macro\xa\htmlize at output\xa{\toadd}%
+      \egroup
+    }%
+}%
+
+% caron diacritics
+{\catcode`|=3\relax
+ \gdef\htmlize at caron{C|D|E|L|N|R|S|T|Z|c|d|e|l|n|r|s|t|z|}}
+\html at action@def\v#1{%
+    \ifinlist{#1}{\htmlize at caron}%
+      {\g at addto@macro\htmlize at output{\otherampersand#1caron\othersemicol}}%
+      {\xa\g at addto@macro\htmlize at output\xa{\string\v#1}}%
+}%
 %    \end{macrocode}
 % 
 % \subsubsection{Command sequences for Expansion}
 % 
 %    \begin{macrocode}
-\html at def\underline#1{<SPAN STYLE="text-decoration: underline;">#1</SPAN>}
+\html at def\underline#1{<SPAN STYLE=\&\#34;text-decoration: underline;\&\#34;>#1</SPAN>}
 \html at def\emph#1{<EM>#1</EM>}%
+\html at def\textit#1{<I>#1</I>}%
 \html at def\textbf#1{<B>#1</B>}%
+\html at def\texttt#1{<CODE>#1</CODE>}%
+\html at def\textsc#1{<SPAN STYLE=\&\#34;font-variant: small-caps;\&\#34;>#1</SPAN>}
+\html at def\url#1{<A href=\&\#34;#1\&\#34;>#1</A>}%
+\html at def\href#1#2{<A href=\&\#34;#1\&\#34;>#2</A>}%
+\html at def\textsuperscript#1{<SUP>#1</SUP>}%
+\html at def\up#1{<SUP>#1</SUP>}%
+\html at def\fup#1{<SUP>#1</SUP>}%
+\html at def\textsubscript#1{<SUB>#1</SUB>}%
 \html at def\blank{____________}%
 \html at def\par{</P><P>}%
 \html at def\aa{\å}%
@@ -3033,6 +5161,8 @@
 \html at def\AA{\Å}%
 \html at def\ae{\æ}%
 \html at def\AE{\Æ}%
+\html at def\oe{\œ}%
+\html at def\OE{\Œ}%
 \html at def\S{\§}%
 \html at def\euro{\€}%
 \html at def\texteuro{\€}%
@@ -3039,21 +5169,149 @@
 \html at def\o{\ø}%
 \html at def\O{\Ø}%
 \html at def\ss{\ß}%
+\html at def\SS{\&\#7838;}%
 \html at def\l{\ł}%
 \html at def\L{\Ł}%
+\html at def\og{\«\&\#8239;}%
+\html at def\guillemotleft{\«\&\#8239;}%
+\html at def\fg{\&\#8239;\»}%
+\html at def\guillemotright{\&\#8239;\»}%
+\html at def\,{\&\#8239;}%
+\html at def\thinspace{\&\#8239;}%
+\html at def\textbackslash{\&\#92;}%
+\html at def\_{\&\#95;}%
+\html at def\textquestiondown{\¿}%
+\html at def\textexclamdown{\¡}%
 
 % AH CUSTOM MACROS TO EXPAND --- remove these before publishing!
-\htmlize at record@expand{\inv}%
-\htmlize at record@expand{\rec}%
+%\htmlize at record@expand{\inv}%
+%\htmlize at record@expand{\rec}%
 
 \htmlize at record@action\inlinemathrightdelim
 \htmlize at record@action\displaymathrightdelim
 
-
 %    \end{macrocode}
 % 
-% \subsection{Graphics via {\tt\string\includegraphics}}
+% \subsection{Graphics via {\ttfamily\string\includegraphics}}
 % 
+% \subsubsection{Finding Media Files}
+% The following code is adapted from the command |\Ginclude at graphics| as
+% found in |graphics.sty|.
+% Calling |\moodle at media@find|\marg{filename} looks for the file the
+% same way |\includegraphics| does, with or without extension provided,
+% in the current folder and in folders specified with |\graphicspath{}|.
+% The allowed extensions and their relative priorities can be set
+% via |\DeclareGraphicsExtensions{}|.
+% The outcome is that the macros |\moodle at media@base| and |\moodle at media@ext|
+% are set with the basename, including path, and extension, respectively.
+%
+%    \begin{macrocode}
+\def\moodle at media@find#1{%
+  \ifx\detokenize\@undefined\else
+    \edef\Gin at extensions{\detokenize\expandafter{\Gin at extensions}}%
+  \fi
+  \begingroup
+  \let\input at path\Ginput at path
+  \set at curr@file{#1}%
+  \expandafter\filename at parse\expandafter{\@curr at file}%
+  \ifx\filename at ext\Gin at gzext
+    \expandafter\filename at parse\expandafter{\filename at base}%
+    \ifx\filename at ext\relax
+      \let\filename at ext\Gin at gzext
+    \else
+      \edef\Gin at ext{\Gin at ext\Gin at sepdefault\Gin at gzext}%
+    \fi
+  \fi
+  \ifx\filename at ext\relax
+    \@for\Gin at temp:=\Gin at extensions\do{%
+      \ifx\Gin at ext\relax
+        \Gin at getbase\Gin at temp
+      \fi}%
+  \else
+    \Gin at getbase{\Gin at sepdefault\filename at ext}%
+    \ifnum0%
+        \ifx\Gin at ext\relax 1%
+        \else \@ifundefined{Gin at rule@\Gin at ext}{1}{0}%
+        \fi >0
+      \let\Gin at ext\relax
+      \let\Gin at savedbase\filename at base
+      \let\Gin at savedext\filename at ext
+      \edef\filename at base{\filename at base\Gin at sepdefault\filename at ext}%
+      \let\filename at ext\relax
+      \@for\Gin at temp:=\Gin at extensions\do{%
+          \ifx\Gin at ext\relax
+            \Gin at getbase\Gin at temp
+          \fi}%
+      \ifx\Gin at ext\relax
+        \let\filename at base\Gin at savedbase
+        \let\filename at ext\Gin at savedext
+      \fi
+    \fi
+    \ifx\Gin at ext\relax
+       \@warning{File `#1' not found}%
+       \def\Gin at base{\filename at area\filename at base}%
+       \edef\Gin at ext{\Gin at sepdefault\filename at ext}%
+    \fi
+  \fi
+    \ifx\Gin at ext\relax
+         \@latex at error{File `#1' not found}%
+         {I could not locate the file with any of these extensions:^^J%
+          \Gin at extensions^^J\@ehc}%
+    \else
+      % begin modified part
+       \xdef\moodle at media@base{\detokenize\xa{\Gin at base}}%
+       \xdef\moodle at media@ext{\detokenize\xa{\Gin at ext}}%
+      % end modfied part
+    \fi
+  \endgroup
+}
+%    \end{macrocode}
+%    \begin{macrocode}
+%See
+% * https://developer.mozilla.org/en-US/docs/Web/Media/Formats/Image_types
+% * https://developer.mozilla.org/en-US/docs/Web/Media/Formats/Containers
+\def\moodle at media@formats{}
+\newcommand{\DeclareMediaFormat}[3]{%
+  \xdef\moodle at media@formats{\ifx\moodle at media@formats\empty\else\moodle at media@formats,\fi#1}%
+  \csgdef{moodle at media@#1list}{#2}%
+  \csgdef{moodle at media@#1mime}{#3}%
+}%
+% Image Formats
+\DeclareMediaFormat{PNG}{.png,.PNG}{image/png}%
+\DeclareMediaFormat{JPEG}{.jpg,.JPG,.jpeg,.JPEG}{image/jpeg}%
+\DeclareMediaFormat{SVG}{.svg,.SVG}{image/svg+xml}%
+\DeclareMediaFormat{GIF}{.gif}{image/gif}%
+% Audio Formats
+\DeclareMediaFormat{WAV}{.wav,.WAV}{audio/wave}%
+\DeclareMediaFormat{MP3}{.mp3,.MP3}{audio/mpeg}%
+\DeclareMediaFormat{OGG}{.ogg,.opus,.og&}{audio/ogg}%
+%\DeclareMediaFormat{FLAC}{.flac,.FLAC}{audio/flac}%
+% Video Formats
+\DeclareMediaFormat{WEBM}{.webm,.webm}{video/webm}%
+\DeclareMediaFormat{MP4}{.mp4,.MP4,.m4v,.M4V}{video/mp4}%
+\DeclareMediaFormat{OGV}{.ogv,.OGV}{video/ogg}%
+%    \end{macrocode}
+%    \begin{macrocode}
+\def\moodle at media@mime at identify#1{%
+  \edef\test at i{\detokenize\xa{#1}}%
+  \let\moodle at media@mime at current\relax
+  \edef\moodle at media@formats{\detokenize\xa{\moodle at media@formats}}%
+  \@for\@format:=\moodle at media@formats\do{%
+    \edef\@templist{\csname moodle at media@\@format list\endcsname}%
+    \@for\@ext:=\@templist\do{%
+      \ifx\moodle at media@mime at current\relax
+        \edef\@ext{\detokenize\xa{\@ext}}%
+        \ifx\test at i\@ext
+          \message{<<extension \@ext (\@format) identified>>^^J}%
+          \xdef\moodle at media@mime at current{\csname moodle at media@\@format mime\endcsname}%
+          \xdef\moodle at media@ext at current{#1}%
+        \fi
+      \fi
+    }%
+  }%
+}
+%    \end{macrocode}
+%
 % \subsubsection{External program command lines}
 % We first set up commands for the external programs.
 %    \begin{macrocode}
@@ -3068,20 +5326,65 @@
   \expandafter\def\htmlize at executable@macro{#1}%
 }
 
-\def\ghostscriptcommand{\htmlize at setexecutable\gs}
-\def\opensslcommand{\htmlize at setexecutable\openssl}
-\def\imagemagickcommand{\htmlize at setexecutable\htmlize at imagemagick@convert}
+\def\ghostscriptcommand{\htmlize at setexecutable\gs}%
+\def\baselxivcommand{\htmlize at setexecutable\baselxiv}%
+\def\imagemagickcommand{\htmlize at setexecutable\htmlize at imagemagick@convert}%
+\def\optipngcommand{\htmlize at setexecutable\optipng}%
+\def\PDFtoSVGcommand{\htmlize at setexecutable\PDFtoSVG}%
+\def\SVGtoPDFcommand{\htmlize at setexecutable\SVGtoPDF}%
+\def\optiSVGcommand{\htmlize at setexecutable\optiSVG}%
+\def\DeleteFilecommand{\htmlize at setexecutable\DeleteFiles}%
 
 \ifwindows%
-  \ghostscriptcommand{gswin64c.exe}%
+  \ghostscriptcommand{gswin64c.exe -dBATCH -dNOPAUSE -sDEVICE=pngalpha}%
+  \baselxivcommand{certutil}%
+  \DeleteFilecommand{del}%
 \else%
-  \ghostscriptcommand{gs}%
+  \ghostscriptcommand{gs -dBATCH -dNOPAUSE -sDEVICE=pngalpha}%
+  \baselxivcommand{base64}%
+  \DeleteFilecommand{rm -f}%
 \fi%
 
-\opensslcommand{openssl}%
-\imagemagickcommand{convert}%
+\imagemagickcommand{convert -colorspace RGB}%
+\optipngcommand{optipng -clobber -strip all -quiet}%
+\PDFtoSVGcommand{inkscape --export-type=svg --export-area-page --vacuum-defs}%--pdf-poppler
+% remove the "--pdf-poppler" import option if you want to preserve text (avoid conversion to path)
+\SVGtoPDFcommand{inkscape --export-type=pdf --export-area-page}%
+\optiSVGcommand{scour -q --enable-id-stripping --enable-comment-stripping
+                --shorten-ids --indent=none --remove-descriptive-elements}%
 %    \end{macrocode}
 % 
+% \subsubsection{Conversion and inclusion of non-native formats}
+%    \begin{macrocode}
+\AtEndPreamble{%
+  \@ifpackageloaded{graphicx}{%
+    \def\@firstofthree#1#2#3{#1}%
+    \def\@secondofthree#1#2#3{#2}%
+    \newcommand{\DeclareGraphicsAlien}[3]{%
+      \edef\Gin at extensions{\Gin at extensions,#1}%
+      \DeclareGraphicsRule{#1}{\@gobble#1}{#1}{}%
+      \csdef{Gread@\@gobble#1}##1{%
+        \edef\SourceFile{\Gin at base\Gin at ext}%
+        \edef\Gin at base{\Gin at base-\@gobble#1-converted-to}%
+        \edef\Gin at ext{#2}%
+        \edef\OutputFile{\Gin at base\Gin at ext}%
+        \edef\targetfmt{\expandafter\expandafter\expandafter
+                        \@firstofthree\csname Gin at rule@\Gin at ext\endcsname\relax}%
+        \edef\targetext{\expandafter\expandafter\expandafter
+                        \@secondofthree\csname Gin at rule@\Gin at ext\endcsname\relax}%
+        \IfFileExists{\OutputFile}{}{\ShellEscape{#3}}%
+        \csletcs{Ginclude@\@gobble#1}{Ginclude@\targetfmt}%
+        \csname Gread@\targetfmt\endcsname{\Gin at base\targetext}%
+      }%
+    }%
+% Support for GIF files: passed as-is in XML but converted in PNG for PDF output.
+% In case the GIF is animated, we pick up the first frame in this conversion.
+% While the picture will be animated after Moodle import, it will not be in the PDF
+% output, whatever the viewer is.
+    \DeclareGraphicsAlien{.gif}{.png}{\htmlize at imagemagick@convert\otherspace '\SourceFile[0]' \OutputFile}%
+  }{}%
+}%
+%    \end{macrocode}
 % \subsubsection{Graphics key-handling}
 % Next, we get ready to handle keys like |height=4cm| or |width=3cm| or |ppi=72|.
 %    \begin{macrocode}
@@ -3110,25 +5413,58 @@
 %    \end{macrocode}
 % 
 % \subsubsection{Graphics conversion to HTML}
+% If the |tikz| option is loaded, we define the |embedaspict| command.
+% Furthermore, |includegraphics| is packed into a TikZ node.
+% This allows externalization with regular options for |includegraphics|.
+% Otherwise, |includegraphics| is redefined with a limited set of options supported.
+%
+% Option SVG
 %    \begin{macrocode}
-\html at action@def\includegraphics{\moodle at includegraphics@int}%
-  % Note that \htmlize at do@actioncs will 'patch' this by putting 
-  % '\xa\htmlize at proceedwiththerest\htmlize at afteraction@hook'
-  % at the end.  We want those 3 tokens to occur instead after
-  % the graphics filename.
-\def\moodle at includegraphics@int#1#2#3{\moodle at includegraphics@int at int}%
-  % This gobbles up those three spurious tokens,
-  % which we will re-insert after our work is done.
-\newcommand\moodle at includegraphics@int at int[2][]{%
+\ifmoodle at svg
+  \AtEndPreamble{%
+% Declaring SVG to PDF conversion rule for includegraphics
+%      \edef\Gin at extensions{\Gin at extensions,.svg,.SVG}%
+%      \DeclareGraphicsRule{.svg}{pdf}{.pdf}{%
+%        `\SVGtoPDF\otherspace '#1' \noexpand\Gin at base-svg-converted-to.pdf}%
+%      \DeclareGraphicsRule{.SVG}{pdf}{.pdf}{%
+%        `\SVGtoPDF\otherspace '#1' \noexpand\Gin at base-SVG-converted-to.pdf}%
+    \DeclareGraphicsAlien{.svg}{.pdf}{%
+      \SVGtoPDF\otherspace '\SourceFile' -o '\OutputFile' 2>/dev/null}%
+    \DeclareGraphicsAlien{.SVG}{.pdf}{%
+      \SVGtoPDF\otherspace '\SourceFile' -o '\OutputFile' 2>/dev/null}%
+  }%
+\fi
+
+\ifmoodle at tikz
+\AfterEndPreamble{%
+  %\htmlize at record@expand{\embedaspict}%
+  \let\oldincludegraphics=\includegraphics
+  % patching includegraphics to trigger externalization
+  \renewcommand{\includegraphics}[2][]{%
+    %\message{moodle.sty: Processing \string\includegraphics[#1]{#2} for HTML^^J}%
+    \tikz{\node[inner sep=0pt]{\oldincludegraphics[#1]{#2}};}%
+  }%
+  % externalized images must be included with the regular command
+  \pgfkeys{/pgf/images/include external/.code={\oldincludegraphics{#1}}}%
+  \html at action@newcommand{includegraphics}[2][]{%
+    \message{moodle.sty: Processing \string\includegraphics[#1]{#2} ^^J}
+    \global\advance\numpicturesread by 1\relax
+    \edef\htmlize at imagetag{<IMG SRC="data:\TikzExportMIME;base64,\csname picbaselxiv@\the\numpicturesread\endcsname">}%
+    \xa\g at addto@macro\xa\htmlize at output\xa{\htmlize at imagetag}%
+  }%
+}%
+\else
+\html at action@newcommand{includegraphics}[2][]{%
   \bgroup% The grouping is to localize the changes caused by \setkeys.
     \message{moodle.sty: Processing \string\includegraphics[#1]{#2} for HTML...^^J}
     \setkeys*{moodle at includegraphics}{#1}%
     % Height or width should be given in TeX dimensions like cm or pt or in,
     % and are converted to pixels for web use using the ppi key.  
-    % TO DO: Can we modify \includegraphics to accept height or width in 
+    % TODO: Can we modify \includegraphics to accept height or width in 
     %        pixels?
-    % TO DO: What about \includegraphics[scale=0.7] ?
+    % TODO: What about \includegraphics[scale=0.7] ?
     %        Other keys: keepaspectratio=true|false, angle (rotation), clip & trim
+    %           -> the package option 'tikz' offers a workaround for this
     \ifnum\moodle at graphics@height at pixels=0\relax
       \ifnum\moodle at graphics@width at pixels=0\relax
         % No size specified.  Default to height of 200 pixels.
@@ -3150,29 +5486,90 @@
         \edef\moodle at graphics@htmlgeometry{width=\number\moodle at graphics@width at pixels\otherspace height=\number\moodle at graphics@height at pixels}%
       \fi
     \fi
-    %First, convert it to PNG
-    \edef\cmdline{\htmlize at imagemagick@convert\otherspace #2 -resize \moodle at graphics@geometry\otherspace #2.png}%
-    \message{moodle.sty:   Converting '#2' to PNG...^^J}%
-    \expandafter\immediate\expandafter\write18\expandafter{\cmdline}%
-    %Next, convert the PNG to base64 encoding
-    \def\cmdline{\openssl\otherspace enc -base64 -in #2.png -out #2.enc}%
-    \message{moodle.sty:   Converting '#2.png' to base64...^^J}%
-    \expandafter\immediate\expandafter\write18\expandafter{\cmdline}%
+    %Look for the file, even if no extension is provided
+    \moodle at media@find{#2}%
+    %\message{<<\moodle at media@base>>^^J}
+    %\message{<<\moodle at media@ext>>^^J}
+    %Try to identify corresponding MIME-type
+    \moodle at media@mime at identify{\moodle at media@ext}%
+    \ifx\moodle at media@mime at current\relax
+      % conversion needed
+      \edef\moodle at media@pdf{\detokenize{.pdf}}%
+      \edef\moodle at media@ext{\detokenize\xa{\moodle at media@ext}}%
+      \ifnum0\ifx\moodle at media@ext\moodle at media@pdf1\fi\ifmoodle at svg1\fi=11% PDF file and SVG option active
+        \def\moodle at media@ext at current{.svg}%
+        \edef\moodle at media@mime at current{\moodle at media@SVGmime}%
+        \edef\cmdline{\PDFtoSVG\otherspace "\moodle at media@base\moodle at media@ext" -o "\moodle at media@base\moodle at media@ext at current" 2>/dev/null}%
+        \message{moodle.sty:   Converting '#2' to SVG...^^J}%
+        \xa\ShellEscape\xa{\cmdline}%
+        %Next, optimize inline
+        \ifwindows\else
+          \edef\cmdline{\optiSVG < "\moodle at media@base\moodle at media@ext at current" >
+           "\moodle at media@base.tmp.svg" && mv "\moodle at media@base.tmp.svg"
+           "\moodle at media@base\moodle at media@ext at current"}%
+          \message{moodle.sty:   Optimizing '\moodle at media@base\moodle at media@ext at current'...^^J}%
+          \xa\ShellEscape\xa{\cmdline}%
+        \fi
+      \else% call ImageMagick
+        \def\moodle at media@ext at current{.png}%
+        \def\moodle at media@mime at current{image/png}%
+        \edef\cmdline{\htmlize at imagemagick@convert\otherspace "\moodle at media@base\moodle at media@ext" -resize \moodle at graphics@geometry\otherspace "\moodle at media@base\moodle at media@ext at current"}%
+        \message{moodle.sty:   Converting '#2' to PNG...^^J}%
+        \xa\ShellEscape\xa{\cmdline}%
+        %Next, optimize inline
+        \edef\cmdline{\optipng\otherspace "\moodle at media@base\moodle at media@ext at current"}%
+        \message{moodle.sty:   Optimizing '\moodle at media@base\moodle at media@ext at current'...^^J}%
+        \xa\ShellEscape\xa{\cmdline}%
+      \fi
+    \fi
+    %Next, convert the file to base64 encoding
+    \ConvertToBaseLXIV{\moodle at media@base}{\moodle at media@ext at current}%
     %Now, save that base64 encoding in a TeX macro
     \def\moodle at newpic@baselxiv{}%
-    \message{moodle.sty:   Reading base64 file '#2.enc'...^^J}%
-    \openin\baseLXIVdatafile=#2.enc\relax
+    \message{moodle.sty:   Reading base64 file '\moodle at media@base.enc'...^^J}%
+    \openin\baseLXIVdatafile="\moodle at media@base.enc"
       \savebaselxivdata at recursive
     \closein\baseLXIVdatafile
+    %Clean up files
+    \ifx\moodle at media@ext at current\moodle at media@ext
+      \ShellEscape{\DeleteFiles\otherspace "\moodle at media@base.enc"}%
+    \else
+      \ShellEscape{\DeleteFiles\otherspace "\moodle at media@base.enc" "\moodle at media@base\moodle at media@ext at current"}%
+    \fi
     \xa\global\xa\let\csname picbaselxiv at graphics@#2\endcsname=\moodle at newpic@baselxiv%
-    \edef\htmlize at imagetag{<IMG \moodle at graphics@htmlgeometry\otherspace SRC="data:image/png;base64,\csname picbaselxiv at graphics@#2\endcsname">}%
+    \edef\htmlize at imagetag{<IMG \moodle at graphics@htmlgeometry\otherspace SRC="data:\moodle at media@mime at current;base64,\csname picbaselxiv at graphics@#2\endcsname">}%
     \xa\g at addto@macro\xa\htmlize at output\xa{\htmlize at imagetag}%
     \message{moodle.sty:   <IMG> tag inserted.^^J}%
   \egroup
-  % Now we re-insert the code to get the HTMLizing going again.
-  \xa\htmlize at proceedwiththerest\htmlize at afteraction@hook
-}
+}%
+\fi
 %    \end{macrocode}
+% This macro is in charge of throwing a system call to convert local files to base64.
+%    \begin{macrocode}
+\ifwindows
+  \def\ConvertToBaseLXIV#1#2{%
+    \def\cmdline{\baselxiv\otherspace -encode "#1#2"\otherspace tmp.b64 && findstr /vbc:"---" tmp.b64 > "#1" && del tmp.b64"}%
+    \message{moodle.sty:   Converting '#1#2' to base64...^^J}%
+    \xa\ShellEscape\xa{\cmdline}%
+  % Starting from Windows 7, CertUtil is included by default. There should be no windows XP still running
+  }%  
+\else
+  \ifmacosx
+    \def\ConvertToBaseLXIV#1#2{%
+      \def\cmdline{\baselxiv\otherspace -b 64 -i "#1#2"\otherspace -o "#1.enc"}%
+      \message{moodle.sty:   Converting '#1#2' to base64...^^J}%
+      \xa\ShellEscape\xa{\cmdline}%
+    }%
+  \else % Linux, Cygwin
+    \def\ConvertToBaseLXIV#1#2{%
+      \def\cmdline{\baselxiv\otherspace "#1#2"\otherspace > "#1.enc"}%
+      \message{moodle.sty:   Converting '#1#2' to base64...^^J}%
+      \xa\ShellEscape\xa{\cmdline}%
+    }%
+    % base64 is part of coreutils, add "-w 64" to get exactly the previous behavior  %
+  \fi
+\fi
+%    \end{macrocode}
 % The following code accomplishes the reading of an |.enc| file into memory.
 % It is also used by the \TikZ\ code below.
 %    \begin{macrocode}
@@ -3201,9 +5598,9 @@
 % are undefined.
 % Our solution is to wait until |\AtBeginDocument| and then test whether 
 % \TikZ\ is loaded.  If so, we make the appropriate definitions.
+% \begin{macro}{TikZ}
+% \changes{v0.7}{2020/07/14}{Support \emph{tikz}\ command}
 %    \begin{macrocode}
-\newif\ifmoodle at tikzloaded
-\moodle at tikzloadedfalse
 \AtBeginDocument{
   \ifx\tikzpicture\@undefined
     \moodle at tikzloadedfalse
@@ -3210,23 +5607,48 @@
   \else
     \moodle at tikzloadedtrue
   \fi
+  \ifmoodle at draftmode
+    \long\def\tikzifexternalizing#1#2{#2}%
+  \else
   \ifmoodle at tikzloaded
-    \usetikzlibrary{external}
+    \usetikzlibrary{external}%
     \tikzexternalize%
     \tikzset{external/force remake}%
-
-    \ifpdf
-      \def\pdftopng{\edef\gscmdline{\gs\otherspace -dBATCH -dNOPAUSE -sDEVICE=pngalpha -sOutputFile=\tikzexternalrealjob-tikztemp-\the\numconvertedpictures.png -r200 \tikzexternalrealjob-tikztemp-\the\numconvertedpictures.pdf}%
-                    \expandafter\immediate\expandafter\write18\expandafter{\gscmdline}}%
+    \def\moodle at basename{\tikzexternalrealjob-tikztemp-\the\numconvertedpictures}%
+    \ifmoodle at svg
+      \def\TikzExportExtension{.svg}%
+      \def\TikzExportMIME{image/svg+xml}%
+      \ifpdfoutput% tex engines defaulting to PDF output (pdflatex, xelatex, lualatex)
+        \def\ExportTikz{ \message{moodle.sty: Converting picture '\moodle at basename.pdf' to SVG...^^J}%
+                         \edef\cmdline{\PDFtoSVG\otherspace "\moodle at basename.pdf" -o "\moodle at basename\TikzExportExtension" 2>/dev/null}%
+                         \xa\ShellEscape\xa{\cmdline}}%
+      \else % latex
+        \def\ExportTikz{ \message{moodle.sty: Converting picture '\moodle at basename.ps' to SVG...^^J}%
+                         \edef\cmdline{\PDFtoSVG\otherspace "\moodle at basename.ps" -o "\moodle at basename\TikzExportExtension" 2>/dev/null}%
+                         \xa\ShellEscape\xa{\cmdline}}%
+      \fi
+      \def\OptimizeExport{ \message{moodle.sty:   Optimizing '\moodle at basename.svg'...^^J}%
+                           \edef\cmdline{\optiSVG\otherspace < "\moodle at basename\TikzExportExtension" >
+                                         "\moodle at basename.tmp.svg" && mv "\moodle at basename.tmp.svg"
+                                         "\moodle at basename\TikzExportExtension" }%
+                           \xa\ShellEscape\xa{\cmdline}}%
     \else
-      \def\pstopng{\edef\gscmdline{\gs\otherspace -dBATCH -dNOPAUSE -sDEVICE=pngalpha -sOutputFile=\tikzexternalrealjob-tikztemp-\the\numconvertedpictures.png -r200 \tikzexternalrealjob-tikztemp-\the\numconvertedpictures.ps}%
-                    \expandafter\immediate\expandafter\write18\expandafter{\gscmdline}}%
+      \def\TikzExportExtension{.png}%
+      \def\TikzExportMIME{image/png}%
+      \ifpdfoutput% tex engines defaulting to PDF output (pdflatex, xelatex, lualatex)
+        \def\ExportTikz{ \message{moodle.sty: Converting picture '\moodle at basename.pdf' to PNG...^^J}%
+                         \edef\gscmdline{\gs\otherspace -sOutputFile=\moodle at basename\TikzExportExtension\otherspace -r150 \moodle at basename.pdf}%
+                         \xa\ShellEscape\xa{\gscmdline}}%
+      \else % latex
+        \def\ExportTikz{ \message{moodle.sty: Converting picture '\moodle at basename.ps' to PNG...^^J}%
+                         \edef\gscmdline{\gs\otherspace -sOutputFile=\moodle at basename\TikzExportExtension\otherspace -r150 \\moodle at basename.ps}%
+                         \xa\ShellEscape\xa{\gscmdline}}%
+      \fi
+      \def\OptimizeExport{ \message{moodle.sty:   Optimizing '\moodle at basename.png'...^^J}%
+                           \edef\cmdline{\optipng\otherspace \moodle at basename\TikzExportExtension}%
+                           \xa\ShellEscape\xa{\cmdline}}%
     \fi
-    \def\pngtobaselxiv{\edef\opensslcmdline{\openssl\otherspace enc -base64 -in \tikzexternalrealjob-tikztemp-\the\numconvertedpictures.png -out \tikzexternalrealjob-tikztemp-\the\numconvertedpictures.enc}%
-                       \expandafter\immediate\expandafter\write18\expandafter{\opensslcmdline}}%
-
     \let\moodle at oldtikzpicture=\tikzpicture
-
     %The following code lets us run things *before* the normal \begin{tikzpicture}.
     \renewenvironment{tikzpicture}{%
       \global\advance\numconvertedpictures by 1\relax
@@ -3238,43 +5660,63 @@
     % However, the tikz externalize library does *not* run \end{tikzpicture}.
     % In order to run commands after the tikz picture is done compiling, we need to 
     % use a hook into \tikzexternal at closeenvironments.
-
     \g at addto@macro{\tikzexternal at closeenvironments}{%
       \moodle at endtikzpicture@hook
     }
+% The following could replace calls to \pdftopng, \pngoptim and \pngtobaselxiv
+%    \tikzset{external/system call/.add={}{;
+%         gs -dBATCH -dNOPAUSE -sDEVICE=pngalpha -sOutputFile="\image.png" -r150 "\image.pdf";
+%         optipng -clobber -strip all -quiet "\image.png";
+%         base64 "\image.png" > "\image.enc"
+%      }
+%    }
+% With the following mechanism, we could trigger something when the externalized images are included back.
+%    \pgfkeys{/pgf/images/include external/.code={\pgfimage{#1}\@moodle at ifgeneratexml{\savebaselxivdata}{}}}
+%
     \def\moodle at endtikzpicture@hook{%
       \@moodle at ifgeneratexml{%
-        \ifpdf
-          \message{moodle.sty: Converting picture '\tikzexternalrealjob-tikztemp-\the\numconvertedpictures.pdf' to PNG...^^J}%
-          \pdftopng
-        \else
-          \pstopng
-        \fi
-        \message{moodle.sty:   Converting '\tikzexternalrealjob-tikztemp-\the\numconvertedpictures.png' to base64...^^J}%
-        \pngtobaselxiv
+        \ExportTikz
+        \OptimizeExport
+        \ConvertToBaseLXIV{\moodle at basename}{\TikzExportExtension}%
         \message{moodle.sty:   Reading base64 file '\tikzexternalrealjob-tikztemp-\the\numconvertedpictures.enc'...^^J}%
         \savebaselxivdata
         \message{moodle.sty:   base64 data saved.^^J}%
       }{}%
     }
-    \tikzset{external/optimize=true}
-    \tikzset{external/optimize command away={\VerbatimInput}{1}}
+    \ifmoodle at tikz
+      \tikzset{external/optimize=false}% due to redefinition, includegraphics must not be optimized away
+    \else
+      \tikzset{external/optimize=true}%
+      \tikzset{external/optimize command away={\VerbatimInput}{1}}%
+    \fi
     %
     % The HTMLizer version of the tikzpicture environment,
     % which writes an <IMG> tag to the XML file.
-    \htmlize at record@environment{tikzpicture}
+    \htmlize at record@environment{tikzpicture}%
     \g at addto@macro\htmlize at activate@environments{%
       \let\tikzpicture\relax\let\endtikzpicture\relax
       \NewEnviron{tikzpicture}[1][]{%
         \global\advance\numpicturesread by 1\relax
-        \edef\htmlize at imagetag{<IMG SRC="data:image/png;base64,\csname picbaselxiv@\the\numpicturesread\endcsname">}%
+        \edef\htmlize at imagetag{<IMG SRC="data:\TikzExportMIME;base64,\csname picbaselxiv@\the\numpicturesread\endcsname">}%
         \xa\g at addto@macro\xa\htmlize at output\xa{\htmlize at imagetag}%
       }[\htmlize at patchendenvironment]%
     }%
+    \html at action@newcommand{tikz}[2][]{%
+%      \message{>>> Processing \string\tikz[#1]{...} ^^J}
+      \global\advance\numpicturesread by 1\relax
+      \edef\htmlize at imagetag{<IMG SRC="data:\TikzExportMIME;base64,\csname picbaselxiv@\the\numpicturesread\endcsname">}%
+      \xa\g at addto@macro\xa\htmlize at output\xa{\htmlize at imagetag}%
+    }%
   \else
     %TikZ not loaded.  Provide dummy definitions for commands.
     \long\def\tikzifexternalizing#1#2{#2}%
   \fi
+  \fi
+  \ifmoodle at tikz
+    \tikzstyle{moodlepict}=[minimum height=1em,inner sep=0pt,execute at begin node={\begin{varwidth}{\linewidth}},execute at end node={\end{varwidth}}]
+    \newcommand\embedaspict[1]{\tikz[baseline=-\the\dimexpr\fontdimen22\textfont2\relax]{\node[moodlepict]{\mbox{#1}};}}
+    \htmlize at record@expand{\embedaspict}
+  \fi
 }
 
 \newcount\numconvertedpictures
@@ -3290,27 +5732,464 @@
   \xa\global\xa\let\csname picbaselxiv@\the\numconvertedpictures\endcsname=\moodle at newpic@baselxiv%
 }
 
-\def\@moodle at par{\par}%
+\ifmoodle at tikz
+  \ifmoodle at tikzloaded
+    \PackageWarning{moodle}{With package option 'tikz', you should not load TikZ manually.}%
+  \fi
+  \RequirePackage{tikz}%
+  \RequirePackage{varwidth}% for the command |embedaspict|
+\fi
 %    \end{macrocode}
 % Finally, we clean up our mess by deleting the temporary PDF, PNG, and ENC 
 % files we created.
+% With XeTeX, we cannot clean pictures pdf's because they are actually included in the final pdf afterwards, by xdvipdfmx.
+% With LuaTeX, it looks like |\AtEndDocument| is too early to for this cleaning step.
 %    \begin{macrocode}
-\AtEndDocument{%
+\AfterEndDocument{%
   \ifmoodle at tikzloaded
     \@moodle at ifgeneratexml{%
-      \ifwindows
-        \immediate\write18{del \tikzexternalrealjob-tikztemp-*.*}%
+      \ifXeTeX
+        % we must keep picture pdf's for subsequent linking (xdvipdfmx)
+        \ifwindows
+          \ShellEscape{powershell.exe -noexit "del * -include \tikzexternalrealjob-tikztemp-*.* -exclude *.pdf}%
+        \else
+          \ShellEscape{find . -type f -name "\tikzexternalrealjob-tikztemp-*.*" -not -name "*.pdf" -delete}%
+        \fi
       \else
-        \immediate\write18{rm \tikzexternalrealjob-tikztemp-*.*}%
+        \ShellEscape{\DeleteFiles\otherspace \tikzexternalrealjob-tikztemp-*.*}%
       \fi
     }{}%
   \fi
 }
-
-% TO DO:
+%    \end{macrocode}
+% TODO:
 % * sizing options for TikZ pictures?
-% * In cloze multi, how to handle HTML or TeX in answers?  In particular, what about ~?
+%\end{macro}
+%
+% \subsection{Other Media}
+% Support for other media comes through the |\url|\marg{link} and |\href|\marg{link}\marg{text}
+% commands.
+\AtEndPreamble{%
+  \@ifpackageloaded{hyperref}{%
+    \let\oldhref\href
+    \let\oldurl\url
+    \def\moodle at hyper@readexternallink#1#2#3#4:#5:#6\\#7{%
+% 1) The link type (the string "link" in the cases I observed)
+% 2) The URL fragment (i.e. what comes after # in the end),
+% 3) the text replacement,
+% 4) the URL scheme (http, https, mailto, file, run etc),
+% 5) the URL details (in general, that is whole authority + path + query).
+%    If the URL contains a column (specification of a password in userinfo or a
+%    port in authority), we get here whatever comes before the first column (:)
+% 6) empty is URL contains no column. Otherwise, filled with whatever follows
+%    a first column (:) after the scheme,
+% 7) the whole URL again (fragment removed).
+      \def\filename at ext{}%
+      \def\filename at area{}%
+      \def\filename at base{}%
+      \ifx\\#6\\% if ##6 is empty (the URL contains no column -> no scheme -> local)
+        %\@hyper at linkfile file:#7\\{#3}{#2}{#7}% local file
+        %Local file (##1|##2|##3|##4|##5|##6): ##7\par
+        \filename at parse{#4}%
+        \ConvertToBaseLXIV{\filename at area\filename at base}{.\filename at ext}%
+      \else
+        \ifx\\#4\\%if ##4 is empty (no scheme was specified -> local file)
+%          %\@hyper at linkfile file:#7\\{#3}{#2}{#7}% Mac filename ?
+%          Local file (Mac? ##1|##2|##3|##4|##5|##6): ##7\par
+          \filename at parse{#4}%
+          \ConvertToBaseLXIV{\filename at area\filename at base}{.\filename at ext}%
+        \else
+          \def\@pdftempa{#4}%
+          \ifx\@pdftempa\@pdftempwordfile% scheme is "file:"
+%            %\@hyper at linkfile#7\\{#3}{#2}{#7}% file
+%            Local file (no column ##1|##2|##3|##4|##5|##6): ##7\par
+            \filename at parse{#5}%
+            \ConvertToBaseLXIV{\filename at area\filename at base}{.\filename at ext}%
+          \else
+            \ifx\@pdftempa\@pdftempwordrun% scheme is "run:"
+              \ifHy at pdfa
+                \Hy at Error{%
+                  PDF/A: Launch action is prohibited%
+                }\@ehc
+                \begingroup
+                  \leavevmode
+%                  ##2%
+                \endgroup
+              \else% not in PDF/A mode -> run is allowed
+                %\@hyper at launch#7\\{#3}{#2}% run local file
+%                Run local file (##1|##2|##3|##4|##5|##6): ##7\par
+                \filename at parse{#5}%
+                \ConvertToBaseLXIV{\filename at area\filename at base}{.\filename at ext}%
+              \fi
+            \else% scheme is neither "file" nor "run", assuming it is a web protocol
+              %\hyper at linkurl{#3}{#7\ifx\\#2\\\else\hyper at hash#2\fi}% URL
+%              URL (##1|##2|##3|##4|##5|##6): ##7\par
+              \filename at parse{#7}%
+            \fi
+          \fi
+        \fi
+      \fi
+      \xdef\moodle at media@ext{.\filename at ext}%
+      \xdef\moodle at media@base{\filename at area\filename at base}%
+    }%
+%    \html at action@newcommand{href}[3][]{%
+%      \bgroup% The grouping is to localize the changes caused by \setkeys.
+%        \message{moodle.sty: Processing \string\href[#1]{#2}{#3} for HTML...^^J}%
+% the following macro is a modified version of hyperref's |\hyper at readexternallink|
+%        \let\@hyper at readexternallink\moodle at hyper@readexternallink
+%        \oldhref[#1]{#2}{#3}%
+        %\message{<<\moodle at media@base>>^^J}
+        %\message{<<\moodle at media@ext>>^^J}
+        %Try to identify corresponding MIME-type
+%        \moodle at media@mime at identify{\moodle at media@ext}%
+        %\edef\moodle at media@mime at current{\detokenize\xa{\moodle at media@mime at current}}%
+%        \xa\message\xa{moodle.sty: \moodle at media@mime at current^^J}%
+%        \ifx\moodle at media@mime at current\relax
+%          \xa\g at addto@macro\xa\htmlize at output\xa{<A href=\otherampersand\otherhash34;\moodle at media@base\moodle at media@ext\otherampersand\otherhash34;>#3</A>}%
+%          \message{moodle.sty:   <A> tag inserted.^^J}%
+%        \else
+%          \filename at parse{\moodle at media@mime at current}%
+%          \def\@tmp{audio/}
+%          \ifx\filename at area\@tmp
+%            \IfFileExists{\moodle at media@base.enc}{%
+%              \def\moodle at newpic@baselxiv{}%
+%              \openin\baseLXIVdatafile=\moodle at media@base.enc\relax
+%                \savebaselxivdata at recursive
+%              \closein\baseLXIVdatafile
+%              \xa\g at addto@macro\xa\htmlize at output\xa{<audio controls src="data:\moodle at media@mime at current;base64,\moodle at newpic@baselxiv">#3</audio>}%
+%            }{%
+%              \xa\g at addto@macro\xa\htmlize at output\xa{<audio controls src="\moodle at media@base\moodle at media@ext">#3</audio>}%
+%            }%
+%            \message{moodle.sty:   <audio> tag inserted.^^J}%
+%          \else
+%            \def\@tmp{video/}
+%            \ifx\filename at area\@tmp
+%              \IfFileExists{\moodle at media@base.enc}{%
+%                \def\moodle at newpic@baselxiv{}%
+%                \openin\baseLXIVdatafile=\moodle at media@base.enc\relax
+%                  \savebaselxivdata at recursive
+%                \closein\baseLXIVdatafile
+%                \xa\g at addto@macro\xa\htmlize at output\xa{<video controls src="data:\moodle at media@mime at current;base64,\moodle at newpic@baselxiv">#3</video>}%
+%              }{%
+%                \xa\g at addto@macro\xa\htmlize at output\xa{<video controls src="\moodle at media@base\moodle at media@ext">#3</video>}%
+%              }%
+%              \message{moodle.sty:   <video> tag inserted.^^J}%
+%            \else
+%              \PackageWarning{moodle}{cannot recognize MIME type of #2. Ignoring it.}%
+%            \fi
+%          \fi
+%        \fi
+%      \egroup
+%    }%
+%    \html at action@def\url#1{%
+%      \bgroup% The grouping is to localize the changes caused by \setkeys.
+%        \message{moodle.sty: Processing \string\url{#1} for HTML...^^J}%
+% the following macro is a modified version of hyperref's |\hyper at readexternallink|
+%        \let\@hyper at readexternallink\moodle at hyper@readexternallink
+%        \oldhref{#1}{#1}%
+%        \xa\g at addto@macro\xa\htmlize at output\xa{<A href=\otherampersand\otherhash34;\moodle at media@base\moodle at media@ext\otherampersand\otherhash34;>#1</A>}%
+%        \message{moodle.sty:   <A> tag inserted.^^J}%
+%      \egroup
+%    }%
+  }{}%
+}%
+%
+% \subsection{Verbatim Code}
+% 
+% We start by defining a macro to parameter a style for code box display in Moodle
+%    \begin{macrocode}
+\def\xmlDisplayVerbatimBox{border-top: thin solid; border-bottom: thin solid}%
 %    \end{macrocode}
+% First, let us handle |\verbatiminput| from the `verbatim' package
+%    \begin{macrocode}
+\html at action@def\verbatiminput#1{%
+  \message{moodle.sty: Processing \string\verbatiminput{#1} for HTML ^^J}%
+  \g at addto@macro\htmlize at output{<PRE style="\xmlDisplayVerbatimBox"><CODE>}%
+  %%%%%%%%%%%%%% from verbatim %%%%%%%%%%%%%%%%%
+  \@bsphack
+  \let\do\@makeother\dospecials
+  \catcode`\^^M\active
+  \def\verbatim at processline{\xa\g at addto@macro\xa\htmlize at output\xa{\the\verbatim at line<BR/>}}
+  \verbatim at readfile{#1}%
+  \@esphack
+   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+  \g at addto@macro\htmlize at output{</CODE></PRE>}%
+}%
+%    \end{macrocode}
+% Second, we deal with |\VerbatimInput| from `fancyvrb' or `fvextra'
+%    \begin{macrocode}
+\@ifpackageloaded{minted}{\PackageError{moodle}{'moodle' should be loaded before 'minted'.}%
+{'moodle' loads 'fancybox' which, unfortunately, redefines verbatim commands.}}{\relax}%
+\@ifpackageloaded{fvextra}{\PackageError{moodle}{'moodle' should be loaded before 'fvextra'.}%
+{'moodle' loads 'fancybox' which, unfortunately, redefines verbatim commands.}}{\relax}%
+\@ifpackageloaded{fancyvrb}{\PackageError{moodle}{'moodle' should be loaded before 'fancyvrb'.}%
+{'moodle' loads 'fancybox' which, unfortunately, redefines verbatim commands.}}{\relax}%
+
+\html at action@newcommand{VerbatimInput}[2][]{%
+  \message{moodle.sty: Processing \string\VerbatimInput[#1]{#2} for HTML ^^J}%
+  \def\FV at KeyValues{#1}%
+  \FV at UseKeyValues% import options defined in #1
+  \moodle at VerbatimInput{#2}%
+}%
+\html at action@newcommand{LVerbatimInput}[2][]{%
+  \message{moodle.sty: Processing \string\LVerbatimInput[#1]{#2} for HTML ^^J}%
+  \def\FV at KeyValues{#1}%
+  \FV at UseKeyValues% import options defined in #1
+  \moodle at VerbatimInput{#2}%
+}%
+\html at action@newcommand{BVerbatimInput}[2][]{%
+  \message{moodle.sty: Processing \string\BVerbatimInput[#1]{#2} for HTML ^^J}%
+  \def\FV at KeyValues{#1}%
+  \FV at UseKeyValues% import options defined in #1
+  \moodle at VerbatimInput{#2}%
+}%
+\def\moodle at VerbatimInput#1{%
+  \g at addto@macro\htmlize at output{<PRE style="\xmlDisplayVerbatimBox"><CODE>}%
+  %%%%%%%% using material from fancyvrb and fvextra  %%%%%%%%
+  %\begingroup
+  \def\moodle at verbatim@addlinenumber##1{%
+    \g at addto@macro\htmlize at output{<span style="font-size: 80\otherpercent; 
+         background-color: \otherhash f0f0f0; padding: 0 5px 0 5px; display:
+         inline-block; width: 16pt; ##1">}%
+    \if at FV@NumberBlankLines
+      \xa\g at addto@macro\xa\htmlize at output\xa{\the\c at FancyVerbLine</span>}%
+    \else
+      \ifx\FV at Line\empty
+        \xa\g at addto@macro\xa\htmlize at output\xa{\otherampersand nbsp;</span>}%
+      \else
+        \xa\g at addto@macro\xa\htmlize at output\xa{\the\c at FancyVerbLine</span>}%
+      \fi 
+    \fi
+  }
+  % redefine the ProcessLine routine ('fancyvrb' and 'fvextra') for XML output
+  \def\FV at ProcessLine##1{%
+    \ifcsname FV at HighlightLine:\number\c at FancyVerbLine\endcsname
+      \xdef\moodle at FV@tagB{<mark>}% fvextra triggered highlighting for this line
+      \xdef\moodle at FV@tagE{</mark>}%
+    \else
+      \xdef\moodle at FV@tagB{}% no highlighting
+      \xdef\moodle at FV@tagE{}%
+    \fi
+    \catcode`\`=12%
+    \def\FV at Line{##1}%
+    \ifx\FV at LeftListNumber\relax
+    
+    \else% line numbers displayed on the left side
+      \moodle at verbatim@addlinenumber{text-align: right}%
+    \fi
+    \xa\g at addto@macro\xa\htmlize at output\xa{\moodle at FV@tagB}%
+    \xa\g at addto@macro\xa\htmlize at output\xa{\FV at Line}%
+    \xa\g at addto@macro\xa\htmlize at output\xa{\moodle at FV@tagE}%
+    \ifx\FV at RightListNumber\relax\else% line numbers on the right side
+      \moodle at verbatim@addlinenumber{text-align: left; float: right}%
+    \fi
+    \g at addto@macro\htmlize at output{<BR/>}%linebreak
+  }
+  \global\FV at CodeLineNo\z@% reset codeline counter
+  \frenchspacing% Cancels special punctuation spacing.
+  \FV at DefineWhiteSpace
+  \def\FV at Space{\space}
+  \FV at DefineTabOut% replace tabs with a series a whitespaces
+  \ifdefined\FV at HighlightLinesPrep
+    \FV at HighlightLinesPrep% prepare highlighting if 'fvextra' is loaded
+  \fi
+  \FV at Input{#1}%
+  %\endgroup
+  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+  \g at addto@macro\htmlize at output{</CODE></PRE>}%
+}%
+\AtEndPreamble{%
+  \@ifpackageloaded{fancyvrb}{%
+    % custom settings for display
+    \fvset{frame=lines,label={[Beginning of code]End of code},framesep=3mm,numbersep=9pt}%
+  }{\relax}%
+}
+%    \end{macrocode}
+% Third, we patch `minted' so that it also calls pygmentize to generate HTML code.
+%    \begin{macrocode}
+\AtEndPreamble{% this definition should prevail because `minted' gets loaded after `moodle'
+\@ifpackageloaded{minted}{%
+  \newcounter{moodle at pygmentizecounter}%
+  \renewcommand{\minted at pygmentize}[2][\minted at outputdir\minted at jobname.pyg]{%
+    \minted at checkstyle{\minted at get@opt{style}{default}}%
+    \stepcounter{minted at pygmentizecounter}%
+    \ifthenelse{\equal{\minted at get@opt{autogobble}{false}}{true}}%
+      {\def\minted at codefile{\minted at outputdir\minted at jobname.pyg}}%
+      {\def\minted at codefile{#1}}%
+    \ifthenelse{\boolean{minted at isinline}}%
+      {\def\minted at optlistcl@inlines{%
+        \minted at optlistcl@g at i
+        \csname minted at optlistcl@lang\minted at lang @i\endcsname}}%
+      {\let\minted at optlistcl@inlines\@empty}%
+    \def\minted at cmdtemplate##1##2{%
+      \ifminted at kpsewhich
+        \ifwindows
+          \detokenize{for /f "usebackq tokens=*"}\space\@percentchar\detokenize{a 
+          in (`kpsewhich}\space\minted at codefile\detokenize{`) do}\space
+        \fi
+      \fi
+      \MintedPygmentize\space -l #2 -f ##1 -F tokenmerge
+      \minted at optlistcl@g \csname minted at optlistcl@lang\minted at lang\endcsname
+      \minted at optlistcl@inlines
+      \minted at optlistcl@cmd -o \minted at outputdir##2\space
+      \ifminted at kpsewhich
+        \ifwindows
+          \@percentchar\detokenize{a}%
+        \else
+          \detokenize{`}kpsewhich \minted at codefile\space
+            \detokenize{||} \minted at codefile\detokenize{`}%
+        \fi
+      \else
+        \minted at codefile
+      \fi}%
+    \def\minted at cmd{\minted at cmdtemplate{latex -P commandprefix=PYG}{\minted at infile}}
+    % For debugging, uncomment: %%%%
+    \immediate\typeout{\minted at cmd}%
+    % %%%%
+    \def\minted at cmdHTML{\minted at cmdtemplate{html -P noclasses -P 
+      nowrap -P hl_lines="\FV at HighlightLinesList" -P
+      style="\minted at get@opt{style}{default}"}{\csname minted at infileHTML\the\c at minted@pygmentizecounter\endcsname}}%
+    \def\minted at cmdPNG{\minted at cmdtemplate{png -P    
+      line_numbers=True}{\minted at infilePNG}}%
+    \def\minted at cmdSVG{\minted at cmdtemplate{svg -P 
+      linenos=True}{\minted at infileSVG}}%
+    \ifthenelse{\boolean{minted at cache}}%
+      {%
+        \ifminted at frozencache
+        \else
+          \ifx\XeTeXinterchartoks\minted at undefined
+            \ifthenelse{\equal{\minted at get@opt{autogobble}{false}}{true}}%
+              {\edef\minted at hash{\pdf at filemdfivesum{#1}%
+                \pdf at mdfivesum{\minted at cmd autogobble(\ifx\FancyVerbStartNum\z@ 
+                0\else\FancyVerbStartNum\fi-\ifx\FancyVerbStopNum\z@ 
+                0\else\FancyVerbStopNum\fi)}}}%
+              {\edef\minted at hash{\pdf at filemdfivesum{#1}%
+                \pdf at mdfivesum{\minted at cmd}}}%
+          \else
+            \ifx\mdfivesum\minted at undefined
+              \immediate\openout\minted at code\minted at jobname.mintedcmd\relax
+              \immediate\write\minted at code{\minted at cmd}%
+              \ifthenelse{\equal{\minted at get@opt{autogobble}{false}}{true}}%
+                {\immediate\write\minted at code{autogobble(\ifx\FancyVerbStartNum\z@
+                 0\else\FancyVerbStartNum\fi-\ifx\FancyVerbStopNum\z@ 
+                0\else\FancyVerbStopNum\fi)}}{}%
+              \immediate\closeout\minted at code
+              \edef\minted at argone@esc{#1}%
+              \StrSubstitute{\minted at argone@esc}{\@backslashchar}{\@backslashchar\@backslashchar}[\minted at argone@esc]%
+              \StrSubstitute{\minted at argone@esc}{"}{\@backslashchar"}[\minted at argone@esc]%
+              \edef\minted at tmpfname@esc{\minted at outputdir\minted at jobname}%
+              \StrSubstitute{\minted at tmpfname@esc}{\@backslashchar}{\@backslashchar\@backslashchar}[\minted at tmpfname@esc]%
+              \StrSubstitute{\minted at tmpfname@esc}{"}{\@backslashchar"}[\minted at tmpfname@esc]%
+              %Cheating a little here by using ASCII codes to write `{` and `}`
+              %in the Python code
+              \def\minted at hashcmd{%
+                \detokenize{python -c "import hashlib; import os;
+                  hasher = hashlib.sha1();
+                  f = 
+                  open(os.path.expanduser(os.path.expandvars(\"}\minted at tmpfname@esc.mintedcmd\detokenize{\")),
+                   \"rb\");
+                  hasher.update(f.read());
+                  f.close();
+                  f = 
+                  open(os.path.expanduser(os.path.expandvars(\"}\minted at argone@esc\detokenize{\")),
+                   \"rb\");
+                  hasher.update(f.read());
+                  f.close();
+                  f = 
+                  open(os.path.expanduser(os.path.expandvars(\"}\minted at tmpfname@esc.mintedmd5\detokenize{\")),
+                   \"w\");
+                  macro = \"\\edef\\minted at hash\" + chr(123) + hasher.hexdigest() 
+                  + chr(125) + \"\";
+                  f.write(\"\\makeatletter\" + macro + 
+                  \"\\makeatother\\endinput\n\");
+                  f.close();"}}%
+              \ShellEscape{\minted at hashcmd}%
+              \minted at input{\minted at outputdir\minted at jobname.mintedmd5}%
+            \else
+              \ifthenelse{\equal{\minted at get@opt{autogobble}{false}}{true}}%
+               {\edef\minted at hash{\mdfivesum file {#1}%
+                  \mdfivesum{\minted at cmd autogobble(\ifx\FancyVerbStartNum\z@ 
+                  0\else\FancyVerbStartNum\fi-\ifx\FancyVerbStopNum\z@ 
+                  0\else\FancyVerbStopNum\fi)}}}%
+               {\edef\minted at hash{\mdfivesum file {#1}%
+                  \mdfivesum{\minted at cmd}}}%
+            \fi
+          \fi
+          \edef\minted at infile{\minted at cachedir/\minted at hash.pygtex}%
+          \edef\minted at temp@infileHTML{\minted at cachedir/\minted at hash.html}%
+          \global\cslet{minted at infileHTML\the\c at minted@pygmentizecounter}{\minted at temp@infileHTML}%
+          %\global\edef\minted at infilePNG{\minted at cachedir/\minted at hash.png}%
+          %\global\edef\minted at infileSVG{\minted at cachedir/\minted at hash.svg}%
+          \IfFileExists{\minted at infile}{}{%
+            \ifthenelse{\equal{\minted at get@opt{autogobble}{false}}{true}}{%
+              \minted at autogobble{#1}}{}%
+            \ShellEscape{\minted at cmd}%
+            \ShellEscape{\minted at cmdHTML}%
+            %\ShellEscape{\minted at cmdPNG}%
+            %\ShellEscape{\minted at cmdSVG}%
+            }%
+        \fi
+        \ifthenelse{\boolean{minted at finalizecache}}%
+         {%
+            \edef\minted at cachefilename{listing\arabic{minted at pygmentizecounter}.pygtex}%
+            \edef\minted at actualinfile{\minted at cachedir/\minted at cachefilename}%
+            \ifwindows
+              \StrSubstitute{\minted at infile}{/}{\@backslashchar}[\minted at infile@windows]
+              \StrSubstitute{\minted at actualinfile}{/}{\@backslashchar}[\minted at actualinfile@windows]
+              \ShellEscape{move /y 
+              \minted at outputdir\minted at infile@windows\space\minted at outputdir\minted at actualinfile@windows}%
+            \else
+              \ShellEscape{mv -f 
+              \minted at outputdir\minted at infile\space\minted at outputdir\minted at actualinfile}%
+            \fi
+            \let\minted at infile\minted at actualinfile
+            \expandafter\minted at addcachefile\expandafter{\minted at cachefilename}%
+         }%
+         {\ifthenelse{\boolean{minted at frozencache}}%
+           {%
+              \edef\minted at cachefilename{listing\arabic{minted at pygmentizecounter}.pygtex}%
+              \edef\minted at infile{\minted at cachedir/\minted at cachefilename}%
+              \expandafter\minted at addcachefile\expandafter{\minted at cachefilename}}%
+           {\expandafter\minted at addcachefile\expandafter{\minted at hash.pygtex}}%
+         }%
+        \minted at inputpyg}%
+      {%
+        \ifthenelse{\equal{\minted at get@opt{autogobble}{false}}{true}}{%
+          \minted at autogobble{#1}}{}%
+        \ShellEscape{\minted at cmd}%
+        \ShellEscape{\minted at cmdHTML}%
+        %\ShellEscape{\minted at cmdPNG}%
+        %\ShellEscape{\minted at cmdSVG}%
+        \minted at inputpyg}%
+  }%
+}{}%
+}%
+\html at action@newcommand{inputminted}[3][]{%
+  \message{moodle.sty: Processing \string\inputminted[#1]{#2}{#3} for HTML ^^J}%
+  % arguments #2 and #3 are thrown away: the job is done previously by minted when
+  % calling pygmentize. The file |\minted at infileHTML| generated with our hack will be used.
+  % Since minted is based upon `fvextra' the macro |\moodle at VerbatimInput| works here.
+  \minted at configlang{#2}% grab options set for this specific language
+  \setkeys{minted at opt@cmd}{#1}% grab options in #1
+  \minted at fvset% import options 
+  \stepcounter{moodle at pygmentizecounter}
+  \xa\moodle at VerbatimInput\xa{\csname minted at infileHTML\the\c at moodle@pygmentizecounter\endcsname}%
+}%
+%    \end{macrocode}
 %
+% \subsection{Warning users of \texttt{babel}}
+% Users of the |babel| package loaded with the 'french' option may experience problems
+% related to autospacing when using |pdfLaTeX|. We shall warn them.
+%    \begin{macrocode}
+\AtBeginDocument{%
+  \ifPDFTeX % pdflatex or latex
+    \@ifpackagewith{babel}{french}{%
+      \PackageWarning{moodle}{Be careful when using LaTeX, moodle, and the babel package with option 'french'. Autospacing produces in undesired symbols in the XML. You can either 1) compile with xelatex/lualatex or 2) add '\NoAutoSpacing' after '\begin{quiz}'.}%
+    }{\relax}%
+  \fi
+}%
+%    \end{macrocode}
+% 
+%
 % \Finale
 \endinput

Modified: trunk/Master/texmf-dist/source/latex/moodle/moodle.ins
===================================================================
--- trunk/Master/texmf-dist/source/latex/moodle/moodle.ins	2021-01-05 22:04:49 UTC (rev 57333)
+++ trunk/Master/texmf-dist/source/latex/moodle/moodle.ins	2021-01-05 22:05:39 UTC (rev 57334)
@@ -1,5 +1,6 @@
 %% moodle.ins
-%% Copyright 2016 by Anders O.F. Hendrickson
+%% Copyright 2016 by Anders O.F. Hendrickson and 2019-2021
+%% by Matthieu Guerquin-Kern.
 %%
 %% This work may be distributed and/or modified under the
 %% conditions of the LaTeX Project Public License, either version 1.3
@@ -11,7 +12,7 @@
 %%
 %% This work has the LPPL maintenance status `maintained'.
 %% 
-%% The Current Maintainer of this work is Anders O.F. Hendrickson.
+%% The Current Maintainer of this work is Matthieu Guerquin-Kern.
 %%
 %% This work consists of the files moodle.dtx and moodle.ins
 %% and the derived file moodle.sty.
@@ -25,7 +26,8 @@
 
 This is a generated file.
 
-Copyright (C) 2016 by Anders Hendrickson <anders.hendrickson at snc.edu>
+Copyright 2016 by Anders O.F. Hendrickson (anders.o.f.hendrickson AT gmail.com)
+and 2019-2021 by Matthieu Guerquin-Kern (guerquin-kern AT crans.org).
 
 This work may be distributed and/or modified under the
 conditions of the LaTeX Project Public License, either version 1.3

Modified: trunk/Master/texmf-dist/tex/latex/moodle/moodle.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/moodle/moodle.sty	2021-01-05 22:04:49 UTC (rev 57333)
+++ trunk/Master/texmf-dist/tex/latex/moodle/moodle.sty	2021-01-05 22:05:39 UTC (rev 57334)
@@ -8,7 +8,8 @@
 %% 
 %% This is a generated file.
 %% 
-%% Copyright (C) 2016 by Anders Hendrickson <anders.hendrickson at snc.edu>
+%% Copyright 2016 by Anders O.F. Hendrickson (anders.o.f.hendrickson AT gmail.com)
+%% and 2019-2021 by Matthieu Guerquin-Kern (guerquin-kern AT crans.org).
 %% 
 %% This work may be distributed and/or modified under the
 %% conditions of the LaTeX Project Public License, either version 1.3
@@ -20,15 +21,37 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}[1999/12/01]
 \ProvidesPackage{moodle}
-    [2016/01/11 v0.5 Moodle quiz XML generation]
+    [2021/01/04 v0.8 Moodle quiz XML generation]
 \newif\ifmoodle at draftmode
+\newif\ifmoodle at handout
+\newif\ifmoodle at stampmode
+\newif\ifmoodle at tikz
 \newif\ifmoodle at tikzloaded
+\newif\ifmoodle at svg
+\newif\ifmoodle at section
+\newif\ifmoodle at subsection
+\newif\ifmoodle at numbered
 
 %%DECLARATION OF OPTIONS
 \DeclareOption{draft}{\moodle at draftmodetrue}
+\DeclareOption{handout}{\moodle at handouttrue}
+\DeclareOption{final}{\moodle at draftmodefalse}
+\DeclareOption{nostamp}{\moodle at stampmodefalse}
+\DeclareOption{tikz}{\moodle at tikztrue}
+\DeclareOption{svg}{\moodle at svgtrue}
+\DeclareOption{section}{\moodle at sectiontrue\moodle at numberedtrue}
+\DeclareOption{section*}{\moodle at sectiontrue\moodle at numberedfalse}
+\DeclareOption{subsection}{\moodle at sectionfalse\moodle at numberedtrue}
+\DeclareOption{subsection*}{\moodle at sectionfalse\moodle at numberedfalse}
 
 \moodle at draftmodefalse
+\moodle at handoutfalse
+\moodle at stampmodetrue
+\moodle at tikzfalse
 \moodle at tikzloadedfalse
+\moodle at svgfalse
+\moodle at subsectiontrue
+\moodle at numberedfalse
 
 \ProcessOptions
 
@@ -35,21 +58,41 @@
 \RequirePackage{environ} %To be able to take environment body as a macro argument
 \RequirePackage{xkeyval} %For key-handling
 \RequirePackage{amssymb} %For \checkmark symbol
-\RequirePackage{trimspaces} %To remove extra spaces from strings
 \RequirePackage{etex}    %Expansion control, detokenization, etc.
 \RequirePackage{etoolbox}%List management
 \RequirePackage{xpatch}  %To patch commands easily in HTML mode
 \RequirePackage{array}   %For formatting tables in the LaTeX mode of Clozes
 \RequirePackage{ifplatform} % To choose Ghostscript commands
-\RequirePackage{ifpdf} % Needed to know whether we can convert output from PDF to PNG
-
+\@ifpackageloaded{iftex}{}{\RequirePackage{iftex}}
+\@ifundefined{ifpdf}{\RequirePackage{ifpdf}}{}% old iftex would not define the conditional
+\RequirePackage{shellesc} %Luatex-compatible way of getting system access
+\RequirePackage{fancybox} %For fancy LaTeX tags
 \RequirePackage{getitems} %To gather the header and items
+\ifmoodle at handout
+  \RequirePackage[seed=42]{randomlist} %To randomize answers in matching questions
+\fi
+\ifmoodle at svg
+  \RequirePackage{graphicx} %To include graphics
+\fi
 
 \let\xa=\expandafter
 \def\@star{*}%
 \def\@hundred{100}%
+\def\@fifty{50}%
 \def\@moodle at empty{}%
 \def\@relax{\relax}%
+\def\@moodle at par{\par}%
+
+\@ifundefined{ifTUTeX}{
+  \newif\ifTUTeX % a new conditional starts as false
+  \ifnum 0\ifXeTeX 1\fi\ifLuaTeX 1\fi>0%
+    \TUTeXtrue
+  \fi
+}{}%
+\newif\ifpdfoutput % a new conditional starts as false
+\ifnum 0\ifTUTeX 1\fi\ifPDFTeX\ifpdf 1\fi\fi>0%
+   \pdfoutputtrue
+\fi
 \def\jobnamewithsuffixtomacro#1#2{%
   \filenamewithsuffixtomacro{#1}{\jobname}{#2}%
 }
@@ -78,9 +121,42 @@
 \newwrite\moodle at outfile
 \def\openmoodleout{%
   \immediate\openout\moodle at outfile=\outputfilename\relax
-  \writetomoodle{<?xml version="1.0" encoding="UTF-8"?>}%
+  \ifPDFTeX % latin1-based engines (pdflatex or latex)
+    \writetomoodle{<?xml version="1.0" encoding="iso-8859-1"?>}%
+  \else
+    \ifTUTeX % UTF8-based engines (XeTeX or LuaTeX)
+      \writetomoodle{<?xml version="1.0" encoding="UTF-8"?>}%
+    \else % what shall we do?
+      \writetomoodle{<?xml version="1.0" encoding="UTF-8"?>}%
+      %\stop
+    \fi
+  \fi
+  \ifmoodle at stampmode
+    \def\moodle at stamp{This file was generated on \the\year-\two at digits\month-\two at digits\day}
+    \ifPDFTeX % pdflatex or latex
+      \ifpdf % pdflatex
+        \g at addto@macro{\moodle at stamp}{ by pdfLaTeX }%
+      \else % latex
+        \g at addto@macro{\moodle at stamp}{ by LaTeX }%
+      \fi
+    \else
+      \ifXeTeX % xetex
+        \g at addto@macro{\moodle at stamp}{ by XeLaTeX }%
+      \else
+        \ifLuaTeX % luatex
+          \g at addto@macro{\moodle at stamp}{ by LuaLaTeX }%
+        \else
+          \g at addto@macro{\moodle at stamp}{ a TeX engine }%
+        \fi
+      \fi
+    \fi
+    \writetomoodle{<!-- \moodle at stamp -->}%
+    \def\moodle at stamp{running on \platformname}%
+    \g at addto@macro{\moodle at stamp}{ with the package moodle v0.8 }%
+    \writetomoodle{<!-- \moodle at stamp -->}%
+  \fi
+  \immediate\write\moodle at outfile{}%
   \writetomoodle{<quiz>}%
-  \writetomoodle{ }%
 }%
 \def\closemoodleout{%
   \writetomoodle{ }%
@@ -111,27 +187,71 @@
     \immediate\write\moodle at outfile{\moodle at indent\trim at pre@space{\test at ii}}%
   \fi
 }%
-\newenvironment{quiz}[2][]%
-  {\setkeys{moodle}{#1}%
-   \@moodle at ifgeneratexml{%
-     \openmoodleout%
-     \setcategory{#2}%
-    }{}%
-    \subsection*{#2}%
-    \begin{enumerate}%
-   }
-  {\end{enumerate}%
-   \@moodle at ifgeneratexml{\closemoodleout}{}}
-
-{\catcode`\$=12\catcode`\ =12%
-\gdef\setcategory#1{%
+{\catcode`\$=12\catcode`\ =12% in this context we cannot indent with spaces...
+\gdef\moodle at write@category at xml#1{%
+\@moodle at ifgeneratexml{%
+\writetomoodle{ }%
 \writetomoodle{<question type="category">}%
 \writetomoodle{  <category>}%
-\writetomoodle{    <text>$module$/#1</text>}%
+\writetomoodle{    <text>$course$/top/#1</text>}%
 \writetomoodle{  </category>}%
 \writetomoodle{</question>}%
 \writetomoodle{ }%
+}{}%
 }}%
+\newcommand*\@enumeratename{enumerate}%
+\newenvironment{quiz}[2][]{%
+  \setkeys{moodle}{#1}%
+  \gdef\setcategory##1{%
+    % At first call (end of \begin{quiz}) enumerate is not started yet
+    \ifx\@currenvir\@enumeratename
+      % In case no question is defined between two calls of \setcategory
+      \def\@noitemerr{\@latex at warning{Empty question list}}%
+      \end{enumerate}%
+    \fi
+    \gdef\moodle at currentcategory{##1}%
+    \moodle at write@category at xml{##1}%
+    \ifmoodle at section
+      \ifmoodle at numbered
+        \section{##1}%
+      \else
+        \section*{##1}%
+      \fi
+    \else
+      \ifmoodle at numbered
+        \subsection{##1}%
+      \else
+        \subsection*{##1}%
+      \fi
+    \fi
+    \begin{enumerate}%
+  }%
+  \gdef\setsubcategory##1{%
+    \def\@noitemerr{\@latex at warning{Empty question list}}%
+    \end{enumerate}%
+    \moodle at write@category at xml{\moodle at currentcategory/##1}%
+    \ifmoodle at section
+      \ifmoodle at numbered
+        \subsection{##1}%
+      \else
+        \subsection*{##1}%
+      \fi
+    \else
+      \ifmoodle at numbered
+        \subsubsection{##1}%
+      \else
+        \subsubsection*{##1}%
+      \fi
+    \fi
+    \begin{enumerate}%
+  }%
+  \setcategory{#2}%
+}{%
+  \end{enumerate}%
+  \let\setcategory\relax
+  \let\setsubcategory\relax
+}%
+
 \def\passvalueaftergroup#1{%
   \xa\xa\xa\gdef\xa\xa\csname moodle at remember@\string#1\endcsname\xa{\xa\def\xa#1\xa{#1}}%
   \xa\aftergroup\csname moodle at remember@\string#1\endcsname
@@ -152,6 +272,16 @@
     \fi
   }%
 }
+\AfterEndPreamble{
+  \@moodle at ifgeneratexml{%
+    \openmoodleout%
+  }{}%
+}
+\AtEndDocument{
+  \@moodle at ifgeneratexml{%
+    \closemoodleout%
+  }{}%
+}
 \def\moodleset#1{\setkeys{moodle}{#1}}%
 \def\generate at moodle@write at code{%
   \@ifnextchar*\generate at moodle@write at data\generate at moodle@write at html
@@ -174,6 +304,20 @@
   }%
 }%
 
+\def\generate at moodle@write at html@noptag#1<#2>#3{%
+\xa\gdef\csname moodle at write#1\endcsname{%
+\xa\def\xa\test at iii\xa{#3}%
+\ifx\test at iii\@moodle at empty
+\writetomoodle[2]{  <#2 format="html"><text/></#2>}%
+\else
+\xa\converttohtmlmacro\xa\moodle at htmltowrite\xa{#3}%
+\writetomoodle[2]{  <#2 format="html">}%
+\writetomoodle[4]{    <text><![CDATA[\moodle at htmltowrite]]></text>}%
+\writetomoodle[2]{  </#2>}%
+\fi
+}%
+}%
+
 \def\generate at moodle@write at data*#1<#2>#3{%
   % #1 = NAME for \moodle at writeNAME
   % #2 = HTML tag
@@ -183,13 +327,24 @@
   }%
 }%
 
+\def\generate at moodle@write at tags#1{%
+  % #1 = NAME for \moodle at writeNAME
+  % #3 = what, exactly, to write
+  \xa\gdef\csname moodle at writetags\endcsname{%
+    %\xa\xa\xdef\xa\xa\ds\xa\xa{Encountered '\string #1'}\show\ds
+    \xa\xdef\xa\test at iii\xa{\moodle at tags}%
+    \ifx\test at iii\@moodle at empty\relax\else
+      \xa\converttohtmlmacro\xa\moodle at htmltowrite\xa{\moodle at tags}%
+      \writetomoodle[2]{  <tags>}%
+      \writetomoodle[4]{    <tag><text><![CDATA[\moodle at htmltowrite]]></text></tag>}%
+      \writetomoodle[2]{  </tags>}%
+    \fi
+  }%
+}%
+
 %% QUESTIONNAME
       \define at cmdkey{moodle}[moodle@]{questionname}{}%
-      \gdef\moodle at writequestionname{%
-        \writetomoodle[2]{<name>}%
-        \writetomoodle[4]{  <text>\moodle at questionname</text>}%
-        \writetomoodle[2]{</name>}%
-      }%
+\generate at moodle@write at html@noptag{questionname}<name>{\moodle at questionname}%
 
 %% QUESTIONTEXT
       %I tried to use questiontext as a key, but it doesn't seem to work.
@@ -205,9 +360,9 @@
       \generate at moodle@write at code{questiontext}<questiontext>{\moodle at questiontext}%{%
 
 %% PENALTY FOR WRONG ATTEMPT
-      \define at cmdkey{moodle}[moodle@]{penalty}[0.1000000]{}%
+      \define at cmdkey{moodle}[moodle@]{penalty}[0.10]{}%
       \generate at moodle@write at code*{penalty}<penalty>{\moodle at penalty}%
-      \moodleset{penalty}%
+      \moodleset{penalty=0.10}%
 
 %% FEEDBACK
       % Moodle allows for feedback tailored to each question,
@@ -221,7 +376,7 @@
       \define at cmdkey{moodle}[moodle@]{feedback}[]{}%
       \generate at moodle@write at code{generalfeedback}<generalfeedback>{\moodle at feedback}%
       \generate at moodle@write at code{feedback}<feedback>{\moodle at feedback}%
-      \moodleset{feedback}%
+      \moodleset{feedback={}}%
 
 %% DEFAULT GRADE
       %The next line creates \moodle at defaultgrade,
@@ -247,6 +402,13 @@
   \moodle at writehidden%
 }%
 
+%% TAGS
+      %The next line creates \moodle at tags,
+      %which defines a "tag" (i.e., keyword) for the question.
+      %Key calls like [tags={random}] set \moodle at tags.
+      \define at cmdkey{moodle}[moodle@]{tags}[]{}%
+      \generate at moodle@write at tags{\csname moodle at tags\endcsname}%
+      \moodleset{tags}%
 
 %% FRACTION -- how much this answer is worth out of 100 percent
       \define at cmdkey{moodle}[moodle@]{fraction}[100]{}%
@@ -253,11 +415,14 @@
       %We do not create \moodle at writefraction, because the fraction occurs in
       %the XML within the answer tag, like <answer fraction="75">.
       \moodleset{fraction=100} %This sets the default.
+%% FRACTIONTOL -- the tolerance for fractions with respect to valid values
+      \define at cmdkey{moodle}[moodle@]{fractiontol}[0.1]{}%
+      \moodleset{fractiontol=0.1} %This sets the default.
 
 %% SINGLE and MULTIPLE -- for multichoice, is there 1 right answer or more than 1?
       \define at boolkey{moodle}[moodle@]{single}[true]{}%
       \generate at moodle@write at code*{single}<single>{\ifmoodle at single true\else false\fi}%
-      \moodleset{single}%
+      \moodleset{single=true}%
       %The key 'multiple' is an antonym to 'single'.
       \define at boolkey{moodle}[moodle@]{multiple}[true]{\ifmoodle at multiple\moodle at singlefalse\else\moodle at singletrue\fi}%
 
@@ -266,15 +431,15 @@
       \generate at moodle@write at code*{shuffle}<shuffleanswers>{\ifmoodle at shuffle 1\else 0\fi}%
       \moodleset{shuffle=true}%
 
-%% TO DO: CORRECTFEEDBACK
-%% TO DO: PARTIALLYCORRECTFEEDBACK
-%% TO DO: INCORRECTFEEDBACK
-%% TO DO: NUMCORRECT key
+%% TODO: CORRECTFEEDBACK
+%% TODO: PARTIALLYCORRECTFEEDBACK
+%% TODO: INCORRECTFEEDBACK
+%% TODO: NUMCORRECT key
 
 %% NUMBERING -- for numbering of multichoice questions
       \define at choicekey{moodle}{numbering}%
                        {alpha,alph,Alpha,Alph,arabic,roman,Roman,%
-                        abc,ABC,123,iii,IIII,none}[abc]{%
+                        abc,ABCD,123,iii,IIII,none}[abc]{%
                         \def\moodle at numbering{#1}%
                         \def\test@@i{#1}%
                         \ifx\test@@i\@moodle at alpha
@@ -282,9 +447,9 @@
                         \ifx\test@@i\@moodle at alph
                           \def\moodle at numbering{abc}\fi
                         \ifx\test@@i\@moodle at Alpha
-                          \def\moodle at numbering{ABC}\fi
+                          \def\moodle at numbering{ABCD}\fi
                         \ifx\test@@i\@moodle at Alph
-                          \def\moodle at numbering{ABC}\fi
+                          \def\moodle at numbering{ABCD}\fi
                         \ifx\test@@i\@moodle at arabic
                           \def\moodle at numbering{123}\fi
                         \ifx\test@@i\@moodle at roman
@@ -306,7 +471,7 @@
       \def\@moodle at roman{roman}%
       \def\@moodle at Roman{Roman}%
       \def\@moodle at abc{abc}%
-      \def\@moodle at ABC{ABC}%
+      \def\@moodle at ABCD{ABCD}%
       \def\@moodle at arabicnumbers{123}%
       \def\@moodle at iii{iii}%
       \def\@moodle at IIII{IIII}%
@@ -315,7 +480,7 @@
         \ifx\moodle at numbering\@moodle at abc
           \renewcommand\theenumii{\alph{enumii}}%
         \fi
-        \ifx\moodle at numbering\@moodle at ABC
+        \ifx\moodle at numbering\@moodle at ABCD
           \renewcommand\theenumii{\Alph{enumii}}%
         \fi
         \ifx\moodle at numbering\@moodle at arabicnumbers
@@ -331,7 +496,7 @@
           \renewcommand\labelenumii{$\bullet$~}%
         \fi
       }
-      %TO DO: * In the PDF, how should 'none' in a multi look different from
+      %TODO: * In the PDF, how should 'none' in a multi look different from
       %         short answer or numerical options?
       %       * Instead of \theenumi and \labelenumi,
       %         use \@enumdepth to automatically set the correct depth.
@@ -414,7 +579,7 @@
 
 %% RESPONSE REQUIRED
       \define at boolkey{moodle}[moodle@]{response required}[true]{}%
-      % TO DO: Make synonym 'required'
+      % TODO: Make synonym 'required'
       \generate at moodle@write at code*{responserequired}<responserequired>{\csname ifmoodle at response required\endcsname 1\else 0\fi}%
       \moodleset{response required=false}%
 
@@ -444,7 +609,7 @@
 
 %% RESPONSE TEMPLATE
       \define at key{moodle}{template}{\long\def\moodle at responsetemplate{#1}}%
-      \generate at moodle@write at code{responsetemplate}<responsetemplate>{\moodle at responsetemplate}
+      \generate at moodle@write at html@noptag{responsetemplate}<responsetemplate>{\moodle at responsetemplate}
       \moodleset{template={}}%
 %% SHOWNUMCORRECT
       \define at boolkey{moodle}[moodle@]{shownumcorrect}[true]{}%
@@ -483,20 +648,34 @@
   \fi
   \xa\xa\xa\def\xa\xa\xa#2\xa\xa\xa{\newxml}%
 }%
+
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%% TRUE/FALSE QUESTIONS %%%%%%%%%%%%%%%%%
+%% CALCULATED %%%%%%%%%%%%%%%%%%%%%%%%%%
 
 
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%% DESCRIPTION 'QUESTIONS' %%%%%%%%%%%%%
 
 
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%% CALCULATED %%%%%%%%%%%%%%%%%%%%%%%%%%
+\def\moodle at makelatextagbox#1{%
+    \Ovalbox{\tiny #1}
+    %\ovalbox{\tiny #1}
+    %\shadowbox{\tiny #1}
+}%
 
+\def\moodle at makelatextag@qtype#1{%
+  \doublebox{\tiny \textsc{#1}}
+}%
 
+\def\moodle at makelatextag@value#1#2{%
+  \moodle at makelatextagbox{\csname moodle@#1\endcsname~#2}
+}%
 
-\def\moodle at makefrontend#1{%
+\def\moodle at makelatextag@key#1{%
+  \moodle at makelatextagbox{\csname moodle@#1\endcsname}
+}%
+
+\def\moodle at marks#1{point\ifdim#1pt=1pt \else s\fi}
+
+\def\moodle at makefrontend#1#2{%
   \NewEnviron{#1}[2][]{%
     \bgroup
       \setkeys{moodle}{##1,questionname={##2}}%
@@ -503,13 +682,29 @@
       \expandafter\gatheritems\xa{\BODY}%
       \let\moodle at questionheader=\gatheredheader
       %First, the LaTeX processing
-      \item \textbf{\moodle at questionname}\par
+      \item \textbf{\moodle at questionname}
+      \ifmoodle at handout
+        \moodle at makelatextag@qtype{#1}
+      \else
+        \xa\xdef\xa\test at iii\xa{\moodle at tags}%
+        \ifx\test at iii\@moodle at empty\relax\else
+          \hfill tags: \texttt{\moodle at tags}
+        \fi
+        \par
+        \noindent
+        \moodle at makelatextag@qtype{#1}
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+        \moodle at makelatextag@value{penalty}{penalty}
+      \fi
+      #2\par
       \noindent
       \moodle at questionheader
+      \edef\moodle at generalfeedback{\expandonce\moodle at feedback}
       \csname moodle@#1 at latexprocessing\endcsname
       %Now, writing information to XML
       \@moodle at ifgeneratexml{%
         \xa\questiontext\xa{\moodle at questionheader}% Save the question text.
+        \csname write#1question\endcsname
         \bgroup
           \gdef\moodle at answers@xml{}%
           \setkeys{moodle}{feedback={}}%
@@ -516,20 +711,62 @@
           \xa\loopthroughitemswithcommand\xa{\csname save#1answer\endcsname}%
           \passvalueaftergroup{\moodle at answers@xml}%
         \egroup
-        \csname write#1question\endcsname
+        \moodle at writeanswers%
+        \moodle at writetags%
+        \writetomoodle{</question>}%
       }{}%
     \egroup
   }%
 }
+\let\description\relax% remove the meaning of existing \description and \enddescription
+\let\enddescription\relax
+\NewEnviron{description}[2][]{%
+  \bgroup
+    \setkeys{moodle}{#1,questionname={#2}}%
+    \let\moodle at questiontext=\BODY
+    \trim at spaces@in\moodle at questiontext
+    \ifx\moodle at questiontext\@empty\relax\else%
+      %First, the LaTeX processing.
+      \item \textbf{\moodle at questionname}
+      \ifmoodle at handout\else
+        \xa\xdef\xa\test at iii\xa{\moodle at tags}%
+        \ifx\test at iii\@moodle at empty\relax\else
+          \hfill tags: \texttt{\moodle at tags}%
+        \fi
+        \par
+        \noindent
+      \fi
+      \moodle at makelatextag@qtype{description}\par
+      \noindent
+      \moodle at questiontext\par
+      \ifmoodle at handout\else
+        \ifx\moodle at feedback\@empty\relax\else
+          \fbox{\parbox{\linewidth}{\emph{\moodle at feedback}}}%
+        \fi
+      \fi
+      %Now, writing information to memory.
+      \@moodle at ifgeneratexml{%
+        \writetomoodle{<question type="description">}%
+        \moodle at writecommondata
+        \moodle at writetags%
+        \writetomoodle{</question>}%
+      }{}%
+    \fi
+  \egroup
+}%
 \def\moodle at essay@latexprocessing{%
   % Moodle cannot automatically grade an essay,
   % but if the user puts \item's in, we can list them in an itemize as notes.
+  \par\noindent \emph{Notes for grader:}
+  \moodle at questionheader
   \ifnum\c at numgathereditems>0\relax
-    \par\noindent Notes: (not included in XML)
     \begin{itemize} \setlength\itemsep{0pt}\setlength\parskip{0pt}%
       \loopthroughitemswithcommand{\moodle at print@essay at answer}%
     \end{itemize}%
   \fi
+  \ifx\moodle at generalfeedback\@empty\relax\else%
+    \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+  \fi
 }
 
 \NewEnviron{essay}[2][]{%
@@ -538,13 +775,35 @@
     \expandafter\gatheritems\expandafter{\BODY}%
     \let\moodle at questionheader=\gatheredheader
     %First, the LaTeX processing.
-      \item \textbf{\moodle at questionname}\par
+      \item \textbf{\moodle at questionname}
+      \ifmoodle at handout
+        \moodle at makelatextag@qtype{essay}
+      \else
+        \xa\xdef\xa\test at iii\xa{\moodle at tags}%
+        \ifx\test at iii\@moodle at empty\relax\else
+          \hfill tags: \texttt{\moodle at tags}
+        \fi
+        \par
+        \noindent
+        \moodle at makelatextag@qtype{essay}
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+        \moodle at makelatextag@value{penalty}{penalty}
+        \moodle at makelatextag@key{responseformat}
+      \fi
+      \par
       \noindent
-      \moodle at questionheader
-      \csname moodle at essay@latexprocessing\endcsname
+      \ifx\moodle at responsetemplate\@empty\relax\else%
+        \par\noindent \emph{Template:}
+        \par\fbox{\parbox{\linewidth}{\moodle at responsetemplate}}\par
+      \fi
+      \edef\moodle at generalfeedback{\expandonce\moodle at feedback}
+      \ifmoodle at handout\else
+        \csname moodle at essay@latexprocessing\endcsname
+      \fi
     %Now, writing information to memory.
     \@moodle at ifgeneratexml{%
       \xa\questiontext\xa{\moodle at questionheader}% Save the question text.
+      \writeessayquestion
       \bgroup
         \gdef\moodle at answers@xml{}%
         %
@@ -564,12 +823,15 @@
         %
         \passvalueaftergroup{\moodle at answers@xml}%
       \egroup
-      \writeessayquestion
+      \moodle at writeanswers% The 'answers' XML really contains the grader info.
+      \moodle at writeresponsetemplate%
+      \moodle at writetags%
+      \writetomoodle{</question>}%
     }{}%
   \egroup
 }%
 
-%%%% TO DO
+%%%% TODO
 %%%% To make essay work will be tough.
 %%%% Every line from \ifnum\c at numgathereditems=0\relax through its \else and \fi,
 %%%% with the exception of
@@ -611,9 +873,6 @@
     \moodle at writeresponsefieldlines%
     \moodle at writeattachmentsallowed%
     \moodle at writeattachmentsrequired%
-    \moodle at writeanswers% The 'answers' XML really contains the grader info.
-    \moodle at writeresponsetemplate%
-  \writetomoodle{</question>}%
 }%
 
 \def\moodle at print@essay at answer#1{%
@@ -621,6 +880,7 @@
 }%
 
 \def\moodle at savegraderinfo#1{%
+  %\def\ds{#1}\show\ds
   \bgroup
     \moodle at savegraderinfo@int#1\moodle at answer@rdelim
     \passvalueaftergroup{\moodle at answers@xml}%
@@ -631,7 +891,8 @@
   \moodle at savegraderinfo@int at int%
 }%
 \def\moodle at savegraderinfo@int at int#1\moodle at answer@rdelim{%
-  \xa\converttohtmlmacro\xa\moodle at answertext@html\xa{#1}%
+  \def\moodle at answertext{#1}
+  \xa\converttohtmlmacro\xa\moodle at answertext@html\xa{\moodle at answertext}%
   %\trim at spaces@in\moodle at answertext
   \ifnum\c at numgathereditems>1\relax
     \addto at xml[6]{\moodle at answers@xml}{<li>\moodle at answertext@html</li>}%
@@ -642,15 +903,32 @@
 \def\blank{\rule{1in}{0.5pt}}%
 
 
-\moodle at makefrontend{shortanswer}%
+\moodle at makefrontend{shortanswer}{\moodle at makelatextag@shortanswer}%
 
-\def\moodle at shortanswer@latexprocessing{%
-  \begin{itemize} \setlength\itemsep{0pt}\setlength\parskip{0pt}%
-    \loopthroughitemswithcommand{\moodle at print@shortanswer at answer}%
-  \end{itemize}%
+
+\def\moodle at makelatextag@shortanswer{%
+  \csname ifmoodle at case sensitive\endcsname
+    \moodle at makelatextagbox{Case-Sensitive}\relax
+  \else
+    \moodle at makelatextagbox{Case-Insensitive}\relax
+  \fi
 }
 
+\ifmoodle at handout
+  \let\moodle at shortanswer@latexprocessing\relax
+\else
+  \def\moodle at shortanswer@latexprocessing{%
+    \begin{itemize} \setlength\itemsep{0pt}\setlength\parskip{0pt}%
+      \loopthroughitemswithcommand{\moodle at print@shortanswer at answer}%
+    \end{itemize}%
+    \ifx\moodle at generalfeedback\@empty\relax\else%
+      \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+    \fi
+  }
+\fi
+
    \def\moodle at print@shortanswer at answer#1{%
+       \let\moodle at feedback=\@empty
        \moodle at print@shortanswer at answer@int#1\@rdelim
    }%
    \newcommand\moodle at print@shortanswer at answer@int[1][]{%
@@ -659,10 +937,14 @@
    }%
    \def\moodle at print@shortanswer at answer@int at int#1\@rdelim{%
      \ifx\moodle at fraction\@hundred
-       \item #1\quad$\checkmark$%
+       \item #1$~\checkmark$%
      \else
-       \item #1\quad (\moodle at fraction\%)%
+       \moodle at checkfraction
+       \item #1$~(\moodle at fraction\%)$%
      \fi
+     \ifx\moodle at feedback\@empty\relax\else
+       \hfill \emph{$\rightarrow$ \moodle at feedback}
+     \fi
    }%
 
 \def\saveshortansweranswer#1{%
@@ -677,10 +959,14 @@
    }%
    \def\saveshortansweranswer at int@int#1\moodle at answer@rdelim{%
      \def\moodle at answertext{#1}%
+     \trim at spaces@in\moodle at answertext
+     \moodle at checkfraction
      \addto at xml[2]{\moodle at answers@xml}{<answer fraction="\moodle at fraction" format="plain_text">}%
      \addto at xml[4]{\moodle at answers@xml}{  <text>\moodle at answertext</text>}%
      \ifx\moodle at feedback\@empty\relax\else
-       \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback</p>]]></text></feedback>}%
+       \trim at spaces@in\moodle at feedback
+       \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{\moodle at feedback}%
+       \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback@html</p>]]></text></feedback>}%
      \fi
      \addto at xml[2]{\moodle at answers@xml}{</answer>}%
    }%
@@ -689,19 +975,34 @@
   \writetomoodle{<question type="shortanswer">}%
     \moodle at writecommondata%
     \moodle at writeusecase%
-    \moodle at writeanswers%
-  \writetomoodle{</question>}%
 }%
-\moodle at makefrontend{numerical}%
+\moodle at makefrontend{numerical}{\moodle at makelatextag@numerical}%
 
-\def\moodle at numerical@latexprocessing{%
-      \begin{itemize} \setlength\itemsep{0pt}\setlength\parskip{0pt}%
-        \loopthroughitemswithcommand{\moodle at print@numerical at answer}%
-      \end{itemize}%
+
+\def\moodle at makelatextag@numerical{}
+
+\AtEndPreamble{
+  \@ifpackageloaded{siunitx}{\def\moodle at printnum{\num[omit-uncertainty,copy-decimal-marker]}}{\let\moodle at printnum\trim at spaces}%
 }
 
+\ifmoodle at handout
+  \let\moodle at numerical@latexprocessing\relax
+\else
+  \def\moodle at numerical@latexprocessing{%
+    \begin{itemize} \setlength\itemsep{0pt}\setlength\parskip{0pt}%
+      \loopthroughitemswithcommand{\moodle at print@numerical at answer}%
+    \end{itemize}%
+    \ifx\moodle at generalfeedback\@empty\relax\else%
+      \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+    \fi
+  }
+\fi
+
    \def\moodle at print@numerical at answer#1{%
-       \moodle at print@numerical at answer@int#1\@rdelim
+       \let\moodle at feedback=\@empty
+       \bgroup
+         \moodle at print@numerical at answer@int#1\@rdelim
+       \egroup
    }%
    \newcommand\moodle at print@numerical at answer@int[1][]{%
      \setkeys{moodle}{#1}%
@@ -708,16 +1009,24 @@
      \moodle at print@numerical at answer@int at int%
    }%
    \def\moodle at print@numerical at answer@int at int#1\@rdelim{%
-     \ifdim0pt=\moodle at tolerance pt\relax
-       \def\moodle at numericalprint@tolerance{}%
+     \xdef\test at i{\trim at spaces{#1}}%
+     \ifx\test at i\@star
+       \item \test at i
      \else
-       \edef\moodle at numericalprint@tolerance{\noexpand\pm\moodle at tolerance}%
+       \item \moodle at printnum{#1}%
+       \ifnum\z@=\moodle at tolerance\else
+         $\,\pm\,$\moodle at printnum{\moodle at tolerance}%
+       \fi
      \fi
      \ifx\moodle at fraction\@hundred
-       \item $#1\moodle at numericalprint@tolerance\quad\checkmark$%
+       $~\checkmark$%
      \else
-       \item $#1\moodle at numericalprint@tolerance$\quad (\moodle at fraction\%)%
+       \moodle at checkfraction
+       $~(\moodle at fraction\%)$%
      \fi
+     \ifx\moodle at feedback\@empty\relax\else
+       \hfill \emph{$\rightarrow$ \moodle at feedback}%
+     \fi
    }%
 
 \def\savenumericalanswer#1{%
@@ -732,11 +1041,17 @@
    }%
    \def\savenumericalanswer at int@int#1\moodle at answer@rdelim{%
      \def\moodle at answertext{#1}%
+     \trim at spaces@in\moodle at answertext
+     \moodle at checkfraction
      \addto at xml[2]{\moodle at answers@xml}{<answer fraction="\moodle at fraction" format="plain_text">}%
      \addto at xml[4]{\moodle at answers@xml}{  <text>\moodle at answertext</text>}%
-     \addto at xml[4]{\moodle at answers@xml}{  <tolerance>\moodle at tolerance</tolerance>}%
+     \ifx\moodle at answertext\@star\else
+       \addto at xml[4]{\moodle at answers@xml}{  <tolerance>\moodle at tolerance</tolerance>}%
+     \fi
      \ifx\moodle at feedback\@empty\relax\else
-       \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback</p>]]></text></feedback>}%
+       \trim at spaces@in\moodle at feedback
+       \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{\moodle at feedback}%
+       \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback@html</p>]]></text></feedback>}%
      \fi
      \addto at xml[2]{\moodle at answers@xml}{</answer>}%
    }%
@@ -744,59 +1059,155 @@
 \gdef\writenumericalquestion{%
   \writetomoodle{<question type="numerical">}%
     \moodle at writecommondata%
-    \moodle at writeanswers%
-  \writetomoodle{</question>}%
 }%
 
-\moodle at makefrontend{multi}
+\moodle at makefrontend{multi}{\moodle at makelatextag@multi}%
 
+
+\def\moodle at makelatextag@multi{%
+  \ifmoodle at multiple
+    \moodle at makelatextagbox{Multiple}\relax%
+  \else
+    \moodle at makelatextagbox{Single}\relax%
+  \fi
+  \ifmoodle at handout\else
+    \ifmoodle at shuffle
+      \moodle at makelatextagbox{Shuffle}\relax%
+    \fi
+  \fi
+}
+
 \def\moodle at multi@latexprocessing{%
-      \moodle at countcorrectanswers
-      \begin{enumerate}\moodle at obeynumberingstyle
-                       %\renewcommand{\theenumi}{\alph{enumi}}%
-                       \setlength\itemsep{0pt}\setlength\parskip{0pt}%
-        \loopthroughitemswithcommand{\moodle at print@multichoice at answer}%
-      \end{enumerate}%
+  \moodle at countcorrectanswers%
+  \ifmoodle at handout\NewList{answerlist}\fi
+  \begin{enumerate}\moodle at obeynumberingstyle%
+    %\renewcommand{\theenumi}{\alph{enumi}}%
+    \setlength\itemsep{0pt}\setlength\parskip{0pt}%
+    \loopthroughitemswithcommand{\moodle at print@multichoice at answer}%
+    \ifmoodle at handout
+      \ifmoodle at shuffle
+        \let\moodle at multi@loop=\ForEachRandomItem
+      \else
+        \let\moodle at multi@loop=\ForEachFirstItem
+      \fi
+      \moodle at multi@loop{answerlist}{Answer}{\Answer}%
+    \fi
+  \end{enumerate}%
+  \ifmoodle at handout\else
+    \ifx\moodle at generalfeedback\@empty\relax\else%
+      \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+    \fi
+  \fi
 }
   \def\moodle at print@multichoice at answer#1{%
-    \moodle at print@multichoice at answer@int#1\@rdelim
+    \let\moodle at feedback=\@empty%
+    \moodle at print@multichoice at answer@int#1 \@rdelim%
   }%
   \newcommand\moodle at print@multichoice at answer@int[1][]{%
-    \setkeys{moodle}{fraction=0,#1}%
-    \moodle at print@multichoice at answer@int at int
+    \let\moodle at fraction\@empty%
+    \setkeys{moodle}{#1}%
+    \moodle at print@multichoice at answer@int at int%
   }%
   \def\moodle at print@multichoice at answer@int at int#1#2\@rdelim{%
     \def\test at i{#1}%
-    \ifmoodle at single
-      \ifx\test at i\@star
-        \item #2$~\checkmark$%
+    \def\test at ii{#2}%
+    \def\moodle at answertext{\item }%
+    \ifx\test at i\@star%
+      \g at addto@macro\moodle at answertext{#2}%
+      \ifmoodle at single%
+        \setkeys{moodle}{fraction=100}%
       \else
-        \item #1#2%
+        \setkeys{moodle}{fraction=\moodle at autopoints}%
       \fi
     \else
-      \ifx\test at i\@star
-        \item #2%
-        \setkeys{moodle}{fraction=\moodle at autopoints}%
-      \else
-        \item #1#2%
+      \g at addto@macro\moodle at answertext{#1#2}%
+    \fi
+    \trim at spaces@in\moodle at answertext%
+    \trim at spaces@in\moodle at answertext%
+    \ifmoodle at handout\else
+      \ifmoodle at single%
+        \ifx\moodle at fraction\@empty\relax%
+          \setkeys{moodle}{fraction=0}%
+        \fi
+        \ifx\moodle at fraction\@hundred%
+          \trim at spaces@in\moodle at answertext%
+          \g at addto@macro\moodle at answertext{$~\checkmark$}%
+        \else
+          \moodle at checkfraction
+          \ifdim0pt=\moodle at fraction pt\relax\else%
+            \g at addto@macro\moodle at answertext{$~(\moodle at fraction\%)$}%
+          \fi
+        \fi
+      \else% multiple
+        \ifx\moodle at fraction\@empty\relax%
+          \setkeys{moodle}{fraction=\moodle at autosanctions}%
+        \fi
+        \moodle at checkfraction
+        \g at addto@macro\moodle at answertext{$~(\moodle at fraction\%)$}%
       \fi
-      $~(\moodle at fraction\%)$
     \fi
+    \ifmoodle at handout
+      \def\temp{\InsertLastItem{answerlist}}%
+      \xa\temp\xa{\moodle at answertext}%
+    \else
+      \ifx\moodle at feedback\@empty\relax\else%
+        \g at addto@macro\moodle at answertext{\hfill \emph{$\rightarrow$ \moodle at feedback}}%
+      \fi
+      \moodle at answertext
+    \fi
   }%
 
-   \newcounter{moodle at numcorrectanswers}%
+   \newcounter{moodle at numcorrectanswers}% count the stars
+   \newcounter{moodle at numincorrectanswers}% count the items without fraction key indicated
    \newlength{\moodle at pointspercorrect}%
+   \newlength{\moodle at pointsperincorrect}%
+   \newlength{\moodle at sumofpositivefractions}% sums user-set positive fractions
+   \newlength{\moodle at sumofnegativefractions}% sums user-set negative fractions
    \def\moodle at countcorrectanswers{%
      \setcounter{moodle at numcorrectanswers}{0}%
+     \setcounter{moodle at numincorrectanswers}{0}%
      \global\setlength{\moodle at pointspercorrect}{100pt}%
+     \global\setlength{\moodle at pointsperincorrect}{-100pt}%
+     \global\setlength{\moodle at sumofpositivefractions}{0pt}%
+     \global\setlength{\moodle at sumofnegativefractions}{0pt}%
      \loopthroughitemswithcommand{\moodle at countcorrectanswers@a}%
-     \ifnum0=\c at moodle@numcorrectanswers\relax
-       \PackageError{moodle}{No correct answers given for multiple choice question.}{Please mark at least one answer correct.}%
-       \gdef\moodle at autopoints{0}%
+     \global\advance\moodle at pointspercorrect by-\moodle at sumofpositivefractions\relax%
+     \def\ds{\strip at pt\moodle at sumofpositivefractions}%
+     \ifnum0=\c at moodle@numcorrectanswers\relax%
+       % autopoints will never be used but we check if the sum of positive fractions is 100%
+       \ifdim\moodle at pointspercorrect<-\moodle at fractiontol pt\relax%
+         \PackageWarning{moodle}{Positive fractions sum up to more than 100 (here: \ds)}%
+       \else
+         \ifdim\moodle at pointspercorrect>\moodle at fractiontol pt\relax%
+           \PackageError{moodle}{Positive fractions sum up to less than 100 (here: \ds)}%
+         \fi
+       \fi
      \else
-       \global\divide\moodle at pointspercorrect by \c at moodle@numcorrectanswers\relax
-       \edef\moodle at autopoints{\strip at pt\moodle at pointspercorrect}%
+       \ifdim0pt<\moodle at pointspercorrect\relax\else%
+         % we have starred items so the sum of user-set positive fractions must be less than 100%
+         % otherwise, starred items would lead to penalties
+         \PackageError{moodle}{Positive fractions sum up to 100 or more (here: \ds):
+                                there is no positive points left to be given to starred items.}%
+       \fi
+       \global\divide\moodle at pointspercorrect by \c at moodle@numcorrectanswers\relax%
      \fi
+     \gdef\moodle at autopoints{\strip at pt\moodle at pointspercorrect}%
+     \global\advance\moodle at pointsperincorrect by-\moodle at sumofnegativefractions\relax%
+     \def\ds{\strip at pt\moodle at sumofnegativefractions}%
+     \ifnum0=\c at moodle@numincorrectanswers\relax%
+       % autosanctions will never be used and
+       % we do not care about the sum of negative fractions (might be less than -100)
+     \else
+       \ifdim0pt<\moodle at pointsperincorrect\relax%
+         % we have items without fractions set: to prevent auto sanctions from becoming bonuses,
+         % such items are neutralized.
+         \PackageWarning{moodle}{Negative fractions sum up to -100 or less (here: \ds):
+                                  items with no fraction key set will be considered as neutral.}%
+         \global\setlength{\moodle at pointsperincorrect}{0pt}%
+       \fi
+       \global\divide\moodle at pointsperincorrect by \c at moodle@numincorrectanswers\relax%
+     \fi
+     \gdef\moodle at autosanctions{\strip at pt\moodle at pointsperincorrect}%
    }
    \def\moodle at countcorrectanswers@a#1{%
      %The grouping is to keep key answer-specific key changes local.
@@ -805,8 +1216,11 @@
      \egroup
    }%
    \newcommand\moodle at countcorrectanswers@b[1][]{%
-     \setkeys{moodle}{fraction=0,#1}%
-     \moodle at countcorrectanswers@c%
+     %\ifx&#1&%
+       \let\moodle at fraction\@empty%
+       \setkeys{moodle}{#1}%
+       \moodle at countcorrectanswers@c%
+     %\fi
    }%
    \def\moodle at countcorrectanswers@c#1#2\moodle at answer@rdelim{%
      \def\test at i{#1}%
@@ -813,22 +1227,66 @@
      \ifx\test at i\@star
        \stepcounter{moodle at numcorrectanswers}%
      \else
-       \global\addtolength{\moodle at pointspercorrect}{-\moodle at fraction pt}%
+       \ifx\moodle at fraction\@empty\relax%
+         \stepcounter{moodle at numincorrectanswers}%
+       \else
+         \ifdim0pt<\moodle at fraction pt\relax%
+           \global\addtolength{\moodle at sumofpositivefractions}{\moodle at fraction pt}%
+         \else
+           \global\addtolength{\moodle at sumofnegativefractions}{\moodle at fraction pt}%
+         \fi
+       \fi
      \fi
    }%
-   \def\moodle at setautopoints#1pt{%
-     \gdef\moodle at autopoints{#1}%
+   \newlength{\test at fraction}%
+   \newlength{\test at lower}%
+   \newlength{\test at upper}%
+   \def\moodle at fractionerror{%
+     \def\ds{\moodle at fraction}%
+     \PackageError{moodle}{the current fraction is not a valid value (here: \ds)}%
    }
+   {\catcode`|=3\relax
+   \gdef\moodle at validfractionlist{0|5|10|11.11111|12.5|14.28571|16.66667|20|25|30|33.33333|40|50|60|66.66667|70|75|80|83.33333|90|100}}%
+   \def\moodle at isfractionnear#1{%
+     \setlength{\test at lower}{#1 pt}%
+     \addtolength{\test at lower}{-\moodle at fractiontol pt}%
+     \setlength{\test at upper}{#1 pt}%
+     \addtolength{\test at upper}{\moodle at fractiontol pt}%
+     \ifdim\test at upper>\test at fraction\relax
+       \ifdim\test at lower<\test at fraction\relax
+         \gdef\test at fractionmatched{#1}%
+       \fi
+     \fi
+   }
+   \def\moodle at checkfraction{%
+     %\def\test at i{#1}%
+     \setlength{\test at fraction}{\moodle at fraction pt}%
+     % take the absolute value
+     \ifdim0pt>\test at fraction\relax%
+       \setlength{\test at fraction}{-\moodle at fraction pt}%
+     \fi
+     % test if the fraction is an admissible value
+     \let\test at fractionmatched\@empty
+     \forlistloop{\moodle at isfractionnear}{\moodle at validfractionlist}%
+     \ifx\test at fractionmatched\@empty\relax
+       \moodle at fractionerror%
+     \fi
+     \ifdim\moodle at fraction pt<-\moodle at fractiontol pt\relax%
+       \setkeys{moodle}{fraction=-\test at fractionmatched}%
+     \else
+       \setkeys{moodle}{fraction=\test at fractionmatched}%
+     \fi
+   }
 
-
 \def\savemultianswer#1{%
   \bgroup
-    \savemultianswer at int#1\moodle at answer@rdelim
+    \savemultianswer at int#1 \moodle at answer@rdelim
     \passvalueaftergroup{\moodle at answers@xml}%
   \egroup
 }%
   \newcommand\savemultianswer at int[1][]{%
-    \setkeys{moodle}{fraction=0,#1}%
+    \let\moodle at fraction\@empty%
+    \setkeys{moodle}{#1}%
     \savemultianswer at int@int%
   }%
   \def\savemultianswer at int@int#1#2\moodle at answer@rdelim{%
@@ -843,12 +1301,23 @@
     \else
       \def\moodle at answertext{#1#2}%
     \fi
+    \ifx\moodle at fraction\@empty\relax%
+      \ifmoodle at single\relax
+        \setkeys{moodle}{fraction=0}%
+      \else% multiple
+        \setkeys{moodle}{fraction=\moodle at autosanctions}%
+      \fi
+    \fi
     \trim at spaces@in\moodle at answertext
+    \trim at spaces@in\moodle at answertext
+    \moodle at checkfraction
     \addto at xml[2]{\moodle at answers@xml}{<answer fraction="\moodle at fraction" format="html">}%
     \xa\converttohtmlmacro\xa\moodle at answertext@html\xa{\moodle at answertext}%
     \addto at xml[4]{\moodle at answers@xml}{  <text><![CDATA[<p>\moodle at answertext@html</p>]]></text>}%
     \ifx\moodle at feedback\@empty\relax\else
-      \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback</p>]]></text></feedback>}%
+      \trim at spaces@in\moodle at feedback
+      \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{\moodle at feedback}%
+      \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback@html</p>]]></text></feedback>}%
     \fi
     \addto at xml[2]{\moodle at answers@xml}{</answer>}%
   }%
@@ -859,42 +1328,322 @@
     \moodle at writesingle%
     \moodle at writeshuffle%
     \moodle at writeanswernumbering%
-    \moodle at writeanswers%
-  \writetomoodle{</question>}%
 }%
-\let\answer=\hfill
 
-\moodle at makefrontend{matching}
 
-\def\moodle at matching@latexprocessing{%
+\NewEnviron{truefalse}[2][]{%
+    \bgroup
+      \setkeys{moodle}{#1,questionname={#2}}%
+      \expandafter\gatheritems\xa{\BODY}%
+      \let\moodle at questionheader=\gatheredheader
+      %First, the LaTeX processing
+      \item \textbf{\moodle at questionname}
+      \ifmoodle at handout
+        \moodle at makelatextag@qtype{truefalse}
+      \else
+        \xa\xdef\xa\test at iii\xa{\moodle at tags}%
+        \ifx\test at iii\@moodle at empty\relax\else
+          \hfill tags: \texttt{\moodle at tags}
+        \fi
+        \par
+        \noindent
+        \moodle at makelatextag@qtype{truefalse}
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+      \fi
+      \par
+      \noindent
+      \moodle at questionheader
+      \edef\moodle at generalfeedback{\expandonce\moodle at feedback}
+      \moodle at truefalse@latexprocessing
+      %Now, writing information to XML
+      \@moodle at ifgeneratexml{%
+        \setkeys{moodle}{penalty=1}%
+        \xa\questiontext\xa{\moodle at questionheader}% Save the question text.
+        \csname writetruefalsequestion\endcsname
+        \bgroup
+          \gdef\moodle at answers@xml{}%
+          \setkeys{moodle}{feedback={}}%
+          \xa\loopthroughitemswithcommand\xa{\xa\savetruefalseanswer}%
+          \ifnum\c at numgathereditems=1\relax%
+            \setcounter{currentitemnumber}{2}%
+            \savetruefalseanswer{}
+          \fi
+          \passvalueaftergroup{\moodle at answers@xml}%
+        \egroup
+        \moodle at writeanswers%
+        \moodle at writetags%
+        \writetomoodle{</question>}%
+      }{}%
+    \egroup
+  }%
+
+
+\def\moodle at truefalse@latexprocessing{%
+  \setcounter{moodle at numcorrectanswers}{0}%
+  \begin{itemize} \setlength\itemsep{0pt}\setlength\parskip{0pt}%
+    \loopthroughitemswithcommand{\moodle at print@truefalse at answer}%
+    \ifnum\c at currentitemnumber=2%
+      \item \textbf{False}%
+    \fi
+  \end{itemize}
+  \ifmoodle at handout\else
+    \ifx\moodle at generalfeedback\@empty\relax\else%
+      \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+    \fi
+  \fi
+  \ifnum\c at moodle@numcorrectanswers=0\relax%
+    \PackageError{moodle}{No answer is explicitly marked as correct (*). Be sure one answer leads to points.}%
+  \fi
+  \ifnum\c at moodle@numcorrectanswers>1\relax%
+    \PackageError{moodle}{Two answers are explicitly marked as correct (*). Be sure only one answer leads to points.}%
+  \fi
+}
+
+   \def\moodle at print@truefalse at answer#1{% here # is all what comes after "\item", that is "[options]* text"
+       \let\moodle at feedback=\@empty
+       \moodle at print@truefalse at answer@int#1\@rdelim % add an end delimiter:
+   }%
+   \newcommand\moodle at print@truefalse at answer@int[1][]{% with the optional argument, catch options and set them as keys
+     \setkeys{moodle}{#1}%
+     \moodle at print@truefalse at answer@int at int% applies to the rest: "* text\@rdelim"
+   }%
+   \def\moodle at print@truefalse at answer@int at int#1\@rdelim{% this is just to treat appart the case where nothing follows
+     \def\test at i{#1}
+     \trim at spaces@in\test at i
+     \ifx\test at i\@empty\relax
+       \moodle at print@truefalse at answer@int at int@empty
+     \else
+       \moodle at print@truefalse at answer@int at int@int#1\@rdelim
+     \fi
+   }%
+   \def\moodle at print@truefalse at answer@int at int@empty{%
+     \ifnum\c at currentitemnumber=1%
+\def\moodle at answertext{True}%
+     \fi
+     \ifnum\c at currentitemnumber=2%
+\def\moodle at answertext{False}%
+     \fi
+     \item \textbf{\moodle at answertext}%
+     \ifmoodle at handout\else
+       \ifx\moodle at feedback\@empty\relax\else
+         ~\hfill \emph{$\rightarrow$ \moodle at feedback}%
+       \fi
+     \fi
+   }%
+   \def\moodle at print@truefalse at answer@int at int@int#1#2\@rdelim{%
+     \ifnum\c at currentitemnumber=1%
+\def\moodle at answertext{True}%
+     \fi
+     \ifnum\c at currentitemnumber=2%
+\def\moodle at answertext{False}%
+     \fi
+     \item \textbf{\moodle at answertext}%
+     \ifnum\c at currentitemnumber<3%
+       \def\test at i{#1}%
+       %\trim at spaces@in\test at i
+       \ifx\test at i\@star
+         \ifmoodle at handout\else
+           ~$\checkmark$%
+         \fi
+         \stepcounter{moodle at numcorrectanswers}%
+       \else
+         ~%
+       \fi
+       \ifmoodle at handout\else
+         \ifx\moodle at feedback\@empty\relax
+           \def\test at ii{#2}%
+           \trim at spaces@in\test at ii
+           \ifx\test at ii\@empty\relax\else
+             \ifx\test at i\@star%
+               \hfill \emph{$\rightarrow$ #2}%
+             \else%
+               \hfill \emph{$\rightarrow$ #1#2}%
+             \fi
+           \fi
+         \else
+           \hfill \emph{$\rightarrow$ \moodle at feedback}%
+         \fi
+       \fi
+     \fi
+   }%
+
+\def\savetruefalseanswer#1{%
   \bgroup
-    \let\answer=\hfill
-    \begin{enumerate}\renewcommand{\theenumi}{\alph{enumi}}\setlength\itemsep{0pt}\setlength\parskip{0pt}%
-      \loopthroughitemswithcommand{\moodle at print@matching at answer}%
-    \end{enumerate}%
+    \savetruefalseanswer at int#1\moodle at answer@rdelim
+    \passvalueaftergroup{\moodle at answers@xml}%
   \egroup
-}
-   \long\def\moodle at print@matching at answer#1{%
-     \moodle at print@matching at answer@int#1\@rdelim
+}%
+   \newcommand\savetruefalseanswer at int[1][]{%
+     \setkeys{moodle}{#1}%
+     \savetruefalseanswer at int@int%
    }%
-   \newcommand\moodle at print@matching at answer@int[1][]{%
-     \moodle at print@matching at answer@int at int\relax
+   \def\savetruefalseanswer at int@int#1\moodle at answer@rdelim{%
+     \def\test at i{#1}
+     \trim at spaces@in\test at i
+     \ifx\test at i\@empty\relax
+       \savetruefalseanswer at int@int at empty
+     \else
+       \savetruefalseanswer at int@int at int#1\moodle at answer@rdelim
+     \fi
    }%
-   \long\def\moodle at print@matching at answer@int at int#1\answer#2\@rdelim{%
-       \item #1\hfill #2%
+   \def\savetruefalseanswer at int@int at empty{%
+     \setkeys{moodle}{fraction=0}%
+     \ifnum\c at currentitemnumber=1%
+\def\moodle at answertext{true}%
+     \fi
+     \ifnum\c at currentitemnumber=2%
+\def\moodle at answertext{false}%
+     \fi
+     \ifnum\c at currentitemnumber<3%
+       \addto at xml[2]{\moodle at answers@xml}{<answer fraction="\moodle at fraction" format="plain_text">}%
+       \addto at xml[4]{\moodle at answers@xml}{  <text>\moodle at answertext</text>}%
+       \ifx\moodle at feedback\@empty\relax\else
+         \trim at spaces@in\moodle at feedback
+         \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{\moodle at feedback}%
+         \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback@html</p>]]></text></feedback>}%
+       \fi
+       \addto at xml[2]{\moodle at answers@xml}{</answer>}%
+     \fi
    }%
+   \def\savetruefalseanswer at int@int at int#1#2\moodle at answer@rdelim{%
+     \def\test at i{#1}%
+     \ifx\test at i\@star
+       \setkeys{moodle}{fraction=100}%
+     \else
+       \setkeys{moodle}{fraction=0}%
+     \fi
+     \ifnum\c at currentitemnumber=1%
+\def\moodle at answertext{true}%
+     \fi
+     \ifnum\c at currentitemnumber=2%
+\def\moodle at answertext{false}%
+     \fi
+     \ifnum\c at currentitemnumber<3%
+       \addto at xml[2]{\moodle at answers@xml}{<answer fraction="\moodle at fraction" format="plain_text">}%
+       \addto at xml[4]{\moodle at answers@xml}{  <text>\moodle at answertext</text>}%
+       \ifx\moodle at feedback\@empty\relax
+         \def\test at ii{#2}
+         \ifx\test at ii\@empty\relax\else
+           \ifx\test at i\@star
+             \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{#2}%
+           \else%
+             \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{#1#2}%
+           \fi%
+           \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback@html</p>]]></text></feedback>}%
+         \fi
+       \else
+         \trim at spaces@in\moodle at feedback
+         \xa\converttohtmlmacro\xa\moodle at feedback@html\xa{\moodle at feedback}%
+         \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback@html</p>]]></text></feedback>}%
+       \fi
+       \addto at xml[2]{\moodle at answers@xml}{</answer>}%
+     \fi
+   }%
 
+\gdef\writetruefalsequestion{%
+  \writetomoodle{<question type="truefalse">}%
+    \moodle at writecommondata%
+}%
+
+\moodle at makefrontend{matching}{\moodle at makelatextag@matching}%
+
+
+\def\moodle at makelatextag@matching{%
+  \ifmoodle at handout\else
+    \ifmoodle at draganddrop
+      \moodle at makelatextagbox{Drag and drop}\relax%
+    \fi
+    \ifmoodle at shuffle
+      \moodle at makelatextagbox{Shuffle}\relax%
+    \fi
+  \fi
+}
+
+\def\moodle at matching@latexprocessing{%
+  \bgroup
+    %\let\answer=\hfill
+    \par%\noindent
+    \ifmoodle at handout
+      \NewList{questionlist}
+      \NewList{answerlist}
+    \fi
+    \def\matching at table@text{}%
+    %  \ifnum\c at numgathereditems>2\relax%
+    \setcounter{moodle at numcorrectanswers}{0}% Here this counter is for "questions" (items on the left column)
+    \loopthroughitemswithcommand{\moodle at print@matching at answer}%
+    \ifnum\c at numgathereditems<3%
+      \PackageWarning{moodle}{Moodle expects at least three "answers" with matching type}
+    \fi
+    \ifnum\c at moodle@numcorrectanswers<2%
+      \PackageWarning{moodle}{Moodle expects at least two "questions" with the matching type}
+    \fi
+    \ifmoodle at handout
+      \ifmoodle at shuffle
+        \let\moodle at matching@loop=\ForEachRandomItem
+      \else
+        \let\moodle at matching@loop=\ForEachFirstItem
+      \fi
+      \moodle at matching@loop{questionlist}{Question}{
+        \xdef\test at i{\Question}%
+        \ExtractRandomItem{answerlist}{Answer}%
+        \ifx\test at i\@empty
+          \xdef\matching at table@text{\expandonce\matching at table@text & & $\bullet$~\expandonce\Answer\\}%
+        \else
+          \xdef\matching at table@text{\expandonce\matching at table@text\expandonce\Question~$\bullet$ & & $\bullet$~\expandonce\Answer\\}%
+        \fi
+      }%
+    \fi
+    \begin{tabular}{@{}>{\raggedleft}p{.45\linewidth}p{.1\linewidth}p{.45\linewidth}@{}}%
+      \matching at table@text
+    \end{tabular}%
+    \par
+    \ifmoodle at handout\else
+      \ifx\moodle at generalfeedback\@empty\relax\else%
+        \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+      \fi
+    \fi
+  \egroup
+}
+
+\long\def\moodle at print@matching at answer#1{%
+  \moodle at print@matching at answer@int#1 \@rdelim
+}%
+\newcommand\moodle at print@matching at answer@int[1][]{%
+  \moodle at print@matching at answer@int at int
+}%
+\long\def\moodle at print@matching at answer@int at int#1\answer#2\@rdelim{%
+  %\typeout{\string#1 \answer \string#2}%
+  \def\test at i{#1}%
+  \trim at spaces@in\test at i
+  \ifmoodle at handout
+    \ifx\test at i\@empty
+      \InsertLastItem{questionlist}{\@empty}%
+    \else
+      \InsertLastItem{questionlist}{#1}%
+    \fi
+    \InsertLastItem{answerlist}{#2}%
+  \else
+    \ifx\test at i\@empty
+      \g at addto@macro\matching at table@text{&&$\bullet$~#2\\}%
+    \else
+      \stepcounter{moodle at numcorrectanswers}%
+      \xa\g at addto@macro\xa\matching at table@text\xa{\test at i~$\bullet$&\leavevmode\cleaders\hb at xt@.44em{\hss$\cdot$\hss}\hfill\kern\z@&$\bullet$~#2\\}%
+    \fi
+  \fi
+}%
+
 \long\def\savematchinganswer#1{%
   \bgroup
-    \savematchinganswer at int#1\moodle at answer@rdelim%
+    \savematchinganswer at int#1 \moodle at answer@rdelim%
     \passvalueaftergroup{\moodle at answers@xml}%
   \egroup
 }%
    \newcommand\savematchinganswer at int[1][]{%
      \setkeys{moodle}{#1}%
-     \xa\savematchinganswer at int@int\space%
+     \savematchinganswer at int@int%\space
    }%
    \long\def\savematchinganswer at int@int#1\answer#2\moodle at answer@rdelim{%
+     %\typeout{\string#1 \answer \string#2}%
      % Note that #1 may simply be \relax.
      \def\moodle at subquestiontext{#1}%
      \def\moodle at subanswertext{#2}%
@@ -915,9 +1664,6 @@
      \else
        \addto at xml[4]{\moodle at answers@xml}{  <answer><text>\moodle at subanswertext</text></answer>}%
      \fi
-     \ifx\moodle at feedback\@empty\relax\else
-       \addto at xml[4]{\moodle at answers@xml}{  <feedback format="html"><text><![CDATA[<p>\moodle at feedback</p>]]></text></feedback>}%
-     \fi
      \addto at xml[2]{\moodle at answers@xml}{</subquestion>}%
    }%
 
@@ -928,13 +1674,11 @@
     \writetomoodle{<question type="matching">}%
   \fi
     \moodle at writecommondata%
-    \moodle at writesingle%
     \moodle at writeshuffle%
-    \moodle at writeanswernumbering%
-    \moodle at writeanswers%
-  \writetomoodle{</question>}%
 }%
 
+\newif\ifmoodle at clozemode
+\moodle at clozemodefalse
 \NewEnviron{cloze}[2][]{%
   \bgroup
     \setkeys{moodle}{default grade=1}%
@@ -942,9 +1686,30 @@
     % A cloze question won't have any \item's in it, so we just use \BODY.
     \moodle at enableclozeenvironments
     %First, the LaTeX processing.
-      \item \textbf{\moodle at questionname}\par
+      \item \textbf{\moodle at questionname}
+      \ifmoodle at handout
+        \moodle at makelatextag@qtype{cloze}
+      \else
+        \xa\xdef\xa\test at iii\xa{\moodle at tags}%
+        \ifx\test at iii\@moodle at empty\relax\else
+          \hfill tags: \texttt{\moodle at tags}
+        \fi
+        \par
+        \noindent
+        \moodle at makelatextag@qtype{cloze}
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+        \moodle at makelatextag@value{penalty}{penalty}
+      \fi
+      \par
       \noindent
       \BODY
+      \edef\moodle at generalfeedback{\expandonce\moodle at feedback}
+      %\csname moodle at cloze@latexprocessing\endcsname
+      \ifmoodle at handout\else
+        \ifx\moodle at generalfeedback\@empty\relax\else%
+          \fbox{\parbox{\linewidth}{\emph{\moodle at generalfeedback}}}%
+        \fi
+      \fi
     %Now, writing information to memory.
     \@moodle at ifgeneratexml{%
       \xa\questiontext\xa{\BODY}% Save the question text as HTML.
@@ -965,6 +1730,7 @@
 \gdef\writeclozequestion{%
   \writetomoodle{<question type="cloze">}%
     \moodle at writecommondata%
+    \moodle at writetags%
   \writetomoodle{</question>}%
 }%
 
@@ -979,40 +1745,87 @@
       \def\moodle at clozemulti@output{}%
       \xa\g at addto@macro\xa\moodle at clozemulti@output\xa{\moodle at questionheader}%
       \def\clozemulti at coding{}%
-      \edef\clozemulti at coding{\otherlbrace\csname moodle at default grade\endcsname:}%
+      \edef\clozemulti at coding{\csname moodle at default grade\endcsname:}%
+      \ifmoodle at multiple
+        \PackageWarning{moodle}{Cloze Multiresponse only supported by Moodle 3.5+}
+        \g at addto@macro{\clozemulti at coding}{MULTIRESPONSE}%
+      \else
+        \g at addto@macro{\clozemulti at coding}{MULTICHOICE}%
+      \fi
       \ifcase\moodle at multi@mode\relax
-        % Case 0: dropdown box style
-        \g at addto@macro{\clozemulti at coding}{MULTICHOICE:}%
+         % Case 0: dropdown box style
+         \ifmoodle at shuffle
+           \g at addto@macro{\clozemulti at coding}{_}%
+         \fi
       \or
         % Case 1: vertical style
-        \g at addto@macro{\clozemulti at coding}{MULTICHOICE_V:}%
+        \ifmoodle at multiple
+          \PackageError{moodle}{Vertical mode (dropdown box) incompatible with multiresponse.}
+        \else
+          \g at addto@macro{\clozemulti at coding}{_V}%
+        \fi
       \else
         % Case 2: horizontal radio buttons
-        \g at addto@macro{\clozemulti at coding}{MULTICHOICE_H:}%
+        \g at addto@macro{\clozemulti at coding}{_H}%
       \fi
+      \ifmoodle at shuffle
+        \PackageWarning{moodle}{Cloze Multi Shuffling only supported by Moodle 3.0+}
+        \g at addto@macro{\clozemulti at coding}{S:}%
+      \else
+        \g at addto@macro{\clozemulti at coding}{:}%
+      \fi
       \bgroup
         \setkeys{moodle}{feedback={}}%
         \loopthroughitemswithcommand{\saveclozemultichoiceanswer}%
       \egroup
-      \xa\g at addto@macro\xa\clozemulti at coding\xa{\otherrbrace}%
-      \xa\g at addto@macro\xa\moodle at clozemulti@output\xa{\clozemulti at coding}%
+      %\xa\g at addto@macro\xa\clozemulti at coding\xa{\clozerbrace}%
+      \xa\g at addto@macro\xa\moodle at clozemulti@output\xa{\xa\clozelbrace\clozemulti at coding\clozerbrace}%
+      %\show\moodle at clozemulti@output
       \xa\gdef\xa\htmlize at afteraction@hook\xa{\moodle at clozemulti@output}%
       \def\endclozemulti at code{\htmlize at patchendenvironment}%
     \else
       %LaTeX version
       \moodle at questionheader% %Any introductory text just continues to be typeset.
+      \par
+      \noindent
+      \moodle at makelatextag@qtype{multi}
+      \ifmoodle at handout\else
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+        \moodle at makelatextag@multi
+      \fi
       \def\cloze at multichoice@table at text{}%
+      \ifmoodle at handout\NewList{answerlist}\fi
+      %\let\moodle at feedback=\@empty
       \loopthroughitemswithcommand{\moodle at print@clozemultichoice at answer}%
+      \ifmoodle at handout
+        \ifmoodle at shuffle
+          \let\moodle at clozemult@loop=\ForEachRandomItem
+        \else
+          \let\moodle at clozemult@loop=\ForEachFirstItem
+        \fi
+        \moodle at clozemult@loop{answerlist}{Answer}{
+          \xdef\cloze at multichoice@table at text{\expandonce\cloze at multichoice@table at text\expandonce\Answer}%
+        }%
+      \fi
       \ifcase\moodle at multi@mode\relax
         %Case 0: dropdown box style
-        \begin{tabular}[t]{|l|}\firsthline% (\firsthline is from the array package.)
+        \par\noindent
+        \ifmoodle at handout
+          \begin{tabular}[t]{|p{.45\linewidth}|}
+        \else
+          \begin{tabular}[t]{|p{.45\linewidth}|p{.45\linewidth}|}
+        \fi
+          \firsthline% (\firsthline is from the array package.)
           \cloze at multichoice@table at text%
         \end{tabular}%
+        \par%
       \or
         %Case 1: vertical style
+        \par\noindent
         \begin{itemize}\setlength\itemsep{0pt}\setlength\parskip{0pt}%
           \cloze at multichoice@table at text%
         \end{itemize}%
+        \par%
       \else
         %Case 2: horizontal radio buttons
         \par{\cloze at multichoice@table at text}\par%
@@ -1025,12 +1838,15 @@
 }[\endclozemulti at code]%
 
 \def\moodle at print@clozemultichoice at answer#1{%
-  \moodle at print@clozemultichoice at answer@int#1\@rdelim%
+  \let\moodle at feedback=\@empty
+  \moodle at print@clozemultichoice at answer@int#1 \@rdelim%
 }%
 \newcommand\moodle at print@clozemultichoice at answer@int[1][]{%
+  \setkeys{moodle}{fraction=0,#1}%
   \moodle at print@clozemultichoice at answer@int at int%
 }%
 \def\moodle at print@clozemultichoice at answer@int at int#1#2\@rdelim{%
+  \def\moodle at answertext{}%
   % Case 0: "(answer) \\ \hline"
   % Case 1: "\item (answer)"
   % Case 2: "$\bullet~$(answer)\hfill"
@@ -1037,28 +1853,60 @@
   \ifcase\moodle at multi@mode\relax
     \relax% Case 0
   \or
-    \g at addto@macro\cloze at multichoice@table at text{\item}% Case 1
+    \g at addto@macro\moodle at answertext{\item}% Case 1
   \else
-    \g at addto@macro\cloze at multichoice@table at text{$\bullet~$}% Case 2
+    \g at addto@macro\moodle at answertext{$\bullet~$}% Case 2
   \fi
   \def\test at i{#1}%
   \ifx\test at i\@star
-     \g at addto@macro\cloze at multichoice@table at text{#2$~\checkmark$}%
+    \setkeys{moodle}{fraction=100}%
+    \g at addto@macro\moodle at answertext{#2}%
   \else
-     \g at addto@macro\cloze at multichoice@table at text{#1#2}%
+    \g at addto@macro\moodle at answertext{#1#2}%
   \fi
+  \trim at spaces@in\moodle at answertext
+  \trim at spaces@in\moodle at answertext
+  \ifmoodle at handout\else
+    \ifx\moodle at fraction\@hundred
+      \g at addto@macro\moodle at answertext{$~\checkmark$}%
+    \else
+      \moodle at checkfraction
+      \ifdim0pt=\moodle at fraction pt\relax\else
+        \xdef\moodle at answertext{\expandonce\moodle at answertext$~(\moodle at fraction\%)$}%
+      \fi
+    \fi
+  \fi
   \ifcase\moodle at multi@mode\relax
-    \g at addto@macro{\cloze at multichoice@table at text}{\\ \hline}% Case 0
-  \or
-    \relax% Case 1
+  % Case 0
+    \ifmoodle at handout\else
+      \xdef\moodle at answertext{\expandonce\moodle at answertext &\expandonce\emph{\expandonce\moodle at feedback}}%
+    \fi
+    \g at addto@macro\moodle at answertext{\\\hline}
+  \or % Case 1
+    \ifmoodle at handout\else
+      \ifx\moodle at feedback\@empty\relax\else
+        \xdef\moodle at answertext{\expandonce\moodle at answertext \hfill \expandonce\emph{$\rightarrow$ \expandonce\moodle at feedback}}%
+      \fi
+    \fi
+  \else % otherwise
+    \ifmoodle at handout\else
+      \ifx\moodle at feedback\@empty\relax\else
+        \xdef\moodle at answertext{\expandonce\moodle at answertext\,\expandonce\emph{$\rightarrow$ \expandonce\moodle at feedback}}%
+      \fi
+    \fi
+    \g at addto@macro\moodle at answertext{\hfill}% Case 2
+  \fi
+  \ifmoodle at handout
+    \def\temp{\InsertLastItem{answerlist}}%
+    \xa\temp\xa{\moodle at answertext}%
   \else
-    \g at addto@macro{\cloze at multichoice@table at text}{\hfill}% Case 2
+    \xdef\cloze at multichoice@table at text{\expandonce\cloze at multichoice@table at text\expandonce\moodle at answertext}%
   \fi
 }%
 
 \def\saveclozemultichoiceanswer#1{%
   \bgroup
-    \saveclozemultichoiceanswer at int#1\moodle at answer@rdelim
+    \saveclozemultichoiceanswer at int#1 \moodle at answer@rdelim
   \egroup
 }%
 \newcommand\saveclozemultichoiceanswer at int[1][]{%
@@ -1077,17 +1925,18 @@
     \def\moodle at answertext{#1#2}%
   \fi
   \trim at spaces@in\moodle at answertext
+  \trim at spaces@in\moodle at answertext
   \ifx\moodle at fraction\@hundred
     \g at addto@macro\clozemulti at coding{=}%
-  \fi
-  \ifnum0<\moodle at fraction\relax
-    \ifnum\moodle at fraction<100\relax
+  \else
+    \moodle at checkfraction
+    \ifdim0pt=\moodle at fraction pt\relax\else
       \xdef\clozemulti at coding{\expandonce\clozemulti at coding\otherpercent\moodle at fraction\otherpercent}%
     \fi
   \fi
   \xdef\clozemulti at coding{\expandonce\clozemulti at coding\expandonce\moodle at answertext}%
   \ifx\moodle at feedback\@empty\else
-    \xdef\clozemulti at coding{\expandonce\clozemulti at coding\otherbackslash\otherhash\moodle at feedback}%
+    \xdef\clozemulti at coding{\expandonce\clozemulti at coding\otherbackslash\otherhash\expandonce\moodle at feedback}%
   \fi
 }%
 \NewEnviron{clozenumerical}[1][]{%
@@ -1101,23 +1950,34 @@
       \def\moodle at clozenumerical@output{}%
       \xa\g at addto@macro\xa\moodle at clozenumerical@output\xa{\moodle at questionheader}%
       \def\clozenumerical at coding{}%
-      \edef\clozenumerical at coding{\otherlbrace\csname moodle at default grade\endcsname:NUMERICAL:}%
+      \edef\clozenumerical at coding{\csname moodle at default grade\endcsname:NUMERICAL:}%
       \bgroup
         \setkeys{moodle}{feedback={}}%
         \loopthroughitemswithcommand{\saveclozenumericalanswer}%
       \egroup
-      \xa\g at addto@macro\xa\clozenumerical at coding\xa{\otherrbrace}%
-      \xa\g at addto@macro\xa\moodle at clozenumerical@output\xa{\clozenumerical at coding}%
+      %\xa\g at addto@macro\xa\clozenumerical at coding\xa{\otherrbrace}%
+      \xa\g at addto@macro\xa\moodle at clozenumerical@output\xa{\xa\clozelbrace\clozenumerical at coding\clozerbrace}%
       \xa\gdef\xa\htmlize at afteraction@hook\xa{\moodle at clozenumerical@output}%
       \def\endclozenumerical at code{\htmlize at patchendenvironment}%
     \else
       %LaTeX version
       \moodle at questionheader% %Any introductory text just continues to be typeset.
-      \def\cloze at numerical@table at text{}%
-      \loopthroughitemswithcommand{\moodle at print@clozenumerical at answer}%
-      \begin{tabular}[t]{|ll|}\firsthline
-        \cloze at numerical@table at text\hline%
-      \end{tabular}%
+      \par
+      \noindent
+      \moodle at makelatextag@qtype{numerical}
+      \ifmoodle at handout\else
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+        \moodle at makelatextag@numerical
+        \par
+        \noindent
+        \def\cloze at numerical@table at text{}%
+        \loopthroughitemswithcommand{\moodle at print@clozenumerical at answer}%
+        \begin{tabular}[t]{|p{.45\linewidth}|p{.45\linewidth}|}
+          \firsthline% (\firsthline is from the array package.)
+          \cloze at numerical@table at text%
+        \end{tabular}%
+        \par%
+      \fi
       \def\endclozenumerical at code{\relax}%
     \fi
     \passvalueaftergroup\endclozenumerical at code%
@@ -1126,6 +1986,7 @@
 }[\endclozenumerical at code]%
 
 \def\moodle at print@clozenumerical at answer#1{%
+  \let\moodle at feedback=\@empty
   \bgroup
     \moodle at print@clozenumerical at answer@int#1\@rdelim
   \egroup
@@ -1136,17 +1997,23 @@
 }%
 \def\moodle at print@clozenumerical at answer@int at int#1\@rdelim{%
   \ifx\moodle at fraction\@hundred
-    \def\moodle at clozenumericalprint@fraction{$\checkmark$}%
+    \def\moodle at clozenumericalprint@fraction{$~\checkmark$}%
   \else
-    \edef\moodle at clozenumericalprint@fraction{(\moodle at fraction\%)}%
+    \moodle at checkfraction
+    \edef\moodle at clozenumericalprint@fraction{$(~\moodle at fraction\%)$}%
   \fi
-  \ifdim0pt=\moodle at tolerance pt\relax
+  \ifnum\z@=\moodle at tolerance
     \def\moodle at clozenumericalprint@tolerance{}%
   \else
-    \edef\moodle at clozenumericalprint@tolerance{\noexpand\pm\moodle at tolerance}%
+    \edef\moodle at clozenumericalprint@tolerance{$\,\pm\,$\moodle at printnum{\moodle at tolerance}}%
   \fi
-  \xdef\moodle at clozenumericalprint@line{$#1\moodle at clozenumericalprint@tolerance$ & \moodle at clozenumericalprint@fraction}%
-  \xa\g at addto@macro\xa\cloze at numerical@table at text\xa{\moodle at clozenumericalprint@line \\}%
+  \xdef\test at i{\trim at spaces{#1}}%
+  \ifx\test at i\@star
+    \xdef\moodle at clozenumericalprint@line{#1~\moodle at clozenumericalprint@fraction & \expandonce\emph{\expandonce\moodle at feedback}}%
+  \else
+    \xdef\moodle at clozenumericalprint@line{\moodle at printnum{#1}\moodle at clozenumericalprint@tolerance~\moodle at clozenumericalprint@fraction & \expandonce\emph{\expandonce\moodle at feedback}}%
+  \fi
+  \xa\g at addto@macro\xa\cloze at numerical@table at text\xa{\moodle at clozenumericalprint@line \\\hline}%
 }%
 
 \def\saveclozenumericalanswer#1{%
@@ -1166,15 +2033,20 @@
   \trim at spaces@in\moodle at answertext
   \ifx\moodle at fraction\@hundred
     \g at addto@macro\clozenumerical at coding{=}%
-  \fi
-  \ifnum0<\moodle at fraction\relax
-    \ifnum\moodle at fraction<100\relax
+  \else
+    \moodle at checkfraction
+    \ifdim0pt=\moodle at fraction pt\relax\else
       \xdef\clozenumerical at coding{\expandonce\clozenumerical at coding\otherpercent\moodle at fraction\otherpercent}%
     \fi
   \fi
-  \xdef\clozenumerical at coding{\expandonce\clozenumerical at coding\moodle at answertext:\moodle at tolerance}%
+  \ifx\moodle at answertext\@star
+    \xdef\clozenumerical at coding{\expandonce\clozenumerical at coding\moodle at answertext}%
+  \else
+    \xdef\clozenumerical at coding{\expandonce\clozenumerical at coding\moodle at answertext:\moodle at tolerance}%
+  \fi
   \ifx\moodle at feedback\@empty\else
-    \xdef\clozenumerical at coding{\expandonce\clozenumerical at coding\otherbackslash\otherhash\moodle at feedback}%
+    %\trim at spaces@in\moodle at feedback
+    \xdef\clozenumerical at coding{\expandonce\clozenumerical at coding\otherbackslash\otherhash\expandonce\moodle at feedback}%
   \fi
 }%
 \NewEnviron{clozeshortanswer}[1][]{%
@@ -1196,29 +2068,37 @@
       \xa\g at addto@macro\xa\moodle at clozeshortanswer@output\xa{\moodle at questionheader}%
       \def\clozeshortanswer at coding{}%
       \ifnum\count0=1\relax
-        \edef\clozeshortanswer at coding{\otherlbrace\csname moodle at default grade\endcsname:SHORTANSWER_C:}%
+        \edef\clozeshortanswer at coding{\csname moodle at default grade\endcsname:SHORTANSWER_C:}%
       \else
-        \edef\clozeshortanswer at coding{\otherlbrace\csname moodle at default grade\endcsname:SHORTANSWER:}%
+        \edef\clozeshortanswer at coding{\csname moodle at default grade\endcsname:SHORTANSWER:}%
       \fi
       \bgroup
         \setkeys{moodle}{feedback={}}%
         \loopthroughitemswithcommand{\saveclozeshortansweranswer}%
       \egroup
-      \xa\g at addto@macro\xa\clozeshortanswer at coding\xa{\otherrbrace}%
-      \xa\g at addto@macro\xa\moodle at clozeshortanswer@output\xa{\clozeshortanswer at coding}%
+      %\xa\g at addto@macro\xa\clozeshortanswer at coding\xa{\otherrbrace}%
+      \xa\g at addto@macro\xa\moodle at clozeshortanswer@output\xa{\xa\clozelbrace\clozeshortanswer at coding\clozerbrace}%
       \xa\gdef\xa\htmlize at afteraction@hook\xa{\moodle at clozeshortanswer@output}%
       \def\endclozeshortanswer at code{\htmlize at patchendenvironment}%
     \else
       %LaTeX version
       \moodle at questionheader% %Any introductory text just continues to be typeset.
-      \def\cloze at shortanswer@table at text{}%
-      \loopthroughitemswithcommand{\moodle at print@clozeshortanswer at answer}%
-      \ifnum\count0=1\relax
-        \marginpar{\tiny\mbox{(Case-Sensitive)}}%
+      \par
+      \noindent
+      \moodle at makelatextag@qtype{shortanswer}
+      \ifmoodle at handout\else
+        \moodle at makelatextag@value{default grade}{\moodle at marks{\csname moodle at default grade\endcsname}}
+        \moodle at makelatextag@shortanswer
+        \par
+        \noindent
+        \def\cloze at shortanswer@table at text{}%
+        \loopthroughitemswithcommand{\moodle at print@clozeshortanswer at answer}%
+        \begin{tabular}[t]{|p{.45\linewidth}|p{.45\linewidth}|}
+          \firsthline% (\firsthline is from the array package.)
+          \cloze at shortanswer@table at text%
+        \end{tabular}%
+        \par%
       \fi
-      \begin{tabular}[t]{|ll|}\firsthline
-        \cloze at shortanswer@table at text\hline%
-      \end{tabular}%
       \def\endclozeshortanswer at code{\relax}%
     \fi
     \passvalueaftergroup\endclozeshortanswer at code%
@@ -1227,6 +2107,7 @@
 }[\endclozeshortanswer at code]%
 
 \def\moodle at print@clozeshortanswer at answer#1{%
+  \let\moodle at feedback=\@empty
   \bgroup
     \moodle at print@clozeshortanswer at answer@int#1\@rdelim
   \egroup
@@ -1237,12 +2118,13 @@
 }%
 \def\moodle at print@clozeshortanswer at answer@int at int#1\@rdelim{%
   \ifx\moodle at fraction\@hundred
-    \def\moodle at clozeshortanswerprint@fraction{$\checkmark$}%
+    \def\moodle at clozeshortanswerprint@fraction{$~\checkmark$}%
   \else
-    \edef\moodle at clozeshortanswerprint@fraction{(\moodle at fraction\%)}%
+    \moodle at checkfraction
+    \edef\moodle at clozeshortanswerprint@fraction{$~(\moodle at fraction\%)$}%
   \fi
-  \xdef\moodle at clozeshortanswerprint@line{#1 & \moodle at clozeshortanswerprint@fraction}%
-  \xa\g at addto@macro\xa\cloze at shortanswer@table at text\xa{\moodle at clozeshortanswerprint@line \\}%
+  \xdef\moodle at clozeshortanswerprint@line{#1~\moodle at clozeshortanswerprint@fraction & \expandonce\emph{\expandonce\moodle at feedback}}%
+  \xa\g at addto@macro\xa\cloze at shortanswer@table at text\xa{\moodle at clozeshortanswerprint@line \\\hline}%
 }%
 
 \def\saveclozeshortansweranswer#1{%
@@ -1262,15 +2144,15 @@
   \trim at spaces@in\moodle at answertext
   \ifx\moodle at fraction\@hundred
     \g at addto@macro\clozeshortanswer at coding{=}%
-  \fi
-  \ifnum0<\moodle at fraction\relax
-    \ifnum\moodle at fraction<100\relax
+  \else
+    \moodle at checkfraction
+    \ifdim0pt=\moodle at fraction pt\relax\else
       \xdef\clozeshortanswer at coding{\expandonce\clozeshortanswer at coding\otherpercent\moodle at fraction\otherpercent}%
     \fi
   \fi
   \xdef\clozeshortanswer at coding{\expandonce\clozeshortanswer at coding\moodle at answertext}%
   \ifx\moodle at feedback\@empty\else
-    \xdef\clozeshortanswer at coding{\expandonce\clozeshortanswer at coding\otherbackslash\otherhash\moodle at feedback}%
+    \xdef\clozeshortanswer at coding{\expandonce\clozeshortanswer at coding\otherbackslash\otherhash\expandonce\moodle at feedback}%
   \fi
 }%
 {\catcode`\#=12\gdef\otherhash{#}%
@@ -1278,14 +2160,20 @@
  \catcode`\&=12\gdef\otherampersand{&}%
  \catcode`\^=12\gdef\othercaret{^}%
  \catcode`\$=12\gdef\otherdollar{$}%
- \catcode`\%=12\gdef\otherpercent{%}}%
+ \catcode`\%=12\gdef\otherpercent{%}
+ \catcode`\%=12\gdef\otherlbracket{[}
+ \catcode`\%=12\gdef\otherrbracket{]}}%
 {\catcode`\ =12\gdef\otherspace{ }}%
-{\tt\catcode`\|=0\catcode`\\=12\relax|gdef|otherbackslash{\}}%
+{\ttfamily\catcode`\|=0\catcode`\\=12\relax|gdef|otherbackslash{\}}%
 {\catcode`\[=1\catcode`\]=2\catcode`\{=12\catcode`\}=12%
- \gdef\otherlbrace[{]\gdef\otherrbrace[}]]
+ \gdef\otherlbrace[{]\gdef\otherrbrace[}]\gdef\clozelbrace[{]\gdef\clozerbrace[}]]%
 
 \edef\@otherlbrace{\otherlbrace}%
 \edef\@otherrbrace{\otherrbrace}%
+\edef\@otherlbracket{\otherlbracket}%
+\edef\@otherrbracket{\otherrbracket}%
+\edef\@clozelbrace{\clozelbrace}%
+\edef\@clozerbrace{\clozerbrace}%
 \edef\@otherdollar{\otherdollar}%
 \edef\@otherbackslash{\otherbackslash}%
 \edef\@othertilde{\othertilde}%
@@ -1362,6 +2250,7 @@
 \def\retokenizenormal at to@macro#1#2{%
   \scantokens at to@macro#1{\retokenizingcatcodes}{#2}%
 }%
+\newcount\grouplevel
 \newcount\moodle at mathmodedepth
 \moodle at mathmodedepth=0\relax
 \def\moodle at ifmathmode#1#2{%
@@ -1370,12 +2259,10 @@
   \else
     #2%
   \fi
-}
+}%
+\newcount\moodle at listdepth
+\moodle at listdepth=0\relax
 
-\newcount\grouplevel
-
-\newif\ifhtmlizer at active
-\htmlizer at activefalse
 \long\def\htmlize at grabblock#1#2\htmlize at rdelim@ii{%
   \long\def\htmlize at blockinbraces{#1}%
   \long\def\htmlize at remainder{#2}%
@@ -1382,6 +2269,8 @@
 }%
 \ultradetokenize at to@macro\@htmlize at stop@detokenized{\@htmlize at stop}%
 \xa\def\xa\htmlize at remove@stopcode\xa#\xa1\@htmlize at stop@detokenized{#1}%
+\newif\ifhtmlizer at active
+\htmlizer at activefalse
 \newif\ifhtmlize at actioncs
 \newif\ifhtmlize at expandcs
 \newif\ifhtmlize at passcs
@@ -1402,7 +2291,7 @@
   \advance\grouplevel by 1\relax
   \bgroup
     \ultradetokenize at to@macro\htmlize at texttoscan{#1}%
-    \xa\htmlize at recursive@i\htmlize at texttoscan\@htmlize at stop\@htmlize at stop\@htmlize at stop\htmlize at rdelim@i
+    \xa\htmlize at recursive@i\htmlize at texttoscan\@htmlize at stop\@htmlize at stop\@htmlize at stop\htmlize at rdelim@i%
   \egroup
   \advance\grouplevel by -1\relax
 }%
@@ -1448,7 +2337,11 @@
         \gdef\htmlize at scrap{\converttohtml at int}%
         \xa\g at addto@macro\xa\htmlize at scrap\xa{\xa{\htmlize at blockinbraces}}%
         \g at addto@macro\htmlize at scrap{\g at addto@macro\htmlize at output}%
-        \xa\g at addto@macro\xa\htmlize at scrap\xa{\xa{\otherrbrace}}%
+        \ifmoodle at clozemode
+          \xa\g at addto@macro\xa\htmlize at scrap\xa{\xa{\otherbackslash\otherrbrace}}%
+        \else
+          \xa\g at addto@macro\xa\htmlize at scrap\xa{\xa{\otherrbrace}}%
+        \fi
         \g at addto@macro\htmlize at scrap{\htmlize at recursive@i}%
         \xa\g at addto@macro\xa\htmlize at scrap\xa{\htmlize at remainder@detokenized\@htmlize at stop\@htmlize at stop\@htmlize at stop\htmlize at rdelim@i}%
         % Okay, that's done.  It's stored in a global macro.
@@ -1465,10 +2358,10 @@
           \htmlize at displaymathshift@replace#1#2#3\htmlize at rdelim@iii%
         \else
           % Single dollar sign, so we're entering inline math mode.
-          % We grab everything between $$...$$, sanitize it, and add it verbatim to
+          % We grab everything between $...$, sanitize it, and add it verbatim to
           % our output.
           \htmlize at inlinemathshift@replace#1#2#3\htmlize at rdelim@iii%
-        \fi
+        \fi% \ifx\test at ii\@otherdollar
         % Now we resume work.
         % The \htmlize at xxxxxxmathshift@replace macro stored the remaining text in \htmlize at remaining@text.
         % Note that since we never detokenized and retokenized #1#2#3,
@@ -1593,9 +2486,9 @@
                 %\edef\ds{Must pass on \xa\string\@htmlize at cs}\show\ds
                 \g at addto@macro\htmlize at output{#1}%
                 \def\htmlize at next@i{\htmlize at recursive@i#2#3\htmlize at rdelim@i}%
-              \fi
-            \fi
-          \fi
+              \fi% \ifhtmlize at expandcs
+            \fi% \ifhtmlize at actioncs
+          \fi% \ifx\@htmlize at cs\@@begin at cs
         \else%
           \ifx\test at i\@othertilde%
             % The ~ becomes non-breaking space  
@@ -1610,7 +2503,7 @@
               \else
                 \g at addto@macro\htmlize at output{\otherampersand lsquo;}%
                 \def\htmlize at next@i{\htmlize at recursive@i#2#3\htmlize at rdelim@i}%
-              \fi
+              \fi% \ifx\test at ii\@lsinglequote%
             \else
               \ifx\test at i\@rsinglequote%
                 \ifx\test at ii\@rsinglequote%
@@ -1620,7 +2513,7 @@
                 \else
                   \g at addto@macro\htmlize at output{\otherampersand rsquo;}%
                   \def\htmlize at next@i{\htmlize at recursive@i#2#3\htmlize at rdelim@i}%
-                \fi
+                \fi% \ifx\test at ii\@rsinglequote%
               \else
                 \ifx\test at i\@doublequote
                   \g at addto@macro\htmlize at output{\otherampersand rdquo;}%
@@ -1639,16 +2532,16 @@
                       % Default case: write first token to output, call self on remaining tokens.
                       \g at addto@macro\htmlize at output{#1}%
                       \def\htmlize at next@i{\htmlize at recursive@i#2#3\htmlize at rdelim@i}%
-                    \fi
-                  \fi
-                \fi
-              \fi
-            \fi
-          \fi
-        \fi
-      \fi
-    \fi
-  \fi
+                    \fi% \ifx\test at i\@gt
+                  \fi% \ifx\test at i\@lt
+                \fi% \ifx\test at i\@doublequote
+              \fi% \ifx\test at i\@rsinglequote%
+            \fi% \ifx\test at i\@lsinglequote%
+          \fi% \ifx\test at i\@othertilde%
+        \fi% \ifx\test at i\@otherbackslash%
+      \fi% \ifx\test at i\@otherdollar%
+    \fi% \ifx\test at i\@otherlbrace%
+  \fi% \ifx\test at i\@@htmlize at stop
   \htmlize at next@i
 }%
 
@@ -1658,16 +2551,38 @@
 \edef\inlinemathleftdelim{\otherbackslash(}%
 \def\inlinemathrightdelim#1{\advancemathmodecounter{-1}%
                             \g at addto@macro\htmlize at output{\otherbackslash)}}%
-\edef\displaymathleftdelim{<CENTER>\otherbackslash[}%
+\edef\displaymathleftdelim{\otherbackslash[}%
 \def\displaymathrightdelim#1{\advancemathmodecounter{-1}%
-                             \g at addto@macro\htmlize at output{\otherbackslash]</CENTER>}}%
+                             \g at addto@macro\htmlize at output{\otherbackslash]}}%
+\long\def\htmlize at inlinemath@recursive at i#1#2#3\htmlize at rdelim@i{%
+  % inspired by \htmlize at recursive@i
+  \def\test at i{#1}%
+  \ifx\test at i\@@htmlize at stop
+    \let\htmlize at next@i=\relax
+  \else
+    \ifx\test at i\@otherbackslash
+        \g at addto@macro\mathtext{#1#2}%
+        \def\htmlize at next@i{\xa\htmlize at inlinemath@recursive at i#3\htmlize at rdelim@i}%
+    \else
+      \ifx\test at i\@otherdollar
+        \let\htmlize at next@i=\relax
+        \g at addto@macro\aftertext{#2#3}%
+      \else
+        \g at addto@macro\mathtext{#1}%
+        \def\htmlize at next@i{\xa\htmlize at inlinemath@recursive at i#2#3\htmlize at rdelim@i}%
+      \fi
+    \fi
+  \fi
+  \htmlize at next@i
+}
 {\catcode`\$=12\relax%
-  \gdef\htmlize at inlinemathshift@replace$#1$#2\htmlize at rdelim@iii{%
+  \gdef\htmlize at inlinemathshift@replace#1#2\htmlize at rdelim@iii{%
     %\def\ds{inline math shift has '#1' and '#2'}\show\ds
     \xa\g at addto@macro\xa\htmlize at output\xa{\inlinemathleftdelim}%
     \advancemathmodecounter{1}%
-    \def\mathtext{#1}%
-    \def\aftertext{#2}%
+    \gdef\mathtext{}%
+    \gdef\aftertext{}%
+    \htmlize at inlinemath@recursive at i#2\htmlize at rdelim@i%
     \xdef\htmlize at remaining@text{\expandonce\mathtext%
                                  \otherbackslash inlinemathrightdelim{}%
                                  \expandonce\aftertext}%
@@ -1683,6 +2598,7 @@
                                  \expandonce\aftertext}%
   }%
 }
+
 \long\def\htmlize at do@actionenv#1#2\@htmlize at stop\htmlize at actionsequence@rdelim{%
   \bgroup %The corresponding \egroup is given in \htmlize at proceedwiththerest,
           %to localize the changes to the environment definitions.
@@ -1760,11 +2676,41 @@
   \xa\g at addto@macro\xa\htmlize at activate@css\xa{\htmlize at scrap}%
   \xa\def\csname html@\string#1\endcsname% %And this \def\html@\oldcsname is follows by the remainder of the definition.
 }
+\def\html at action@newcommand#1[#2][#3]#4{%
+  %\message{>>> Defining #1[#2][#3]{...} ^^J}
+  \ifmoodle at draftmode
+  \else
+    \xa\html at action@def\csname #1\endcsname{\csname moodle@#1 at int\endcsname}%
+  \fi
+  % Note that \htmlize at do@actioncs will 'patch' this by putting
+  % '\xa\htmlize at proceedwiththerest\htmlize at afteraction@hook'
+  % at the end.  We want those 3 tokens to occur instead after
+  % the graphics filename.
+  \xa\csdef{moodle@#1 at int}##1##2##3{\csname moodle@#1 at int@int\endcsname}%
+  % This gobbles up those three spurious tokens,
+  % which we will re-insert after our work is done.
+  \xa\newcommand\csname moodle@#1 at int@int\endcsname[#2][#3]{%
+    #4%
+    % Now we re-insert the code to get the HTMLizing going again.
+    \xa\htmlize at proceedwiththerest\htmlize at afteraction@hook
+  }%
+}
 \def\htmlize at redefine@expansionmacros{}%
 \long\def\htmlize at record@expand#1{%
   \xa\listadd\xa\htmlize at cs@expandlist\xa{\string#1}%
 }
 \let\htmlregister=\htmlize at record@expand
+\def\moodleregisternewcommands{%
+  %% INSPIRED FROM
+  %https://tex.stackexchange.com/questions/73271/how-to-redefine-or-patch-the-newcommand-command
+  \newcommand*{\saved at ifdefinable}{}
+  \let\saved at ifdefinable\@ifdefinable
+  \renewcommand{\@ifdefinable}[2]{%
+    \saved at ifdefinable{##1}{##2}%
+    \htmlregister{##1}
+  }%
+  \let\@@ifdefinable\@ifdefinable
+}%
 \long\def\html at def#1{%
   \htmlize at record@expand{#1}%
   \xa\def\xa\htmlize at scrap\xa{\xa\let\xa#1\csname html@\string#1\endcsname}%
@@ -1779,27 +2725,64 @@
 \htmlize at record@environment{shortanswer}
 
 \html at newenvironment{center}{\xdef\htmlize at afteraction@hook{<CENTER>\expandonce\BODY</CENTER>}}%
-\html at newenvironment{enumerate}{%
-    \xa\gatheritems\xa{\BODY}%
-    \gdef\htmlize at afteraction@hook{<OL>}%
-    \loopthroughitemswithcommand{\moodle at itemtoLI}%
-    \g at addto@macro\htmlize at afteraction@hook{</OL>}%
+
+\def\moodle at save@getitems at state{%
+  \global\xa\xdef\csname moodle at currentitemnumber@level@\the\moodle at listdepth\xa\endcsname\xa{\thecurrentitemnumber}%
+  \global\xa\xdef\csname moodle at numgathereditems@level@\the\moodle at listdepth\xa\endcsname\xa{\thenumgathereditems}%
+  \moodle at saveitems{\thenumgathereditems}%
 }%
-\html at newenvironment{itemize}{%
-    \xa\gatheritems\xa{\BODY}%
-    \gdef\htmlize at afteraction@hook{<UL>}%
-    \loopthroughitemswithcommand{\moodle at itemtoLI}%
-    \g at addto@macro\htmlize at afteraction@hook{</UL>}%
+\def\moodle at restore@getitems at state{%
+  \setcounter{numgathereditems}{\csname moodle at numgathereditems@level@\the\moodle at listdepth\endcsname}%
+  \setcounter{currentitemnumber}{\csname moodle at currentitemnumber@level@\the\moodle at listdepth\endcsname}%
+  \moodle at restoreitems{\thenumgathereditems}%
 }%
+\def\moodle at saveitems#1{%
+  \ifnum#1>0%
+    \global\csletcs{moodle at level@\the\moodle at listdepth @item@#1}{getitems at item@#1}%
+    \xa\moodle at saveitems\xa{\number\numexpr#1-1\expandafter}%
+  \fi
+}%
+\def\moodle at restoreitems#1{%
+  \ifnum#1>0%
+    \global\csletcs{getitems at item@#1}{moodle at level@\the\moodle at listdepth @item@#1}%
+    \global\xa\let\csname moodle at level@\the\moodle at listdepth @item@#1\endcsname=\@undefined
+    \xa\moodle at restoreitems\xa{\number\numexpr#1-1\expandafter}%
+  \fi
+}%
+\def\moodle at makelistenv#1#2{%
+  \html at newenvironment{#1}{%
+    \advance\moodle at listdepth by 1\relax
+    \moodle at save@getitems at state%
+      \xa\gatheritems\xa{\BODY}%
+      \gdef\htmlize at afteraction@hook{<#2>}%
+      \loopthroughitemswithcommand{\moodle at itemtoLI}%
+      \g at addto@macro\htmlize at afteraction@hook{</#2>}%
+    \moodle at restore@getitems at state%
+    \advance\moodle at listdepth by -1\relax
+  }%
+}%
+
+\moodle at makelistenv{enumerate}{OL}%
+\moodle at makelistenv{itemize}{UL}%
+
 \def\moodle at itemtoLI#1{%
-  \g at addto@macro\htmlize at afteraction@hook{<LI>#1</LI>}%
+  \g at addto@macro\htmlize at afteraction@hook{<LI>#1}%
+  \trim at spaces@in\htmlize at afteraction@hook%
+  \g at addto@macro\htmlize at afteraction@hook{</LI>}%
 }%
 
 \def\advancemathmodecounter#1{%
   \global\advance\moodle at mathmodedepth by #1\relax
 }
+\def\openclozemode{%
+  \global\moodle at clozemodetrue\relax
+}
+\def\endclozemode{%
+  \global\moodle at clozemodefalse\relax
+}
 \htmlize at record@action{\advancemathmodecounter}%
-
+\htmlize at record@action{\openclozemode}%
+\htmlize at record@action{\endclozemode}%
 \htmlize at record@action{\relax}%
 
 \html at action@def\#{\g at addto@macro\htmlize at output{\otherhash}}%
@@ -1812,15 +2795,32 @@
   }%
 \html at action@def\}{%
     \moodle at ifmathmode{\g at addto@macro\htmlize at output{\otherbackslash\otherrbrace}}%
-                      {\g at addto@macro\htmlize at output{\otherrbrace}}%
+                      {\ifmoodle at clozemode\g at addto@macro\htmlize at output{\otherbackslash}\fi
+                       \g at addto@macro\htmlize at output{\otherrbrace}}%
   }%
+\html at action@def\[{%
+    \advancemathmodecounter{1}
+    \g at addto@macro\htmlize at output{\otherbackslash\otherlbracket}%
+  }%
+\html at action@def\]{%
+    \g at addto@macro\htmlize at output{\otherbackslash\otherrbracket}%
+    \advancemathmodecounter{-1}
+  }%
+\html at action@def\({%
+    \advancemathmodecounter{1}
+    \g at addto@macro\htmlize at output{\otherbackslash(}%
+  }%
+\html at action@def\){%
+    \g at addto@macro\htmlize at output{\otherbackslash)}%
+    \advancemathmodecounter{-1}
+  }%
 \html at action@def\ldots{%
     \moodle at ifmathmode{\g at addto@macro\htmlize at output{\string\ldots}}%
-                      {\g at addto@macro\htmlize at output{...}}%
+                      {\g at addto@macro\htmlize at output{\otherampersand hellip\othersemicol}}%
   }%
 \html at action@def\dots{%
     \moodle at ifmathmode{\g at addto@macro\htmlize at output{\string\dots}}%
-                      {\g at addto@macro\htmlize at output{...}}%
+                      {\g at addto@macro\htmlize at output{\otherampersand hellip\othersemicol}}%
   }%
 \html at action@def\ {%
     \moodle at ifmathmode{\g at addto@macro\htmlize at output{\otherbackslash\otherspace}}%
@@ -1829,11 +2829,26 @@
 \html at action@def\${%
      \g at addto@macro\htmlize at output{\otherdollar}%
   }%
-
 \html at action@def\clozetilde{%
     \xa\g at addto@macro\xa\htmlize at output\xa{\othertilde}%
   }%
+\html at action@def\clozelbrace{%
+    \openclozemode
+    \xa\g at addto@macro\xa\htmlize at output\xa{\otherlbrace}%
+  }%
+\html at action@def\clozerbrace{%
+    \xa\g at addto@macro\xa\htmlize at output\xa{\otherrbrace}%
+    \endclozemode
+  }%
+\html at action@def\TeX{%
+    \g at addto@macro\htmlize at output{\otherbackslash(\otherbackslash rm\otherbackslash TeX\otherbackslash)}
+  }%
+\html at action@def\LaTeX{%
+    \g at addto@macro\htmlize at output{\otherbackslash(\otherbackslash rm\otherbackslash LaTeX\otherbackslash)}
+  }%
 
+{\catcode`;=12\relax\gdef\othersemicol{;}}
+
 {\catcode`|=3\relax
  \gdef\htmlize at vowels{a|e|i|o|u|A|E|I|O|U|}}
 \def\htmlize at define@diacritic#1#2{%
@@ -1841,7 +2856,7 @@
   \g at addto@macro\htmlize at activate@css{%
     \def#1##1{%
       \ifinlist{##1}{\htmlize at vowels}%
-        {\g at addto@macro\htmlize at output{\otherampersand##1#2;}}%
+        {\g at addto@macro\htmlize at output{\otherampersand##1#2\othersemicol}}%
         {\xa\g at addto@macro\htmlize at output\xa{\string#1##1}}%
     }%
   }%
@@ -1848,24 +2863,31 @@
 }
 \htmlize at define@diacritic{\^}{circ}%
 \htmlize at define@diacritic{\'}{acute}%
-\htmlize at define@diacritic{\"}{uml}%
 \htmlize at define@diacritic{\`}{grave}%
 
+{\catcode`|=3\relax
+ \gdef\htmlize at diaeresis{a|e|i|o|u|y|A|E|I|O|U|Y|}}
+\html at action@def\"#1{%
+    \ifinlist{#1}{\htmlize at diaeresis}%
+      {\g at addto@macro\htmlize at output{\otherampersand#1uml\othersemicol}}%
+      {\xa\g at addto@macro\htmlize at output\xa{\string\"#1}}%
+}%
+
 \def\@o{o}\def\@O{O}\def\@u{u}\def\@U{U}%
 \html at action@def\H#1{%
   \bgroup
     \def\test at i{#1}%
     \ifx\test at i\@O
-      \def\toadd{\otherampersand\otherhash337;}%
+      \def\toadd{\otherampersand\otherhash336\othersemicol}%
     \else
       \ifx\test at i\@o
-        \def\toadd{\otherampersand\otherhash337;}%
+        \def\toadd{\otherampersand\otherhash337\othersemicol}%
       \else
-        \ifx\test at i\U
-          \def\toadd{\otherampersand\otherhash368;}%
+        \ifx\test at i\@U
+          \def\toadd{\otherampersand\otherhash368\othersemicol}%
         \else
-          \ifx\test at i\u
-            \def\toadd{\otherampersand\otherhash369;}%
+          \ifx\test at i\@u
+            \def\toadd{\otherampersand\otherhash369\othersemicol}%
           \else
             \def\toadd{\otherbackslash\otherlbrace#1\otherrbrace}%
           \fi
@@ -1876,16 +2898,109 @@
   \egroup
 }%
 
+\def\@c{c}\def\@C{C}\def\@s{s}\def\@S{S}\def\@t{t}\def\@T{T}%
+\html at action@def\c#1{%
+\bgroup
+  \def\test at i{#1}%
+  \ifx\test at i\@c
+    \def\toadd{\otherampersand ccedil\othersemicol}%
+  \else
+    \ifx\test at i\@C
+      \def\toadd{\otherampersand Ccedil\othersemicol}%
+    \else
+      \ifx\test at i\@s
+        \def\toadd{\otherampersand\otherhash351\othersemicol}%
+      \else
+        \ifx\test at i\@S
+          \def\toadd{\otherampersand\otherhash350\othersemicol}%
+        \else
+          \ifx\test at i\@t
+            \def\toadd{\otherampersand\otherhash355\othersemicol}%
+          \else
+            \ifx\test at i\@T
+              \def\toadd{\otherampersand\otherhash354\othersemicol}%
+            \else
+              \def\toadd{\otherbackslash\otherlbrace#1\otherrbrace}%
+            \fi
+          \fi
+        \fi
+      \fi
+    \fi
+  \fi
+  \xa\g at addto@macro\xa\htmlize at output\xa{\toadd}%
+\egroup
+}%
+
 {\catcode`|=3\relax
  \gdef\htmlize at tilde{A|N|O|a|n|o|}}
 \html at action@def\~#1{%
     \ifinlist{#1}{\htmlize at tilde}%
-      {\g at addto@macro\htmlize at output{\otherampersand#1tilde;}}%
+      {\g at addto@macro\htmlize at output{\otherampersand#1tilde\othersemicol}}%
       {\xa\g at addto@macro\htmlize at output\xa{\string\~#1}}%
-  }%
-\html at def\underline#1{<SPAN STYLE="text-decoration: underline;">#1</SPAN>}
+}%
+
+{\catcode`|=3\relax
+ \gdef\htmlize at breve{A|G|U|a|g|u|}}
+\def\@e{e}\def\@E{E}\def\@i{i}\def\@ii{\i}\def\@I{I}\def\@o{o}\def\@O{O}%
+\html at action@def\u#1{%
+  \ifinlist{#1}{\htmlize at breve}%
+     {\g at addto@macro\htmlize at output{\otherampersand#1breve\othersemicol}}%
+     {
+      \bgroup
+        \def\test at i{#1}%
+        \ifx\test at i\@E
+          \def\toadd{\otherampersand\otherhash276\othersemicol}%
+        \else
+          \ifx\test at i\@e
+            \def\toadd{\otherampersand\otherhash277\othersemicol}%
+          \else
+            \ifx\test at i\@I
+              \def\toadd{\otherampersand\otherhash300\othersemicol}%
+            \else
+              \ifx\test at i\@i
+                \def\toadd{\otherampersand\otherhash301\othersemicol}%
+              \else
+                \ifx\test at i\@ii
+                  \def\toadd{\otherampersand\otherhash301\othersemicol}%
+                \else
+                  \ifx\test at i\@O
+                    \def\toadd{\otherampersand\otherhash334\othersemicol}%
+                  \else
+                    \ifx\test at i\@o
+                      \def\toadd{\otherampersand\otherhash335\othersemicol}%
+                    \else
+                      \def\toadd{\otherbackslash\otherlbrace#1\otherrbrace}%
+                    \fi
+                  \fi
+                \fi
+              \fi
+            \fi
+          \fi
+        \fi
+        \xa\g at addto@macro\xa\htmlize at output\xa{\toadd}%
+      \egroup
+    }%
+}%
+
+{\catcode`|=3\relax
+ \gdef\htmlize at caron{C|D|E|L|N|R|S|T|Z|c|d|e|l|n|r|s|t|z|}}
+\html at action@def\v#1{%
+    \ifinlist{#1}{\htmlize at caron}%
+      {\g at addto@macro\htmlize at output{\otherampersand#1caron\othersemicol}}%
+      {\xa\g at addto@macro\htmlize at output\xa{\string\v#1}}%
+}%
+\html at def\underline#1{<SPAN STYLE=\&\#34;text-decoration: underline;\&\#34;>#1</SPAN>}
 \html at def\emph#1{<EM>#1</EM>}%
+\html at def\textit#1{<I>#1</I>}%
 \html at def\textbf#1{<B>#1</B>}%
+\html at def\texttt#1{<CODE>#1</CODE>}%
+\html at def\textsc#1{<SPAN STYLE=\&\#34;font-variant: small-caps;\&\#34;>#1</SPAN>}
+\html at def\url#1{<A href=\&\#34;#1\&\#34;>#1</A>}%
+\html at def\href#1#2{<A href=\&\#34;#1\&\#34;>#2</A>}%
+\html at def\textsuperscript#1{<SUP>#1</SUP>}%
+\html at def\up#1{<SUP>#1</SUP>}%
+\html at def\fup#1{<SUP>#1</SUP>}%
+\html at def\textsubscript#1{<SUB>#1</SUB>}%
 \html at def\blank{____________}%
 \html at def\par{</P><P>}%
 \html at def\aa{\å}%
@@ -1892,6 +3007,8 @@
 \html at def\AA{\Å}%
 \html at def\ae{\æ}%
 \html at def\AE{\Æ}%
+\html at def\oe{\œ}%
+\html at def\OE{\Œ}%
 \html at def\S{\§}%
 \html at def\euro{\€}%
 \html at def\texteuro{\€}%
@@ -1898,15 +3015,117 @@
 \html at def\o{\ø}%
 \html at def\O{\Ø}%
 \html at def\ss{\ß}%
+\html at def\SS{\&\#7838;}%
 \html at def\l{\ł}%
 \html at def\L{\Ł}%
+\html at def\og{\«\&\#8239;}%
+\html at def\guillemotleft{\«\&\#8239;}%
+\html at def\fg{\&\#8239;\»}%
+\html at def\guillemotright{\&\#8239;\»}%
+\html at def\,{\&\#8239;}%
+\html at def\thinspace{\&\#8239;}%
+\html at def\textbackslash{\&\#92;}%
+\html at def\_{\&\#95;}%
+\html at def\textquestiondown{\¿}%
+\html at def\textexclamdown{\¡}%
 
-\htmlize at record@expand{\inv}%
-\htmlize at record@expand{\rec}%
 
 \htmlize at record@action\inlinemathrightdelim
 \htmlize at record@action\displaymathrightdelim
 
+\def\moodle at media@find#1{%
+  \ifx\detokenize\@undefined\else
+    \edef\Gin at extensions{\detokenize\expandafter{\Gin at extensions}}%
+  \fi
+  \begingroup
+  \let\input at path\Ginput at path
+  \set at curr@file{#1}%
+  \expandafter\filename at parse\expandafter{\@curr at file}%
+  \ifx\filename at ext\Gin at gzext
+    \expandafter\filename at parse\expandafter{\filename at base}%
+    \ifx\filename at ext\relax
+      \let\filename at ext\Gin at gzext
+    \else
+      \edef\Gin at ext{\Gin at ext\Gin at sepdefault\Gin at gzext}%
+    \fi
+  \fi
+  \ifx\filename at ext\relax
+    \@for\Gin at temp:=\Gin at extensions\do{%
+      \ifx\Gin at ext\relax
+        \Gin at getbase\Gin at temp
+      \fi}%
+  \else
+    \Gin at getbase{\Gin at sepdefault\filename at ext}%
+    \ifnum0%
+        \ifx\Gin at ext\relax 1%
+        \else \@ifundefined{Gin at rule@\Gin at ext}{1}{0}%
+        \fi >0
+      \let\Gin at ext\relax
+      \let\Gin at savedbase\filename at base
+      \let\Gin at savedext\filename at ext
+      \edef\filename at base{\filename at base\Gin at sepdefault\filename at ext}%
+      \let\filename at ext\relax
+      \@for\Gin at temp:=\Gin at extensions\do{%
+          \ifx\Gin at ext\relax
+            \Gin at getbase\Gin at temp
+          \fi}%
+      \ifx\Gin at ext\relax
+        \let\filename at base\Gin at savedbase
+        \let\filename at ext\Gin at savedext
+      \fi
+    \fi
+    \ifx\Gin at ext\relax
+       \@warning{File `#1' not found}%
+       \def\Gin at base{\filename at area\filename at base}%
+       \edef\Gin at ext{\Gin at sepdefault\filename at ext}%
+    \fi
+  \fi
+    \ifx\Gin at ext\relax
+         \@latex at error{File `#1' not found}%
+         {I could not locate the file with any of these extensions:^^J%
+          \Gin at extensions^^J\@ehc}%
+    \else
+      % begin modified part
+       \xdef\moodle at media@base{\detokenize\xa{\Gin at base}}%
+       \xdef\moodle at media@ext{\detokenize\xa{\Gin at ext}}%
+      % end modfied part
+    \fi
+  \endgroup
+}
+\def\moodle at media@formats{}
+\newcommand{\DeclareMediaFormat}[3]{%
+  \xdef\moodle at media@formats{\ifx\moodle at media@formats\empty\else\moodle at media@formats,\fi#1}%
+  \csgdef{moodle at media@#1list}{#2}%
+  \csgdef{moodle at media@#1mime}{#3}%
+}%
+\DeclareMediaFormat{PNG}{.png,.PNG}{image/png}%
+\DeclareMediaFormat{JPEG}{.jpg,.JPG,.jpeg,.JPEG}{image/jpeg}%
+\DeclareMediaFormat{SVG}{.svg,.SVG}{image/svg+xml}%
+\DeclareMediaFormat{GIF}{.gif}{image/gif}%
+\DeclareMediaFormat{WAV}{.wav,.WAV}{audio/wave}%
+\DeclareMediaFormat{MP3}{.mp3,.MP3}{audio/mpeg}%
+\DeclareMediaFormat{OGG}{.ogg,.opus,.og&}{audio/ogg}%
+\DeclareMediaFormat{WEBM}{.webm,.webm}{video/webm}%
+\DeclareMediaFormat{MP4}{.mp4,.MP4,.m4v,.M4V}{video/mp4}%
+\DeclareMediaFormat{OGV}{.ogv,.OGV}{video/ogg}%
+\def\moodle at media@mime at identify#1{%
+  \edef\test at i{\detokenize\xa{#1}}%
+  \let\moodle at media@mime at current\relax
+  \edef\moodle at media@formats{\detokenize\xa{\moodle at media@formats}}%
+  \@for\@format:=\moodle at media@formats\do{%
+    \edef\@templist{\csname moodle at media@\@format list\endcsname}%
+    \@for\@ext:=\@templist\do{%
+      \ifx\moodle at media@mime at current\relax
+        \edef\@ext{\detokenize\xa{\@ext}}%
+        \ifx\test at i\@ext
+          \message{<<extension \@ext (\@format) identified>>^^J}%
+          \xdef\moodle at media@mime at current{\csname moodle at media@\@format mime\endcsname}%
+          \xdef\moodle at media@ext at current{#1}%
+        \fi
+      \fi
+    }%
+  }%
+}
 \def\htmlize at setexecutable#1{%
   % Defines macro #1 to be #2 in a verbatim mode suitable for filenames
   \def\htmlize at executable@macro{#1}%
@@ -1918,18 +3137,55 @@
   \expandafter\def\htmlize at executable@macro{#1}%
 }
 
-\def\ghostscriptcommand{\htmlize at setexecutable\gs}
-\def\opensslcommand{\htmlize at setexecutable\openssl}
-\def\imagemagickcommand{\htmlize at setexecutable\htmlize at imagemagick@convert}
+\def\ghostscriptcommand{\htmlize at setexecutable\gs}%
+\def\baselxivcommand{\htmlize at setexecutable\baselxiv}%
+\def\imagemagickcommand{\htmlize at setexecutable\htmlize at imagemagick@convert}%
+\def\optipngcommand{\htmlize at setexecutable\optipng}%
+\def\PDFtoSVGcommand{\htmlize at setexecutable\PDFtoSVG}%
+\def\SVGtoPDFcommand{\htmlize at setexecutable\SVGtoPDF}%
+\def\optiSVGcommand{\htmlize at setexecutable\optiSVG}%
+\def\DeleteFilecommand{\htmlize at setexecutable\DeleteFiles}%
 
 \ifwindows%
-  \ghostscriptcommand{gswin64c.exe}%
+  \ghostscriptcommand{gswin64c.exe -dBATCH -dNOPAUSE -sDEVICE=pngalpha}%
+  \baselxivcommand{certutil}%
+  \DeleteFilecommand{del}%
 \else%
-  \ghostscriptcommand{gs}%
+  \ghostscriptcommand{gs -dBATCH -dNOPAUSE -sDEVICE=pngalpha}%
+  \baselxivcommand{base64}%
+  \DeleteFilecommand{rm -f}%
 \fi%
 
-\opensslcommand{openssl}%
-\imagemagickcommand{convert}%
+\imagemagickcommand{convert -colorspace RGB}%
+\optipngcommand{optipng -clobber -strip all -quiet}%
+\PDFtoSVGcommand{inkscape --export-type=svg --export-area-page --vacuum-defs}%--pdf-poppler
+\SVGtoPDFcommand{inkscape --export-type=pdf --export-area-page}%
+\optiSVGcommand{scour -q --enable-id-stripping --enable-comment-stripping
+                --shorten-ids --indent=none --remove-descriptive-elements}%
+\AtEndPreamble{%
+  \@ifpackageloaded{graphicx}{%
+    \def\@firstofthree#1#2#3{#1}%
+    \def\@secondofthree#1#2#3{#2}%
+    \newcommand{\DeclareGraphicsAlien}[3]{%
+      \edef\Gin at extensions{\Gin at extensions,#1}%
+      \DeclareGraphicsRule{#1}{\@gobble#1}{#1}{}%
+      \csdef{Gread@\@gobble#1}##1{%
+        \edef\SourceFile{\Gin at base\Gin at ext}%
+        \edef\Gin at base{\Gin at base-\@gobble#1-converted-to}%
+        \edef\Gin at ext{#2}%
+        \edef\OutputFile{\Gin at base\Gin at ext}%
+        \edef\targetfmt{\expandafter\expandafter\expandafter
+                        \@firstofthree\csname Gin at rule@\Gin at ext\endcsname\relax}%
+        \edef\targetext{\expandafter\expandafter\expandafter
+                        \@secondofthree\csname Gin at rule@\Gin at ext\endcsname\relax}%
+        \IfFileExists{\OutputFile}{}{\ShellEscape{#3}}%
+        \csletcs{Ginclude@\@gobble#1}{Ginclude@\targetfmt}%
+        \csname Gread@\targetfmt\endcsname{\Gin at base\targetext}%
+      }%
+    }%
+    \DeclareGraphicsAlien{.gif}{.png}{\htmlize at imagemagick@convert\otherspace '\SourceFile[0]' \OutputFile}%
+  }{}%
+}%
 \define at cmdkeys{moodle at includegraphics}[moodle at graphics@]{ppi}
 \define at cmdkey{moodle}[moodle at graphics@]{ppi}{}% This is so the ppi key can be set at the document, quiz, or question level.
 \define at cmdkeys{Gin}{ppi}% This is so the original \includegraphics will not object to a key of ppi.
@@ -1952,24 +3208,45 @@
   \moodle at graphics@dimentopixels{\moodle at graphics@width at pixels}{#1}%
 }
 \setkeys{moodle at includegraphics}{height=0pt,width=0pt}
-\html at action@def\includegraphics{\moodle at includegraphics@int}%
-  % Note that \htmlize at do@actioncs will 'patch' this by putting
-  % '\xa\htmlize at proceedwiththerest\htmlize at afteraction@hook'
-  % at the end.  We want those 3 tokens to occur instead after
-  % the graphics filename.
-\def\moodle at includegraphics@int#1#2#3{\moodle at includegraphics@int at int}%
-  % This gobbles up those three spurious tokens,
-  % which we will re-insert after our work is done.
-\newcommand\moodle at includegraphics@int at int[2][]{%
+\ifmoodle at svg
+  \AtEndPreamble{%
+    \DeclareGraphicsAlien{.svg}{.pdf}{%
+      \SVGtoPDF\otherspace '\SourceFile' -o '\OutputFile' 2>/dev/null}%
+    \DeclareGraphicsAlien{.SVG}{.pdf}{%
+      \SVGtoPDF\otherspace '\SourceFile' -o '\OutputFile' 2>/dev/null}%
+  }%
+\fi
+
+\ifmoodle at tikz
+\AfterEndPreamble{%
+  %\htmlize at record@expand{\embedaspict}%
+  \let\oldincludegraphics=\includegraphics
+  % patching includegraphics to trigger externalization
+  \renewcommand{\includegraphics}[2][]{%
+    %\message{moodle.sty: Processing \string\includegraphics[#1]{#2} for HTML^^J}%
+    \tikz{\node[inner sep=0pt]{\oldincludegraphics[#1]{#2}};}%
+  }%
+  % externalized images must be included with the regular command
+  \pgfkeys{/pgf/images/include external/.code={\oldincludegraphics{#1}}}%
+  \html at action@newcommand{includegraphics}[2][]{%
+    \message{moodle.sty: Processing \string\includegraphics[#1]{#2} ^^J}
+    \global\advance\numpicturesread by 1\relax
+    \edef\htmlize at imagetag{<IMG SRC="data:\TikzExportMIME;base64,\csname picbaselxiv@\the\numpicturesread\endcsname">}%
+    \xa\g at addto@macro\xa\htmlize at output\xa{\htmlize at imagetag}%
+  }%
+}%
+\else
+\html at action@newcommand{includegraphics}[2][]{%
   \bgroup% The grouping is to localize the changes caused by \setkeys.
     \message{moodle.sty: Processing \string\includegraphics[#1]{#2} for HTML...^^J}
     \setkeys*{moodle at includegraphics}{#1}%
     % Height or width should be given in TeX dimensions like cm or pt or in,
     % and are converted to pixels for web use using the ppi key.
-    % TO DO: Can we modify \includegraphics to accept height or width in
+    % TODO: Can we modify \includegraphics to accept height or width in
     %        pixels?
-    % TO DO: What about \includegraphics[scale=0.7] ?
+    % TODO: What about \includegraphics[scale=0.7] ?
     %        Other keys: keepaspectratio=true|false, angle (rotation), clip & trim
+    %           -> the package option 'tikz' offers a workaround for this
     \ifnum\moodle at graphics@height at pixels=0\relax
       \ifnum\moodle at graphics@width at pixels=0\relax
         % No size specified.  Default to height of 200 pixels.
@@ -1991,28 +3268,86 @@
         \edef\moodle at graphics@htmlgeometry{width=\number\moodle at graphics@width at pixels\otherspace height=\number\moodle at graphics@height at pixels}%
       \fi
     \fi
-    %First, convert it to PNG
-    \edef\cmdline{\htmlize at imagemagick@convert\otherspace #2 -resize \moodle at graphics@geometry\otherspace #2.png}%
-    \message{moodle.sty:   Converting '#2' to PNG...^^J}%
-    \expandafter\immediate\expandafter\write18\expandafter{\cmdline}%
-    %Next, convert the PNG to base64 encoding
-    \def\cmdline{\openssl\otherspace enc -base64 -in #2.png -out #2.enc}%
-    \message{moodle.sty:   Converting '#2.png' to base64...^^J}%
-    \expandafter\immediate\expandafter\write18\expandafter{\cmdline}%
+    %Look for the file, even if no extension is provided
+    \moodle at media@find{#2}%
+    %\message{<<\moodle at media@base>>^^J}
+    %\message{<<\moodle at media@ext>>^^J}
+    %Try to identify corresponding MIME-type
+    \moodle at media@mime at identify{\moodle at media@ext}%
+    \ifx\moodle at media@mime at current\relax
+      % conversion needed
+      \edef\moodle at media@pdf{\detokenize{.pdf}}%
+      \edef\moodle at media@ext{\detokenize\xa{\moodle at media@ext}}%
+      \ifnum0\ifx\moodle at media@ext\moodle at media@pdf1\fi\ifmoodle at svg1\fi=11% PDF file and SVG option active
+        \def\moodle at media@ext at current{.svg}%
+        \edef\moodle at media@mime at current{\moodle at media@SVGmime}%
+        \edef\cmdline{\PDFtoSVG\otherspace "\moodle at media@base\moodle at media@ext" -o "\moodle at media@base\moodle at media@ext at current" 2>/dev/null}%
+        \message{moodle.sty:   Converting '#2' to SVG...^^J}%
+        \xa\ShellEscape\xa{\cmdline}%
+        %Next, optimize inline
+        \ifwindows\else
+          \edef\cmdline{\optiSVG < "\moodle at media@base\moodle at media@ext at current" >
+           "\moodle at media@base.tmp.svg" && mv "\moodle at media@base.tmp.svg"
+           "\moodle at media@base\moodle at media@ext at current"}%
+          \message{moodle.sty:   Optimizing '\moodle at media@base\moodle at media@ext at current'...^^J}%
+          \xa\ShellEscape\xa{\cmdline}%
+        \fi
+      \else% call ImageMagick
+        \def\moodle at media@ext at current{.png}%
+        \def\moodle at media@mime at current{image/png}%
+        \edef\cmdline{\htmlize at imagemagick@convert\otherspace "\moodle at media@base\moodle at media@ext" -resize \moodle at graphics@geometry\otherspace "\moodle at media@base\moodle at media@ext at current"}%
+        \message{moodle.sty:   Converting '#2' to PNG...^^J}%
+        \xa\ShellEscape\xa{\cmdline}%
+        %Next, optimize inline
+        \edef\cmdline{\optipng\otherspace "\moodle at media@base\moodle at media@ext at current"}%
+        \message{moodle.sty:   Optimizing '\moodle at media@base\moodle at media@ext at current'...^^J}%
+        \xa\ShellEscape\xa{\cmdline}%
+      \fi
+    \fi
+    %Next, convert the file to base64 encoding
+    \ConvertToBaseLXIV{\moodle at media@base}{\moodle at media@ext at current}%
     %Now, save that base64 encoding in a TeX macro
     \def\moodle at newpic@baselxiv{}%
-    \message{moodle.sty:   Reading base64 file '#2.enc'...^^J}%
-    \openin\baseLXIVdatafile=#2.enc\relax
+    \message{moodle.sty:   Reading base64 file '\moodle at media@base.enc'...^^J}%
+    \openin\baseLXIVdatafile="\moodle at media@base.enc"
       \savebaselxivdata at recursive
     \closein\baseLXIVdatafile
+    %Clean up files
+    \ifx\moodle at media@ext at current\moodle at media@ext
+      \ShellEscape{\DeleteFiles\otherspace "\moodle at media@base.enc"}%
+    \else
+      \ShellEscape{\DeleteFiles\otherspace "\moodle at media@base.enc" "\moodle at media@base\moodle at media@ext at current"}%
+    \fi
     \xa\global\xa\let\csname picbaselxiv at graphics@#2\endcsname=\moodle at newpic@baselxiv%
-    \edef\htmlize at imagetag{<IMG \moodle at graphics@htmlgeometry\otherspace SRC="data:image/png;base64,\csname picbaselxiv at graphics@#2\endcsname">}%
+    \edef\htmlize at imagetag{<IMG \moodle at graphics@htmlgeometry\otherspace SRC="data:\moodle at media@mime at current;base64,\csname picbaselxiv at graphics@#2\endcsname">}%
     \xa\g at addto@macro\xa\htmlize at output\xa{\htmlize at imagetag}%
     \message{moodle.sty:   <IMG> tag inserted.^^J}%
   \egroup
-  % Now we re-insert the code to get the HTMLizing going again.
-  \xa\htmlize at proceedwiththerest\htmlize at afteraction@hook
-}
+}%
+\fi
+\ifwindows
+  \def\ConvertToBaseLXIV#1#2{%
+    \def\cmdline{\baselxiv\otherspace -encode "#1#2"\otherspace tmp.b64 && findstr /vbc:"---" tmp.b64 > "#1" && del tmp.b64"}%
+    \message{moodle.sty:   Converting '#1#2' to base64...^^J}%
+    \xa\ShellEscape\xa{\cmdline}%
+  % Starting from Windows 7, CertUtil is included by default. There should be no windows XP still running
+  }%
+\else
+  \ifmacosx
+    \def\ConvertToBaseLXIV#1#2{%
+      \def\cmdline{\baselxiv\otherspace -b 64 -i "#1#2"\otherspace -o "#1.enc"}%
+      \message{moodle.sty:   Converting '#1#2' to base64...^^J}%
+      \xa\ShellEscape\xa{\cmdline}%
+    }%
+  \else % Linux, Cygwin
+    \def\ConvertToBaseLXIV#1#2{%
+      \def\cmdline{\baselxiv\otherspace "#1#2"\otherspace > "#1.enc"}%
+      \message{moodle.sty:   Converting '#1#2' to base64...^^J}%
+      \xa\ShellEscape\xa{\cmdline}%
+    }%
+    % base64 is part of coreutils, add "-w 64" to get exactly the previous behavior  %
+  \fi
+\fi
 \newread\baseLXIVdatafile
 \def\savebaselxivdata at recursive{%
   \ifeof\baseLXIVdatafile
@@ -2030,8 +3365,6 @@
   \fi
   \baselxiv at next
 }
-\newif\ifmoodle at tikzloaded
-\moodle at tikzloadedfalse
 \AtBeginDocument{
   \ifx\tikzpicture\@undefined
     \moodle at tikzloadedfalse
@@ -2038,23 +3371,48 @@
   \else
     \moodle at tikzloadedtrue
   \fi
+  \ifmoodle at draftmode
+    \long\def\tikzifexternalizing#1#2{#2}%
+  \else
   \ifmoodle at tikzloaded
-    \usetikzlibrary{external}
+    \usetikzlibrary{external}%
     \tikzexternalize%
     \tikzset{external/force remake}%
-
-    \ifpdf
-      \def\pdftopng{\edef\gscmdline{\gs\otherspace -dBATCH -dNOPAUSE -sDEVICE=pngalpha -sOutputFile=\tikzexternalrealjob-tikztemp-\the\numconvertedpictures.png -r200 \tikzexternalrealjob-tikztemp-\the\numconvertedpictures.pdf}%
-                    \expandafter\immediate\expandafter\write18\expandafter{\gscmdline}}%
+    \def\moodle at basename{\tikzexternalrealjob-tikztemp-\the\numconvertedpictures}%
+    \ifmoodle at svg
+      \def\TikzExportExtension{.svg}%
+      \def\TikzExportMIME{image/svg+xml}%
+      \ifpdfoutput% tex engines defaulting to PDF output (pdflatex, xelatex, lualatex)
+        \def\ExportTikz{ \message{moodle.sty: Converting picture '\moodle at basename.pdf' to SVG...^^J}%
+                         \edef\cmdline{\PDFtoSVG\otherspace "\moodle at basename.pdf" -o "\moodle at basename\TikzExportExtension" 2>/dev/null}%
+                         \xa\ShellEscape\xa{\cmdline}}%
+      \else % latex
+        \def\ExportTikz{ \message{moodle.sty: Converting picture '\moodle at basename.ps' to SVG...^^J}%
+                         \edef\cmdline{\PDFtoSVG\otherspace "\moodle at basename.ps" -o "\moodle at basename\TikzExportExtension" 2>/dev/null}%
+                         \xa\ShellEscape\xa{\cmdline}}%
+      \fi
+      \def\OptimizeExport{ \message{moodle.sty:   Optimizing '\moodle at basename.svg'...^^J}%
+                           \edef\cmdline{\optiSVG\otherspace < "\moodle at basename\TikzExportExtension" >
+                                         "\moodle at basename.tmp.svg" && mv "\moodle at basename.tmp.svg"
+                                         "\moodle at basename\TikzExportExtension" }%
+                           \xa\ShellEscape\xa{\cmdline}}%
     \else
-      \def\pstopng{\edef\gscmdline{\gs\otherspace -dBATCH -dNOPAUSE -sDEVICE=pngalpha -sOutputFile=\tikzexternalrealjob-tikztemp-\the\numconvertedpictures.png -r200 \tikzexternalrealjob-tikztemp-\the\numconvertedpictures.ps}%
-                    \expandafter\immediate\expandafter\write18\expandafter{\gscmdline}}%
+      \def\TikzExportExtension{.png}%
+      \def\TikzExportMIME{image/png}%
+      \ifpdfoutput% tex engines defaulting to PDF output (pdflatex, xelatex, lualatex)
+        \def\ExportTikz{ \message{moodle.sty: Converting picture '\moodle at basename.pdf' to PNG...^^J}%
+                         \edef\gscmdline{\gs\otherspace -sOutputFile=\moodle at basename\TikzExportExtension\otherspace -r150 \moodle at basename.pdf}%
+                         \xa\ShellEscape\xa{\gscmdline}}%
+      \else % latex
+        \def\ExportTikz{ \message{moodle.sty: Converting picture '\moodle at basename.ps' to PNG...^^J}%
+                         \edef\gscmdline{\gs\otherspace -sOutputFile=\moodle at basename\TikzExportExtension\otherspace -r150 \\moodle at basename.ps}%
+                         \xa\ShellEscape\xa{\gscmdline}}%
+      \fi
+      \def\OptimizeExport{ \message{moodle.sty:   Optimizing '\moodle at basename.png'...^^J}%
+                           \edef\cmdline{\optipng\otherspace \moodle at basename\TikzExportExtension}%
+                           \xa\ShellEscape\xa{\cmdline}}%
     \fi
-    \def\pngtobaselxiv{\edef\opensslcmdline{\openssl\otherspace enc -base64 -in \tikzexternalrealjob-tikztemp-\the\numconvertedpictures.png -out \tikzexternalrealjob-tikztemp-\the\numconvertedpictures.enc}%
-                       \expandafter\immediate\expandafter\write18\expandafter{\opensslcmdline}}%
-
     \let\moodle at oldtikzpicture=\tikzpicture
-
     %The following code lets us run things *before* the normal \begin{tikzpicture}.
     \renewenvironment{tikzpicture}{%
       \global\advance\numconvertedpictures by 1\relax
@@ -2066,43 +3424,52 @@
     % However, the tikz externalize library does *not* run \end{tikzpicture}.
     % In order to run commands after the tikz picture is done compiling, we need to
     % use a hook into \tikzexternal at closeenvironments.
-
     \g at addto@macro{\tikzexternal at closeenvironments}{%
       \moodle at endtikzpicture@hook
     }
     \def\moodle at endtikzpicture@hook{%
       \@moodle at ifgeneratexml{%
-        \ifpdf
-          \message{moodle.sty: Converting picture '\tikzexternalrealjob-tikztemp-\the\numconvertedpictures.pdf' to PNG...^^J}%
-          \pdftopng
-        \else
-          \pstopng
-        \fi
-        \message{moodle.sty:   Converting '\tikzexternalrealjob-tikztemp-\the\numconvertedpictures.png' to base64...^^J}%
-        \pngtobaselxiv
+        \ExportTikz
+        \OptimizeExport
+        \ConvertToBaseLXIV{\moodle at basename}{\TikzExportExtension}%
         \message{moodle.sty:   Reading base64 file '\tikzexternalrealjob-tikztemp-\the\numconvertedpictures.enc'...^^J}%
         \savebaselxivdata
         \message{moodle.sty:   base64 data saved.^^J}%
       }{}%
     }
-    \tikzset{external/optimize=true}
-    \tikzset{external/optimize command away={\VerbatimInput}{1}}
+    \ifmoodle at tikz
+      \tikzset{external/optimize=false}% due to redefinition, includegraphics must not be optimized away
+    \else
+      \tikzset{external/optimize=true}%
+      \tikzset{external/optimize command away={\VerbatimInput}{1}}%
+    \fi
     %
     % The HTMLizer version of the tikzpicture environment,
     % which writes an <IMG> tag to the XML file.
-    \htmlize at record@environment{tikzpicture}
+    \htmlize at record@environment{tikzpicture}%
     \g at addto@macro\htmlize at activate@environments{%
       \let\tikzpicture\relax\let\endtikzpicture\relax
       \NewEnviron{tikzpicture}[1][]{%
         \global\advance\numpicturesread by 1\relax
-        \edef\htmlize at imagetag{<IMG SRC="data:image/png;base64,\csname picbaselxiv@\the\numpicturesread\endcsname">}%
+        \edef\htmlize at imagetag{<IMG SRC="data:\TikzExportMIME;base64,\csname picbaselxiv@\the\numpicturesread\endcsname">}%
         \xa\g at addto@macro\xa\htmlize at output\xa{\htmlize at imagetag}%
       }[\htmlize at patchendenvironment]%
     }%
+    \html at action@newcommand{tikz}[2][]{%
+      \global\advance\numpicturesread by 1\relax
+      \edef\htmlize at imagetag{<IMG SRC="data:\TikzExportMIME;base64,\csname picbaselxiv@\the\numpicturesread\endcsname">}%
+      \xa\g at addto@macro\xa\htmlize at output\xa{\htmlize at imagetag}%
+    }%
   \else
     %TikZ not loaded.  Provide dummy definitions for commands.
     \long\def\tikzifexternalizing#1#2{#2}%
   \fi
+  \fi
+  \ifmoodle at tikz
+    \tikzstyle{moodlepict}=[minimum height=1em,inner sep=0pt,execute at begin node={\begin{varwidth}{\linewidth}},execute at end node={\end{varwidth}}]
+    \newcommand\embedaspict[1]{\tikz[baseline=-\the\dimexpr\fontdimen22\textfont2\relax]{\node[moodlepict]{\mbox{#1}};}}
+    \htmlize at record@expand{\embedaspict}
+  \fi
 }
 
 \newcount\numconvertedpictures
@@ -2118,19 +3485,356 @@
   \xa\global\xa\let\csname picbaselxiv@\the\numconvertedpictures\endcsname=\moodle at newpic@baselxiv%
 }
 
-\def\@moodle at par{\par}%
-\AtEndDocument{%
+\ifmoodle at tikz
   \ifmoodle at tikzloaded
+    \PackageWarning{moodle}{With package option 'tikz', you should not load TikZ manually.}%
+  \fi
+  \RequirePackage{tikz}%
+  \RequirePackage{varwidth}% for the command |embedaspict|
+\fi
+\AfterEndDocument{%
+  \ifmoodle at tikzloaded
     \@moodle at ifgeneratexml{%
-      \ifwindows
-        \immediate\write18{del \tikzexternalrealjob-tikztemp-*.*}%
+      \ifXeTeX
+        % we must keep picture pdf's for subsequent linking (xdvipdfmx)
+        \ifwindows
+          \ShellEscape{powershell.exe -noexit "del * -include \tikzexternalrealjob-tikztemp-*.* -exclude *.pdf}%
+        \else
+          \ShellEscape{find . -type f -name "\tikzexternalrealjob-tikztemp-*.*" -not -name "*.pdf" -delete}%
+        \fi
       \else
-        \immediate\write18{rm \tikzexternalrealjob-tikztemp-*.*}%
+        \ShellEscape{\DeleteFiles\otherspace \tikzexternalrealjob-tikztemp-*.*}%
       \fi
     }{}%
   \fi
 }
+\AtEndPreamble{%
+  \@ifpackageloaded{hyperref}{%
+    \let\oldhref\href
+    \let\oldurl\url
+    \def\moodle at hyper@readexternallink#1#2#3#4:#5:#6\\#7{%
+      \def\filename at ext{}%
+      \def\filename at area{}%
+      \def\filename at base{}%
+      \ifx\\#6\\% if ##6 is empty (the URL contains no column -> no scheme -> local)
+        %\@hyper at linkfile file:#7\\{#3}{#2}{#7}% local file
+        %Local file (##1|##2|##3|##4|##5|##6): ##7\par
+        \filename at parse{#4}%
+        \ConvertToBaseLXIV{\filename at area\filename at base}{.\filename at ext}%
+      \else
+        \ifx\\#4\\%if ##4 is empty (no scheme was specified -> local file)
+          \filename at parse{#4}%
+          \ConvertToBaseLXIV{\filename at area\filename at base}{.\filename at ext}%
+        \else
+          \def\@pdftempa{#4}%
+          \ifx\@pdftempa\@pdftempwordfile% scheme is "file:"
+            \filename at parse{#5}%
+            \ConvertToBaseLXIV{\filename at area\filename at base}{.\filename at ext}%
+          \else
+            \ifx\@pdftempa\@pdftempwordrun% scheme is "run:"
+              \ifHy at pdfa
+                \Hy at Error{%
+                  PDF/A: Launch action is prohibited%
+                }\@ehc
+                \begingroup
+                  \leavevmode
+                \endgroup
+              \else% not in PDF/A mode -> run is allowed
+                %\@hyper at launch#7\\{#3}{#2}% run local file
+                \filename at parse{#5}%
+                \ConvertToBaseLXIV{\filename at area\filename at base}{.\filename at ext}%
+              \fi
+            \else% scheme is neither "file" nor "run", assuming it is a web protocol
+              %\hyper at linkurl{#3}{#7\ifx\\#2\\\else\hyper at hash#2\fi}% URL
+              \filename at parse{#7}%
+            \fi
+          \fi
+        \fi
+      \fi
+      \xdef\moodle at media@ext{.\filename at ext}%
+      \xdef\moodle at media@base{\filename at area\filename at base}%
+    }%
+        %\message{<<\moodle at media@base>>^^J}
+        %\message{<<\moodle at media@ext>>^^J}
+        %Try to identify corresponding MIME-type
+        %\edef\moodle at media@mime at current{\detokenize\xa{\moodle at media@mime at current}}%
+  }{}%
+}%
+\def\xmlDisplayVerbatimBox{border-top: thin solid; border-bottom: thin solid}%
+\html at action@def\verbatiminput#1{%
+  \message{moodle.sty: Processing \string\verbatiminput{#1} for HTML ^^J}%
+  \g at addto@macro\htmlize at output{<PRE style="\xmlDisplayVerbatimBox"><CODE>}%
+  %%%%%%%%%%%%%% from verbatim %%%%%%%%%%%%%%%%%
+  \@bsphack
+  \let\do\@makeother\dospecials
+  \catcode`\^^M\active
+  \def\verbatim at processline{\xa\g at addto@macro\xa\htmlize at output\xa{\the\verbatim at line<BR/>}}
+  \verbatim at readfile{#1}%
+  \@esphack
+   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+  \g at addto@macro\htmlize at output{</CODE></PRE>}%
+}%
+\@ifpackageloaded{minted}{\PackageError{moodle}{'moodle' should be loaded before 'minted'.}%
+{'moodle' loads 'fancybox' which, unfortunately, redefines verbatim commands.}}{\relax}%
+\@ifpackageloaded{fvextra}{\PackageError{moodle}{'moodle' should be loaded before 'fvextra'.}%
+{'moodle' loads 'fancybox' which, unfortunately, redefines verbatim commands.}}{\relax}%
+\@ifpackageloaded{fancyvrb}{\PackageError{moodle}{'moodle' should be loaded before 'fancyvrb'.}%
+{'moodle' loads 'fancybox' which, unfortunately, redefines verbatim commands.}}{\relax}%
 
+\html at action@newcommand{VerbatimInput}[2][]{%
+  \message{moodle.sty: Processing \string\VerbatimInput[#1]{#2} for HTML ^^J}%
+  \def\FV at KeyValues{#1}%
+  \FV at UseKeyValues% import options defined in #1
+  \moodle at VerbatimInput{#2}%
+}%
+\html at action@newcommand{LVerbatimInput}[2][]{%
+  \message{moodle.sty: Processing \string\LVerbatimInput[#1]{#2} for HTML ^^J}%
+  \def\FV at KeyValues{#1}%
+  \FV at UseKeyValues% import options defined in #1
+  \moodle at VerbatimInput{#2}%
+}%
+\html at action@newcommand{BVerbatimInput}[2][]{%
+  \message{moodle.sty: Processing \string\BVerbatimInput[#1]{#2} for HTML ^^J}%
+  \def\FV at KeyValues{#1}%
+  \FV at UseKeyValues% import options defined in #1
+  \moodle at VerbatimInput{#2}%
+}%
+\def\moodle at VerbatimInput#1{%
+  \g at addto@macro\htmlize at output{<PRE style="\xmlDisplayVerbatimBox"><CODE>}%
+  %%%%%%%% using material from fancyvrb and fvextra  %%%%%%%%
+  %\begingroup
+  \def\moodle at verbatim@addlinenumber##1{%
+    \g at addto@macro\htmlize at output{<span style="font-size: 80\otherpercent;
+         background-color: \otherhash f0f0f0; padding: 0 5px 0 5px; display:
+         inline-block; width: 16pt; ##1">}%
+    \if at FV@NumberBlankLines
+      \xa\g at addto@macro\xa\htmlize at output\xa{\the\c at FancyVerbLine</span>}%
+    \else
+      \ifx\FV at Line\empty
+        \xa\g at addto@macro\xa\htmlize at output\xa{\otherampersand nbsp;</span>}%
+      \else
+        \xa\g at addto@macro\xa\htmlize at output\xa{\the\c at FancyVerbLine</span>}%
+      \fi
+    \fi
+  }
+  % redefine the ProcessLine routine ('fancyvrb' and 'fvextra') for XML output
+  \def\FV at ProcessLine##1{%
+    \ifcsname FV at HighlightLine:\number\c at FancyVerbLine\endcsname
+      \xdef\moodle at FV@tagB{<mark>}% fvextra triggered highlighting for this line
+      \xdef\moodle at FV@tagE{</mark>}%
+    \else
+      \xdef\moodle at FV@tagB{}% no highlighting
+      \xdef\moodle at FV@tagE{}%
+    \fi
+    \catcode`\`=12%
+    \def\FV at Line{##1}%
+    \ifx\FV at LeftListNumber\relax
+
+    \else% line numbers displayed on the left side
+      \moodle at verbatim@addlinenumber{text-align: right}%
+    \fi
+    \xa\g at addto@macro\xa\htmlize at output\xa{\moodle at FV@tagB}%
+    \xa\g at addto@macro\xa\htmlize at output\xa{\FV at Line}%
+    \xa\g at addto@macro\xa\htmlize at output\xa{\moodle at FV@tagE}%
+    \ifx\FV at RightListNumber\relax\else% line numbers on the right side
+      \moodle at verbatim@addlinenumber{text-align: left; float: right}%
+    \fi
+    \g at addto@macro\htmlize at output{<BR/>}%linebreak
+  }
+  \global\FV at CodeLineNo\z@% reset codeline counter
+  \frenchspacing% Cancels special punctuation spacing.
+  \FV at DefineWhiteSpace
+  \def\FV at Space{\space}
+  \FV at DefineTabOut% replace tabs with a series a whitespaces
+  \ifdefined\FV at HighlightLinesPrep
+    \FV at HighlightLinesPrep% prepare highlighting if 'fvextra' is loaded
+  \fi
+  \FV at Input{#1}%
+  %\endgroup
+  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+  \g at addto@macro\htmlize at output{</CODE></PRE>}%
+}%
+\AtEndPreamble{%
+  \@ifpackageloaded{fancyvrb}{%
+    % custom settings for display
+    \fvset{frame=lines,label={[Beginning of code]End of code},framesep=3mm,numbersep=9pt}%
+  }{\relax}%
+}
+\AtEndPreamble{% this definition should prevail because `minted' gets loaded after `moodle'
+\@ifpackageloaded{minted}{%
+  \newcounter{moodle at pygmentizecounter}%
+  \renewcommand{\minted at pygmentize}[2][\minted at outputdir\minted at jobname.pyg]{%
+    \minted at checkstyle{\minted at get@opt{style}{default}}%
+    \stepcounter{minted at pygmentizecounter}%
+    \ifthenelse{\equal{\minted at get@opt{autogobble}{false}}{true}}%
+      {\def\minted at codefile{\minted at outputdir\minted at jobname.pyg}}%
+      {\def\minted at codefile{#1}}%
+    \ifthenelse{\boolean{minted at isinline}}%
+      {\def\minted at optlistcl@inlines{%
+        \minted at optlistcl@g at i
+        \csname minted at optlistcl@lang\minted at lang @i\endcsname}}%
+      {\let\minted at optlistcl@inlines\@empty}%
+    \def\minted at cmdtemplate##1##2{%
+      \ifminted at kpsewhich
+        \ifwindows
+          \detokenize{for /f "usebackq tokens=*"}\space\@percentchar\detokenize{a
+          in (`kpsewhich}\space\minted at codefile\detokenize{`) do}\space
+        \fi
+      \fi
+      \MintedPygmentize\space -l #2 -f ##1 -F tokenmerge
+      \minted at optlistcl@g \csname minted at optlistcl@lang\minted at lang\endcsname
+      \minted at optlistcl@inlines
+      \minted at optlistcl@cmd -o \minted at outputdir##2\space
+      \ifminted at kpsewhich
+        \ifwindows
+          \@percentchar\detokenize{a}%
+        \else
+          \detokenize{`}kpsewhich \minted at codefile\space
+            \detokenize{||} \minted at codefile\detokenize{`}%
+        \fi
+      \else
+        \minted at codefile
+      \fi}%
+    \def\minted at cmd{\minted at cmdtemplate{latex -P commandprefix=PYG}{\minted at infile}}
+    % For debugging, uncomment: %%%%
+    \immediate\typeout{\minted at cmd}%
+    % %%%%
+    \def\minted at cmdHTML{\minted at cmdtemplate{html -P noclasses -P
+      nowrap -P hl_lines="\FV at HighlightLinesList" -P
+      style="\minted at get@opt{style}{default}"}{\csname minted at infileHTML\the\c at minted@pygmentizecounter\endcsname}}%
+    \def\minted at cmdPNG{\minted at cmdtemplate{png -P
+      line_numbers=True}{\minted at infilePNG}}%
+    \def\minted at cmdSVG{\minted at cmdtemplate{svg -P
+      linenos=True}{\minted at infileSVG}}%
+    \ifthenelse{\boolean{minted at cache}}%
+      {%
+        \ifminted at frozencache
+        \else
+          \ifx\XeTeXinterchartoks\minted at undefined
+            \ifthenelse{\equal{\minted at get@opt{autogobble}{false}}{true}}%
+              {\edef\minted at hash{\pdf at filemdfivesum{#1}%
+                \pdf at mdfivesum{\minted at cmd autogobble(\ifx\FancyVerbStartNum\z@
+                0\else\FancyVerbStartNum\fi-\ifx\FancyVerbStopNum\z@
+                0\else\FancyVerbStopNum\fi)}}}%
+              {\edef\minted at hash{\pdf at filemdfivesum{#1}%
+                \pdf at mdfivesum{\minted at cmd}}}%
+          \else
+            \ifx\mdfivesum\minted at undefined
+              \immediate\openout\minted at code\minted at jobname.mintedcmd\relax
+              \immediate\write\minted at code{\minted at cmd}%
+              \ifthenelse{\equal{\minted at get@opt{autogobble}{false}}{true}}%
+                {\immediate\write\minted at code{autogobble(\ifx\FancyVerbStartNum\z@
+                 0\else\FancyVerbStartNum\fi-\ifx\FancyVerbStopNum\z@
+                0\else\FancyVerbStopNum\fi)}}{}%
+              \immediate\closeout\minted at code
+              \edef\minted at argone@esc{#1}%
+              \StrSubstitute{\minted at argone@esc}{\@backslashchar}{\@backslashchar\@backslashchar}[\minted at argone@esc]%
+              \StrSubstitute{\minted at argone@esc}{"}{\@backslashchar"}[\minted at argone@esc]%
+              \edef\minted at tmpfname@esc{\minted at outputdir\minted at jobname}%
+              \StrSubstitute{\minted at tmpfname@esc}{\@backslashchar}{\@backslashchar\@backslashchar}[\minted at tmpfname@esc]%
+              \StrSubstitute{\minted at tmpfname@esc}{"}{\@backslashchar"}[\minted at tmpfname@esc]%
+              %Cheating a little here by using ASCII codes to write `{` and `}`
+              %in the Python code
+              \def\minted at hashcmd{%
+                \detokenize{python -c "import hashlib; import os;
+                  hasher = hashlib.sha1();
+                  f =
+                  open(os.path.expanduser(os.path.expandvars(\"}\minted at tmpfname@esc.mintedcmd\detokenize{\")),
+                   \"rb\");
+                  hasher.update(f.read());
+                  f.close();
+                  f =
+                  open(os.path.expanduser(os.path.expandvars(\"}\minted at argone@esc\detokenize{\")),
+                   \"rb\");
+                  hasher.update(f.read());
+                  f.close();
+                  f =
+                  open(os.path.expanduser(os.path.expandvars(\"}\minted at tmpfname@esc.mintedmd5\detokenize{\")),
+                   \"w\");
+                  macro = \"\\edef\\minted at hash\" + chr(123) + hasher.hexdigest()
+                  + chr(125) + \"\";
+                  f.write(\"\\makeatletter\" + macro +
+                  \"\\makeatother\\endinput\n\");
+                  f.close();"}}%
+              \ShellEscape{\minted at hashcmd}%
+              \minted at input{\minted at outputdir\minted at jobname.mintedmd5}%
+            \else
+              \ifthenelse{\equal{\minted at get@opt{autogobble}{false}}{true}}%
+               {\edef\minted at hash{\mdfivesum file {#1}%
+                  \mdfivesum{\minted at cmd autogobble(\ifx\FancyVerbStartNum\z@
+                  0\else\FancyVerbStartNum\fi-\ifx\FancyVerbStopNum\z@
+                  0\else\FancyVerbStopNum\fi)}}}%
+               {\edef\minted at hash{\mdfivesum file {#1}%
+                  \mdfivesum{\minted at cmd}}}%
+            \fi
+          \fi
+          \edef\minted at infile{\minted at cachedir/\minted at hash.pygtex}%
+          \edef\minted at temp@infileHTML{\minted at cachedir/\minted at hash.html}%
+          \global\cslet{minted at infileHTML\the\c at minted@pygmentizecounter}{\minted at temp@infileHTML}%
+          %\global\edef\minted at infilePNG{\minted at cachedir/\minted at hash.png}%
+          %\global\edef\minted at infileSVG{\minted at cachedir/\minted at hash.svg}%
+          \IfFileExists{\minted at infile}{}{%
+            \ifthenelse{\equal{\minted at get@opt{autogobble}{false}}{true}}{%
+              \minted at autogobble{#1}}{}%
+            \ShellEscape{\minted at cmd}%
+            \ShellEscape{\minted at cmdHTML}%
+            %\ShellEscape{\minted at cmdPNG}%
+            %\ShellEscape{\minted at cmdSVG}%
+            }%
+        \fi
+        \ifthenelse{\boolean{minted at finalizecache}}%
+         {%
+            \edef\minted at cachefilename{listing\arabic{minted at pygmentizecounter}.pygtex}%
+            \edef\minted at actualinfile{\minted at cachedir/\minted at cachefilename}%
+            \ifwindows
+              \StrSubstitute{\minted at infile}{/}{\@backslashchar}[\minted at infile@windows]
+              \StrSubstitute{\minted at actualinfile}{/}{\@backslashchar}[\minted at actualinfile@windows]
+              \ShellEscape{move /y
+              \minted at outputdir\minted at infile@windows\space\minted at outputdir\minted at actualinfile@windows}%
+            \else
+              \ShellEscape{mv -f
+              \minted at outputdir\minted at infile\space\minted at outputdir\minted at actualinfile}%
+            \fi
+            \let\minted at infile\minted at actualinfile
+            \expandafter\minted at addcachefile\expandafter{\minted at cachefilename}%
+         }%
+         {\ifthenelse{\boolean{minted at frozencache}}%
+           {%
+              \edef\minted at cachefilename{listing\arabic{minted at pygmentizecounter}.pygtex}%
+              \edef\minted at infile{\minted at cachedir/\minted at cachefilename}%
+              \expandafter\minted at addcachefile\expandafter{\minted at cachefilename}}%
+           {\expandafter\minted at addcachefile\expandafter{\minted at hash.pygtex}}%
+         }%
+        \minted at inputpyg}%
+      {%
+        \ifthenelse{\equal{\minted at get@opt{autogobble}{false}}{true}}{%
+          \minted at autogobble{#1}}{}%
+        \ShellEscape{\minted at cmd}%
+        \ShellEscape{\minted at cmdHTML}%
+        %\ShellEscape{\minted at cmdPNG}%
+        %\ShellEscape{\minted at cmdSVG}%
+        \minted at inputpyg}%
+  }%
+}{}%
+}%
+\html at action@newcommand{inputminted}[3][]{%
+  \message{moodle.sty: Processing \string\inputminted[#1]{#2}{#3} for HTML ^^J}%
+  % arguments #2 and #3 are thrown away: the job is done previously by minted when
+  % calling pygmentize. The file |\minted at infileHTML| generated with our hack will be used.
+  % Since minted is based upon `fvextra' the macro |\moodle at VerbatimInput| works here.
+  \minted at configlang{#2}% grab options set for this specific language
+  \setkeys{minted at opt@cmd}{#1}% grab options in #1
+  \minted at fvset% import options
+  \stepcounter{moodle at pygmentizecounter}
+  \xa\moodle at VerbatimInput\xa{\csname minted at infileHTML\the\c at moodle@pygmentizecounter\endcsname}%
+}%
+\AtBeginDocument{%
+  \ifPDFTeX % pdflatex or latex
+    \@ifpackagewith{babel}{french}{%
+      \PackageWarning{moodle}{Be careful when using LaTeX, moodle, and the babel package with option 'french'. Autospacing produces in undesired symbols in the XML. You can either 1) compile with xelatex/lualatex or 2) add '\NoAutoSpacing' after '\begin{quiz}'.}%
+    }{\relax}%
+  \fi
+}%
 \endinput
 %%
 %% End of file `moodle.sty'.



More information about the tex-live-commits mailing list.