I'm having some issues with listings
that include German
Umlaute. The following example code generates a completely messed up PDF.
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[]{listings}
\begin{document}
\begin{lstlisting}[language={[LaTeX]TeX},inputencoding={utf8},extendedchars=false]
Staatsangehörigkeit
\end{lstlisting}
\end{document}
Does anyone have an idea how to fix this?
Best Answer
the normal listings package doesn't provide unicode support. I use the following code to work around the Problem
I also tried listingsutf8 and listings2 which ist BETA, but for me the literate solution just works perfekt ;)
edit:sry, marco has the same solution earlier...