Debian Codegraph @

texmf-dist/doc/latex/moodle/test/test_includegraphics_with_svg.tex

raw
1 % !TeX encoding = UTF-8
2 % !TeX spellcheck = en_US
3 % !TEX TS-program = lualatex
4 \documentclass{article}
5 \usepackage[nostamp,svg]{moodle}
6 \ifPDFTeX % FOR LATEX and PDFLATEX
7 \usepackage[utf8]{inputenc} % necessary
8 \usepackage[T1]{fontenc} % necessary
9 \else % assuming XELATEX or LUALATEX
10 \usepackage{fontspec}
11 \fi
12
13 \begin{document}
14
15 \section*{Introduction}
16
17 This document is intended to check picture inclusion using
18 \verb|\includegraphics| together with the \texttt{svg} package option.
19 When this option is used, vector graphics will be converted to SVG rather than
20 being rasterized. The picture inclusion using \verb|\includegraphics| is mostly
21 unchanged. If SVG files are included, they are converted on-the-fly to PDF.
22 Conversions from and to SVG are performed using \textsf{Inkscape}. The
23 \textsf{Scour} utility is used to perform an optimization on intermediate SVG
24 files, before inclusion to the XML.
25
26 \begin{quiz}{Scalable Vector Graphics}
27
28 \begin{multi}{Picture}
29 \includegraphics{fig/NoodlE_logo.SVG}
30 \item[feedback={\includegraphics{fig/2 2.pdf}}]* \includegraphics{fig/3.gif}
31 \item[feedback={\includegraphics{fig/4.jpg}}] \includegraphics{fig/5.jpeg}
32 \end{multi}
33
34 \graphicspath{{./fig/}}
35
36 \begin{matching}[dd]{Picture}
37 \includegraphics[width=2cm]{NoodlE_logo.SVG}
38 % on Linux, if .SVG is omitted moodle tries to manipulate "NoodlE_logo.svg"
39 \item \includegraphics{2 2} \answer \includegraphics{3}
40 \item \includegraphics{4} \answer \includegraphics{5}
41 \item \includegraphics{3} \answer \includegraphics[width=2em]{2 2}
42 \end{matching}
43
44 \end{quiz}
45
46 \end{document}