aboutsummaryrefslogtreecommitdiff
path: root/examples/exshexample-embedded.tex
blob: d9cf5576471a02947bca0d1c03bcd99c5ef4df34 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
\documentclass[aspectratio=169]{beamer}
\usetheme{Berlin}
\usefonttheme{professionalfonts}
\useoutertheme{infolines}
\useinnertheme{rounded}
\setbeamertemplate{itemize items}[circle]
\setbeamertemplate{enumerate items}[circle]
\setbeamertemplate{sections/subsections in toc}[circle]
\setbeamercolor{item projected}{bg=black}
\setbeamercolor{item}{fg=black}
\setbeamertemplate{navigation symbols}{}

\setbeamertemplate{footline}[frame number]

\setbeamercolor{block title}{bg=black}
\setbeamercolor{section in toc}{fg=red,bg=white}

\AtBeginSection[]{
\begin{frame}
\begin{block}{Overview}
\tableofcontents[sectionstyle=show/shaded,subsectionstyle=hide/hide/hide]
\end{block}
\end{frame}
}

\AtBeginSubsection[]{
\begin{frame}[allowframebreaks]
\begin{block}{Overview}
\tableofcontents[sectionstyle=show/hide,subsectionstyle=show/shaded/hide]
\end{block}
\end{frame}
}


\author{Example Author}
\title{Embedding Exercises}
\subtitle{a never-ending journey}
\makeatletter
\date{compilation date: \the\year-\two@digits{\the\month}-\two@digits{\the\day}}
\makeatother



\newenvironment<>{stlist}[1][]{%
  \setbeamertemplate{enumerate items}{\alph{enumi})}
  \setbeamertemplate{enumerate subitem}{\arabic{enumii}.}
  \setbeamertemplate{enumerate subsubitem}{\arabic{enumii}.}
  \begin{enumerate}[#1]
}{\end{enumerate}}

%embedded already sets a lot of values, see documentation
%in non-embedded mode, exercisesheets clears beamers headline
%and footline if non of the beamerwith...line arguments are used.
\usepackage[embedded]{exercisesheets}
\makeatletter
\exshset{
  strings/sheet={Missions},
  exercisespath=exercises,
  subtask environment=stlist,
  task restate font={\color{gray}},
  imp/.style={pointsinfo=important},
  vi/.style={pointsinfo=very important},
}
\makeatother

\parindent 0pt
\setlength{\parskip}{\baselineskip}



\begin{document}
\begin{frame}
\maketitle
\end{frame}

\section{Introduction}

\begin{frame}
  Let me tell you everything \pause\textbf{about embedding exercises}.
\end{frame}

\section{Examples}

\subsection{without a sheet environment}

  \begin{frame}
    \begin{block}{}
      Since our exercises are already in a dedicated subsection,\pause
      we do not need an extra sheet environment.
    \end{block}
  \end{frame}

  \includeexercise*[imp]{exshexample-ex1}
  \includeLexercise*[vi]{exshexample-ex2}

\subsection{with a sheet environment}

\begin{sheet}[note={The exercises are within a separated sheet
  environment.}]
  \includeexercise*[imp,solutions]{exshexample-ex1}
\end{sheet}

\begingroup
\def\sheetfancy[#1]#2{\textcolor{red}{#2}}%nope, nothing happens
\exshset{sheet sectioning cmd=\sheetfancy}

\begin{sheet}[note={This sheet header looks exactly like the first one, because \texttt{sheet sectioning cmd} is only used for
non-beamer documents.}]
  \includeLexercise*[imp,solutions]{exshexample-ex2}
\end{sheet}
\endgroup


\end{document}