I want to use the commentpackage with special german characters (umlauts), but it doesn't work. I get the following error message:
ERROR: Undefined control sequence.
--- TeX said ---
\UseTextAccent ...up \@firstofone \let \@curr@enc
\cf@encoding \@use@text@en...
l.24 Deutsche Umlaute: äüö
Here is my example:
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{ngerman}
\usepackage{ascii}
\usepackage{comment}
\specialcomment{testcomment}{\asciifamily}{\normalfont}
\begin{document}
Here is a comment which works.
\begin{testcomment}
Test
\end{testcomment}
Here is a comment that doesn't work.
\begin{testcomment}
Deutsche Umlaute: äüö
\end{testcomment}
\end{document}
Any idea, how to make this work?
Edit
Using
\renewcommand\ThisComment[1]{%
\immediate\write\CommentStream{\unexpanded{#1}}%
}
after \usepackage{comment} solved the problem completely.
\usepackage[ngerman]{babel}. – Juri Robl Mar 05 '14 at 11:33\asciifamilyfont seems to contain umlauts. After aplying the answer in the other question linked above, everything seems to work as it should... – student Mar 05 '14 at 12:19