1

I am layouting my PhD theses in linguistics and I am struggling with the layout of the linguistic examples. Thanks to StackExchange, I could solve the problem of font size (see here). Now, however, I am struggling with using tipa and fontenc. To me it seems that I need the fontenc package because of tipa (as suggested in the tipa documentation on page 11). If I do not load fontenc, I cannot compile the IPA symbols (instead I am getting the message ! Undefined control sequence). And if I load fontenc, it prints some letters of the remaining text in Greek letters.

Here is a WME and any help is very much appreciated:

\documentclass[twoside, fontsize=10.2pt, listof=nochaptergap]{scrbook}

%======================================
% === Papierformat ===
\usepackage[paperwidth=17cm, paperheight=24cm, %seitengrösse
outer=2.7cm, inner=2.4cm, top=2.5cm,bottom=2.5cm, %seitenränder
headsep=0.62cm]{geometry} %abstand von kopfzeile zu text
\setlength{\textheight}{19cm} \setlength{\textwidth}{11.9cm} %satzspiegel definieren

% === Schriftart ===
\usepackage{fontspec}
\setmainfont{Times New Roman}

% === Einzüge ===
\setlength\parindent{6mm}

%======================================
% === language packages ===
\usepackage[ngerman]{babel}

%======================================
% === testing ===
\usepackage{showframe}
\usepackage{blindtext}

%======================================
% === Querverweise ===
\usepackage{hyperref} % muss vor leipzig geladen werden
\hypersetup{colorlinks=false, linkcolor=black,unicode=true,
 citecolor=blue, filecolor=blue, urlcolor=blue, pdfauthor=Hasse, pdfkeywords=}
\urlstyle{same}

%======================================
% === Glossar ===
\usepackage[nomain,style=long,nonumberlist,toc,xindy,nopostdot,sort=def,acronym]{glossaries}% package for creating a glossary and package for leipzig glosses (nomain, weil es in einem separaten file ist)
\usepackage{glossary-mcols} %dann wird glossar in zwei spalten gedruckt

% # \input{glossary.tex}

\usepackage[block]{leipzig}

\makeglossaries

\renewcommand{\leipzigname}{Glossierung}%die Leipzigliste umbenennen

%%customised glossings
\renewleipzig{abl}{abl}{Ablativ}
\renewleipzig{acc}{acc}{Akkusativ}
% some more customised glossings

%======================================
% === linguistic examples ===
%
\usepackage{microtype,booktabs}
\usepackage{langsci-gb4e} %https://ctan.math.illinois.edu/macros/xetex/latex/langsci/documentation/langsci-gb4.pdf

\renewcommand{\eachwordone}{\itshape} %italics in first line

%======================================
% === linguistic specific packages ===
\usepackage[english]{varioref}
\usepackage[T2A,T1,T3]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[noenc]{tipa} % overview IPA signs http://www.ling.ohio-state.edu/events/lcc/tutorials/tipachart/tipachart.pdf [16.6.2016]

% === new tipa symbols ===
\newcommand\uhalb{\ipabar{u}{.7ex}{.5}{}{.5}}
\newcommand\aganz{\ipabar{a}{.5ex}{0.8}{}{}}

%======================================
%======================================
%======================================
\begin{document}
\setcounter{page}{5}

\blindtext

\begin{exe}
\ex\label{ex:specificlabel}
\gll es hungrigs ross\\
a.\textsc{nom/acc.neutr} hungry.\textsc{nom/acc.neutr} horse \\
\trans `a hungry horse'
\end{exe}

\blindtext

\textsl{\textipa{5}}

\textipa{mid5r5N} gälld

\blindtext

\end{document}
5
  • 3
    You might want to try the tipauni package as a replacement for tipa. I'm not sure whether it covers the full feature set of tipa, but at least your example document works with it (you might want to take a close look at its documentation; also please note that it loads fontspec and by default the font CharisSIL, you can change the font of your document using its documentfont option, or if you want to set up your fonts outside of tipauni use the preservefont option).
    – Skillmon
    Aug 24, 2022 at 13:42
  • Thank you very much! I have tried to use tipauni instead of tipa. It works with most of my document. As soon as I am trying to compile a figure enviroment, however, the PDF cannot be compiled. Does anyone have any idea what might be causing this problem?
    – ahasse
    Sep 6, 2022 at 10:39
  • 1
    @ahasse Can you post a minimal working example which demonstrates that a figure doesn't work with tipauni?
    – Niranjan
    Sep 6, 2022 at 11:54
  • Also it would be great if you could tell us what error you get when you use figure with tipauni.
    – Niranjan
    Sep 6, 2022 at 11:55
  • I have just made a MWE and run it... and it works. However, only with a new figure. Weirdly, it no longer works with my old figures which used to be in my theses. So there must be a problem with these files rather than with the code.
    – ahasse
    Sep 7, 2022 at 18:07

0

You must log in to answer this question.

Browse other questions tagged .