\begin{rambling}
This is a brief introduction to LaTeX – for dummies like myself!
So……What’s LaTeX?
LaTeX (/‘leɪtɛk/) is a typesetting language widely used in academia. If this is the first time you have ever heard of LaTeX, you might want to have a look at this. Or this for a quicker read. You know what, just google it.
Why choose LaTeX over Word?
- It is content-oriented: you worry about the writing, let LaTeX handle the layout
- It produces highly structured documents
- It makes referencing and outputting bibliography so much easier
- Scientists appreciate the subtle beauty of LaTeX: typography
- It’s free!
TeX Editors: ShareLaTeX, TeXmaker, Atom, Sublime Text
If you are new to LaTeX and need to get some work done soon but has absolutely no idea where to start, I recommend ShareLaTeX, an online platform for LaTeX newbies because:
- There lots of free templates and comprehensive guidelines available
- It has pretty a user-friendly interface, and compiling takes only seconds
- There’s o need to download any TeX distribution or editor
- Absolutely no prior experience needed
BUT – it comes with a few pitfalls:
- You cannot work on your document without the internet
- There are just too many commands to remember (especially for mathematical symbols)
- Potential issues with copyright and privacy
For these reasons, I eventually moved all my documents offline. There are three editors that I regularly use for typesetting stuff in LaTeX: TeXmaker, Atom, Sublime Text. Other popular editors include TeXShop, TeXstudio, TeXworks, and LyX. Here’s a comparison of TeX editors.
As a beginner, I find TeXmaker pretty handy, especially because its interface provides a clear structure of your tex file, allows you to view the pdf file alongside the tex script, and has quick access to mathematical/logical symbols that we semanticists always need. It works perfectly on Linus, Mac OS X, and Windows systems. Since I’m using a MacBook, I got the MacTeX Distribution and it pretty much has everything I need.
A few things to note:
- Configuring the TeXmaker editor
- APA style for linguistics: there are several ways to do APA style referencing in LaTeX, but it seems like Biblatex + Biber + Babel is the closest approximation as far as I know. To do this in TeXmaker, go to Preference -> Commands, then reset the value of Bib(la)tex to “biber” % before including the following in your preamble:
\usepackage[english]{babel}
\usepackage[style=apa,sortcites=true, sorting=nyt, citestyle=apa, backend=biber]{biblatex}
\DeclareLanguageMapping{english}{english-apa}
As you become more proficient in LaTeX, you might want to use an editor that looks neater (less is more!). If that’s the case, then perhaps Atom and Sublime Text will be more to your liking. There are countless online tutorials that can tell/show you how to get LaTeX to work on these editors – it takes a bit of configuration since neither is specifically made for LaTeX, but it’s really quite straightforward. Normally I use these two editors for typesetting fairly short documents, e.g. CV and resume. Plus you can get everything color-coded which is kinda cute!
LaTeX for Linguists
- A Guide to LaTeX for Linguists (University of Essex)
- Short Course on LaTeX for Linguists (Matt Tucker & Robert Henderson)
- WikiBooks: LaTeX/Linguistics
- LFG & Glue Semantics: Avery Andrews
- (La)TeX macros: Christopher Manning
- Basic examples
- Phrase structure trees: use \Tree from the qtree package to create syntax trees and and the tree-dvips package to add movement arrows.
- Interlinear glosses: you can use the gb4e package and then introduce the example sentences in the exe environment, using \ex (which automatically numbers all examples) and \gll (which handles the glossing). IMPORTANT: make sure gb4e is the last \usepackage call in the document’s preamble, because otherwise you may get exceeded parameter stack size error (and other weird errors) [Examples]. Alternatively, use the covington package or the linguex package to stay out of trouble.
Common questions and suggestive solutions
- Got a question?
- TeX – LaTeX Stack Exchange
- LaTeX forum on Reddit
- 中文TeX (in Chinese)
- Templates:
- LaTeX Templates
- howtoTeX
- My own: CV / paper
- Symbols:
- Draw it! Detexify
- The Comprehensive LaTeX Symbol List (including characters from The Simpsons!)
- Coffee Stains
- Tracking changes & collaboration:
- The changes package
- There also are other ways
- Word count for LaTeX: TeXcount
- Header and Footer: with {fancyhdr}
- LaTeX Table Generator
- LaTeX cheat sheet
- How to approach errors (hint: panicking doesn’t help)
Websites for general resources
- The TeX Book: a Bible for TeX users
- The (Not So) Short Introduction to LaTeX: a Bible for beginners
- TeXblog: news and resources in TeX
- TeX tips on Twitter: daily tips on (La)TeX and typography
\end{rambling}