2

I have a project with (so far) 5 included files. Within the first and the last included file the Umlauts are properly displayed, in the other three files there are undefined symbols in the output. Fot the title page everything is fine also, the umlaut ü is preperly transferred to ü in the pdf.

%%%%%%%%%\include{Kap1}) - I do not know how to include a minimal sample of an included document in a master document, so I addedb%%%%%%%%%\include{Kap1} to show you how i included, similarly to the other four files... perhaps this is hint enough?

The umplauts are not properly displayed in my output pdf as long as I don't use e. g. \"a which is of course possible put really time consuming while writing a document which should finally consist of 200 pages. And, however, in 2 of 5 files i do not need those \"...

Do I need to use the inputenc and fontenc command AGAIN in the included documents?

Thanks in advance for your answers! And sorry for the uncoloured code - i do not know how to colour it. Lisa

\documentclass[12pt,oneside,a4paper]{scrreprt}

\usepackage[ngerman]{babel}%{hyphsubst}
\usepackage[ansinew]{inputenc}%[ansinew]für eurozeichen; [latin9][UTF8] entfernt helfen ebenfalls nicht 
\usepackage[T1]{fontenc} %für Umlautdarstellung
\usepackage{textcomp} %zur Behebung weiterer Umlautfehler, Extrasymbole

\usepackage{fancyhdr}
\pagestyle{fancy}
\usepackage{setspace}% erlaubt Befehle: singlespacing, onehalfspacing und doublespacing
\onehalfspacing

%%********** ENDE PRÄAMBEL************

\begin{document}
\begin{titlepage}
 \begin{center}
{\Large Lisa Müller}
 \end{center}
\end{titlepage}
%%

%%%%%%%%%\include{Kap1} 

\end{document}
  • 1
    Did you check all included files have the same input encoding? – Bernard Sep 8 '15 at 10:31
  • 2
    Please verify for each if your documents that they are all written in the same encoding. Are you 100% sure you are using ansinew? Most editors today use utf8. Many of them will even tell you which encoding withe current file is using (texmaker and texstudio are good at that). – daleif Sep 8 '15 at 10:31
  • at least ansinew doesn't work in my installation but utf8 does. Additional, you could try to use lmodern for the eurosymbol. (and have a look at you tex-files are the saved in utf8? TeXStudio shows the encoding of the shown tex-file in the bottom menu but you could also check it in most text editors like notepad++ ) – jlk Sep 8 '15 at 10:42
  • 1
    lmodern doesn't only have an ok euro symbol, it has a better support of umlaute and sonderzeichen in general. Because it's basically an updated version of computern modern (the standard font of LaTeX, some people may prefer a different choice of words) the math fonts of the ams-package etc match latin modern as good as the match computer modern. (tug.dk/FontCatalogue/lmodern) – jlk Sep 8 '15 at 11:02
  • 1
    Please tell us which editor do you use. Then we can tell were you can check the encoding (TeXnicCenter and TeXworks shows the coding in the bottom line of the window). – Kurt Sep 8 '15 at 11:31
1

There are two points where you have the control over the file encoding:

  1. for example for pdflatex: \usepackage[utf8]{inputenc}
  2. for TeXnicCenter (and other editors): define with which encoding the TeX file has to be saved on the hard disk.

BTW: The encoding UTF-8 is in my opinion the best choice, then you can exchange files between different operating systems usually with no problems.

Both choices for the encoding has to be the same!

The following images shows the way you can check and change the encoding with TeXnicCenter:

enter image description here

In the bottom line of TeXnicCenter (see small red circle) you can see the encoding the file has at the moment you opened it.

If you want to change the encoding, click on "File" -- "Save as". Then you can change the encoding (see big red circle).

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.