2

I am a Linguistics PhD student at U.Florida, writing my dissertation. The LaTeX class from our editorial office conflicts with gb4e (among other packages). Is there a way to override the style sheet temporarily in order to use gb4e?

The template can be downloaded from http://helpdesk.ufl.edu/wp-content/uploads/2012/12/latex_spring_2011.zip.

The template is actually a number of different .tex files. When I have \usepackage{gb4e} anywhere in the packages.tex file (both before and after {hyperref}), the main file will not compile. As soon as I comment out \usepackage{gb4e}, the document compiles.

The template is buggy to begin with: I couldn't get it to compile at all with TeXnicCenter (I'm having to use WinEtd).

I've also used {covington}, but it changes the numbering, formatting like this (1-1), rather than simple numbers (1), and the gloss (middle line) is in a different font, which UF's editorial office disallows.

4
  • 3
    Hi and welcome to TeX.sx. In its current form, your question might not receive many answers. Please take a look at the How to Ask-page and try to improve your question according to the guidance found there. This may require you to show some effort on your part in terms of attempting a solution. If you have questions about what to do or if you don't quite understand what this means, please ask for clarification using the add comment function.
    – jub0bs
    Apr 2, 2013 at 11:05
  • 1
    The template folder you link to is really a mess since it includes all sorts of old versions of packages which might be causing the problem. The sample file doesn't compile either. So without your creating a minimal document to play with that shows the problem, this will be impossible to diagnose. As a guess, though, try adding \noautomath immediately after the \usepackage{gb4e} line in your preamble/packages.tex file.
    – Alan Munn
    Apr 2, 2013 at 14:26
  • @AlanMunn, thanks for the advice. It worked almost perfectly. The only issue is that the text and gloss lines are in a serif font, while the rest of the document is in a non-serif font. I think I can fix that. You're right that the template is a mess. UF even admits to it. They recommend WinEDT because it allows you to ignore errors and continue the compilation effort.
    – ToddAO
    Apr 2, 2013 at 19:53
  • 1
    Florida pays its football and basketball head coaches almost $3 million a year each. You'd think they could spring for a decently written thesis class. :)
    – Alan Munn
    Apr 3, 2013 at 0:40

1 Answer 1

6

The most likely source of the incompatibility between gb4e and other packages is the fact that gb4e implements catcode changes that allow _ and ^ (sub- and superscripts) to be used outside of math. This breaks lots of things if you're not careful, but since it's so useful, most of us put up with it and find workarounds when needed. Your problem is that the template you've been given to work with is horrendous and so finding the actual source of the problem would be difficult. So the best solution is simply to turn off the gb4e changes. You can do this by adding \noautomath to your preamble immediately after loading gb4e. So your preamble (or in this case the packages.tex file) should have the following lines:

\usepackage{gb4e}
\noautomath

You can try turning it back on after the preamble, by adding the command \automath or use other methods for sub- and superscripts (surround them with $..$ if you want math style indices or use \textsuperscript and \textsubscript (by loading the fixltx2e package.)

On your second problem, gb4e defines three hooks for the formatting of the glosses. You can change them in the following way:

\let\eachwordone=\sffamily
\let\eachwordtwo=\sffamily
\let\eachwordthree=\sffamily

This will make all the gloss and translation lines use the sans serif font.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .