2

I'm trying to use german umlauts in my document, however if I use it like that:

\documentclass[a4paper]{scrartcl}

\usepackage[T1]{fontenc}
\usepackage[ngerman]{babel}
\usepackage[ansinew]{inputenc} 
\usepackage[pdftex]{graphicx}
\usepackage{atbegshi}% http://ctan.org/pkg/atbegshi
\AtBeginDocument{\AtBeginShipoutNext{\AtBeginShipoutDiscard}}
\usepackage{wasysym}
\setlength{\parindent}{0pt}
\pagenumbering{gobble}
\graphicspath{{Bilder/}}

\begin{document}
\begin{center}
\centerline{\includegraphics[scale=0.9]{Deckblatt.png}}
\end{center}
\tableofcontents
\newpage
\section{Voraussetzungen f{\"Ä}r  das Programm}

Wenn Sie das Programm nutzen mchten, benigen sie die aktuellste Version von Java.

\end{document}

It is shown with double umlauts above for some reason, why is that?

double colons

  • 1
    Welcome to TeX.SX! Use either fÄr (recommended) or f\"Ar, but not both. – Phelype Oleinik May 31 at 10:54
  • 2
    They're growing/reproducing!! #blumlauts – Steven B. Segletes May 31 at 10:56
  • Are you sure your files are encoded in ansinew? Not utf8, which is the standard for years? – Johannes_B May 31 at 11:07
  • That's not the output I'm getting from that code. As an aside, the code is short enough but there is still a lot of redundant cruft. – JPi May 31 at 11:24
  • Did my answer helped you? If yes, please consider accepting and upvoting it. That is the way here to say "Thank you for your help"! – Mensch Jun 3 at 16:42
1

Well, it is an issue with your file encoding.

See the following reduced code

% https://tex.stackexchange.com/questions/493504/german-letters-with-double-umlauts
\documentclass[a4paper]{scrartcl}

\usepackage[T1]{fontenc}
\usepackage[ngerman]{babel}
\usepackage[ansinew]{inputenc} % <======================================


\begin{document}

\section{Voraussetzungen f{\"u}r  das Programm} % <=====================

Wenn Sie das Programm nutzen m\"ochten, ben\"otigen sie die aktuellste Version von Java.

\end{document}

with ansi encoding (see red circle) in the image showing editor TeXnicCenter with the code above in ansi encoding:

editor texniccenter

Compiling this returns the following pdf (please see that I used the correct \"u for ü, \"o for ö etc. and not your wrong code!):

resulting pdf

Nowadays encoding utf8 is the standard, see the following code (you can use \usepackage[utf8]{inputenc} or leave it out, with current TeX distribution utf8 is standard and neeeds not to be called):

\documentclass[a4paper]{scrartcl}

\usepackage[T1]{fontenc}
\usepackage[ngerman]{babel}
\usepackage[utf8]{inputenc} % <====================================== utf8 is standard now


\begin{document}

\section{Voraussetzungen für  das Programm} % <=====================

Wenn Sie das Programm nutzen möchten, benötigen sie die aktuellste Version von Java.

\end{document}

and in editor it needs to have encoding utf8 (see red circle in screenshot):

code in utf8 in editor

and the resuting pdf:

resulting pdf with utf8

As you can see the written code is much better readable with real german umlauts ...

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.