diff options
Diffstat (limited to 'latex/common.tex')
| -rw-r--r-- | latex/common.tex | 50 |
1 files changed, 25 insertions, 25 deletions
diff --git a/latex/common.tex b/latex/common.tex index 6349f3bf..6d925d72 100644 --- a/latex/common.tex +++ b/latex/common.tex @@ -74,7 +74,7 @@ { \refstepcounter{Aufg}% \noindent\textbf{Aufgabe \theAufg\ifstrempty{#1}{}{\ #1}:% - \ifdefempty{\Verteilung}{}{\ \Verteilung{} BE} \hfill \iftoggle{vaguebe}{ca. }{\iftoggle{betable}{/}{}}\ref{a:\theAufg} \ BE}% + \ifdefempty{\Verteilung}{}{\ \Verteilung{} BE} \hfill \iftoggle{vaguebe}{ca. }{\iftoggle{betable}{}{/}}\ref{a:\theAufg} \ BE}% \newline% }{% \ifdefempty{\Verteilung}% @@ -82,7 +82,6 @@ {\setcounter{distSum}{\fpeval{\Verteilung}}}% \renewcommand{\Verteilung}{}% reset the distribution after each exercise \global\let\Verteilung\Verteilung% - \setcounter{AufgVersion}{1}% Reset the exercise version } % Total amount of point * 2 in order to track half points in an integer counter @@ -135,31 +134,32 @@ \newenvironment{Lsg}[1][] {% -\iftoggle{lehrerversion}{% -\noindent\textbf{Lösung:}\ \iftoggle{erwartungshorizont}{#1 \\}{} -}{% -\begin{adjustbox}{max height=0cm, minipage=[0pt]{\textwidth},frame,phantom} -}% + \iftoggle{lehrerversion}{% + \noindent\textbf{Lösung:}\ \iftoggle{erwartungshorizont}{#1 \\}{}% + }{% + \begin{adjustbox}{max height=0cm, minipage=[0pt]{\textwidth},frame,phantom}% + }% }% {%end_def -\iftoggle{lehrerversion}{}{\end{adjustbox}\vspace{-0.5\baselineskip}} -% Overwrite the beA counter -\ifnumcomp{\arabic{beAManuell}}{>}{-1}% -{\setcounter{beA}{\value{beAManuell}}}% -{} -\setcounter{beAManuell}{-1} -% Sum up all points -\addtocounter{be}{\value{beA}} -% Persist the current exercise count -\setcounter{beA}{\fpeval{\value{beA} / 2}}% -\addtocounter{beA}{-1}% decrement beA count because refstepcounter will increment it -\refstepcounter{beA}% make the beA available for the ref and label mechanisms -\expandafter\label{a:\theAufg}% create a label for this exercise -\ifnumgreater{\thedistSum}{-1}{% - \ifnumequal{\thedistSum}{\thebeA}{}{% - \errmessage{Aufg \theAufg: \noexpand\Verteilung (\thedistSum) and point count (\thebeA) are not equal}% - }%ifnumequal -}{}%ifnumfreater + \iftoggle{lehrerversion}{}{\end{adjustbox}\vspace{-0.5\baselineskip}}% + % Overwrite the beA counter + \ifnumcomp{\arabic{beAManuell}}{>}{-1}% + {\setcounter{beA}{\value{beAManuell}}}%true + {}%false + \setcounter{beAManuell}{-1} + % Sum up all points + \addtocounter{be}{\value{beA}}% + % Persist the current exercise count + \setcounter{beA}{\fpeval{\value{beA} / 2}}% + \addtocounter{beA}{-1}% decrement beA count because refstepcounter will increment it + \refstepcounter{beA}% make the beA available for the ref and label mechanisms + \expandafter\label{a:\theAufg}% create a label for this exercise + \ifnumgreater{\thedistSum}{-1}{% + \ifnumequal{\thedistSum}{\thebeA}{}{% + \errmessage{Aufg \theAufg: \noexpand\Verteilung (\thedistSum) and point count (\thebeA) are not equal}% + }%ifnumequal + }{}%ifnumfreater + \setcounter{AufgVersion}{1}% Reset the exercise version } \newtheoremstyle{Bearbeitung}% name of the style to be used |
