In my document, which is encoded as utf8 throughout (hopefully), umlaute etc. in the document body are put out correctly, but those defined in a \newcommand are not. I have tried some alternatives to writing the unlaute plain, and \symbol works, while the international accent does not, and I'd rather not use it since it is a little cumbersome.
See the following example:
\newcommand{\myPlace}{Örtlichkeit}
\newcommand{\myWhat}{\"{O}rtlichkeit}
\newcommand{\myHmm}{Stra\symbol{255}e}
\documentclass{scrlttr2}
\usepackage[ngerman]{babel}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\begin{document}
\myPlace
\myWhat
\myHmm
ÖÄÜäöüß
\end{document}
Thanks for any input!
\newcommand{\myPlace}{\"{O}rtlichkeit}and\newcommand{\myHmmm}{Stra\ss e}. It's theinputencpackage that assigns the desired meaning to the non ASCII characters and using them before loading the package can lead to puzzling results. – egreg Sep 21 '12 at 12:08\newcommandinstruction. – Mico Sep 21 '12 at 12:15