corso-di-italiano-per-stran.../definitions.tex

34 lines
881 B
TeX
Raw Permalink Normal View History

2020-11-14 19:20:06 +01:00
\newcommand\gm{\textit{(m.)} }
\newcommand\gf{\textit{(f.)} }
\definecolor{translationcolor}{RGB}{128, 0, 128}
2020-11-14 22:19:02 +01:00
\providecommand{ActiveTranslation}{none}
2020-11-14 19:20:06 +01:00
\newenvironment{translation}[1]{%
\def\switchtolang{#1}
2020-11-14 22:19:02 +01:00
\ifx\switchtolang\ActiveTranslation
\bigskip
\begin{adjustwidth}{3em}{}
2020-11-14 19:20:06 +01:00
\begin{\switchtolang}
\textsc{\titlecap{\switchtolang}}:
\itshape\color{translationcolor}
2020-11-14 19:20:06 +01:00
}{%
\end{\switchtolang}
\end{adjustwidth}
\bigskip
2020-11-14 19:20:06 +01:00
\else % do not translate
% No output
\fi
}
2023-01-08 14:07:59 +01:00
\newcommand\itranslation[2]{%
\def\switchtolang{#1}
\ifx\switchtolang\ActiveTranslation
\begin{\switchtolang}
\textsc{\titlecap{\switchtolang}}:
\itshape\color{translationcolor}
#2
\end{\switchtolang}
\else % do not translate
% No output
\fi
}