AUCTeX is a package for writing (La)TeX, ConTeXt, docTeX and TeXinfo in Emacs and XEmacs.

learn more… | top users | synonyms

60
votes
5answers
12k views

Useful shortcuts or key bindings or predefined commands for emacs+AUCTeX

On of the problems I've encountered with emacs in general, and with the defaults key bindings in particular, is the diversity. There are simply so many of them, that sometimes, at the end of the day, ...
40
votes
1answer
2k views

AucTeX extension for TikZ

Is there an AucTeX extension which supports the TikZ syntax and that one of the tkz-collection as well? In particular I want thinks like: syntax highlighting proper indentation that ...
33
votes
6answers
6k views

What is your favorite Emacs and/or AUCTeX command/trick?

What is your favorite Emacs and/or AUCTeX command/trick? The point here is that I don't know what I don't know. I'm an Emacs and AUCTeX user looking to improve my Emacs & AUCTeX use, especially ...
26
votes
2answers
476 views

Click on package name to open corresponding style file?

I think it would be super if, in my LaTeX editor, I could click on the name of package... \usepackage{blob} ... and the corresponding style file, blob.sty, would be opened. Do any LaTeX editors ...
25
votes
8answers
7k views

Setup SyncTeX with Emacs

I want to setup SyncTeX with Emacs, or, more specifically, with AUCTeX, and Evince in Ubuntu. How can I do that? I would like both forward search (from source to output) and inverse search (from ...
24
votes
1answer
471 views

Folding braces in Emacs/AucTeX

I have some code looking like this: 142 \newcommand*\john[2]{ 143 blah blah blah blah 144 blah blah 145 blah blah blah 146 blah 147 } 148 149 \newcommand*\peter[3]{ 150 blah blah ...
17
votes
3answers
3k views

RefTeX won't find my .bib file in local library tree

RefTeX gives out the following error when trying to insert a citation: No valid bibliography in this document, and no default available I keep a master .bib file in ...
16
votes
3answers
3k views

Does AucTeX Autocomplete?

The quick start guide for AUCTeX says As nearly everywhere in AUCTeX, you can use the TAB or SPC key to get a list of available level names, and to auto-complete what you started typing. Which ...
15
votes
2answers
604 views

Predictive mode: Only auto-complete LaTeX keywords

I typeset documents in French, and I don't really need auto-completion of the words that I type. I do, however, love the completions features that Predictive mode offers for LaTeX commands. Is there ...
15
votes
2answers
287 views

How to make AUCTeX ignore syntax highlighting within environment

I have a problem with syntax highlighting in the Emacs editor using AUCTeX. The problem occurs in particular with the Verbatim environment from the fancyvrb package. Consider the following code: ...
14
votes
1answer
850 views

How can I make AUCTeX use the spelling dictionary in the same language as babel is loaded with?

Is it possible to setup AUCTeX so that it loads the spelling dictionary in the same language as the language used by babel? For example, is it possible to load the Danish ispell dictionary when a ...
13
votes
4answers
4k views

AUCTeX and XeTeX

I use Emacs+AUCTeX to write my *-tex. Using the PDF mode, I can run pdfTeX automatically with the C-c C-c command. However, I don't see a way to run XeTeX automatically, or even set up a command ...
13
votes
3answers
7k views

How to preview LaTeX in Emacs?

I want a similar layout as in SO, I use it currently as my editor but I would like to find such tool under my fingers. I am more vi-prone so having hard time to get preview-latex working with emacs. I ...
13
votes
1answer
208 views

Skip spelling in Emacs for the content of a user macro

In Emacs, in order to skip spelling for the arguments of a user macro, one appends an entry to the ispell-tex-skip-alists variable. For example, to skip parsing the argument of \mycommad, one adds ...
12
votes
2answers
2k views

How to turn on flyspell mode with AucTeX?

I'm using flyspell mode, but unfortunatly I have to M-x flyspell-mode in each AucTeX buffer. Somehow (add-hook 'LaTeX-mode-hook 'flyspell-mode) doesn't work for me. What is the correct flyspell-hook ...
12
votes
3answers
1k views

Uninformative error message when using AUCTeX

I often have this error when using AUCTeX: "TeX-error: Error occured after last TeX file closed" However, when running for instance pdflatex on the command line, I have a proper error message. But ...
12
votes
2answers
987 views

Emacs, RefTeX and Cleveref – can they work together?

Trying to look for an answer in the net yielded only one questions and one answer which I could neither understand nor use. On tex.stackexchange I found only this question which was answered but I'm ...
12
votes
4answers
6k views

Launching an external PDF viewer from Emacs/AUCTeX on a Mac OSX fails.

I am trying to set Emacs/AUCTeX to invoke an external PDF viewer so I can view the document output, preferably with source correlation via SyncTeX. AUCTeX, by default, suggested evince file.pdf; ...
11
votes
3answers
368 views

Click on macro name to jump to its definition?

Encouraged by a super response to my previous question on a similar topic, I shall persevere with a similar line of inquiry. I think it would be super if, in my LaTeX editor, I could click on a macro ...
10
votes
2answers
218 views

Get emacs to automatically insert \end{} commands after a \begin{} command

I've recently switched from Kile to Emacs/AUCTeX for LaTeX editing. I like AUCTeX a lot more in general, in part because I've put a lot of effort into learning Emacs really well. One feature I really ...
10
votes
3answers
4k views

pdflatex fails within Emacs.app, but works in terminal

LaTeX rookie here. I'm running OS X 10.7 with Emacs 24, Auctex 11.86 and TexLive 2011 via MacTex. When i run LaTeX through Emacs in the terminal it outputs my test.tex as test.pdf just fine. ...
10
votes
1answer
356 views

AUCTeX's csquotes integration does not work together with babel

I use the AUCTeX feature to expand " into csquotes macros. To enable it I have put the following in my .emacs: ;; " expands into csquotes macros (setq LaTeX-csquotes-close-quote "}" ...
10
votes
1answer
903 views

How to make `latexmk` run the appropriate amount of times

System: Ubuntu 13.04, Texlive2012, Emacs 24.something, I run Emacs from the terminal and not the GUI, and I have server mode on in Emacs. When compiling my latex documents, I use AucTeX in emacs to ...
10
votes
1answer
943 views

How can I make AUCTeX spell check in the language specified by babel and csquotes macros?

It is possible to make AUCTeX load the spelling dictionary of the language which babel is loaded with. One further convenience would be for it to appropriately react to changes of language within a ...
9
votes
3answers
624 views

Open included files in emacs+AUCTeX

When working with emacs+AUCTeX I would like to consider a project with one main.tex in which you have many include's. Is it possible somehow to open the included files from within the buffer where ...
9
votes
1answer
288 views

AUCTeX – new commands recognized as such

Many non-base commands, quite used today, are not recognized as such by AUCTeX. This is understandable as not everyone will use them, and not every time. I'm thinking about commands like ...
9
votes
1answer
3k views

Installing new packages from ctan through command line or AUCTeX on Mac OS?

I've needed a few new packages for some macros to draw diagrams that I'm working with. I've heard that some LaTeX editors can automatically download the correct packages from CTAN when they're not ...
9
votes
1answer
261 views

How can I make AUCTeX use the spelling dictionary in the same language as polyglossia is loaded with?

Is it possible to setup AUCTeX so that it loads the spelling dictionary in the same language as the language used by polyglossia? For example, is it possible to load the Danish ispell dictionary when ...
9
votes
2answers
487 views

More fine grained syntax highlighting in Emacs/AUCTeX

I'm using Emacs with AUCTeX to do all my LaTeX. When it comes to syntax highlighting it seems that all mathematics is by default just orange. Do you know of a mode or package that adds some more fine ...
9
votes
1answer
582 views

Emacs and latex math delimiters

The forward-sexp command in EMACS can be used to find the $ that closes an inline equation: if the point is before the $ that opens the equation, then forward-sexp moves the point after the closing $. ...
8
votes
1answer
1k views

auctex 11.86 in emacs 24: Don't know how to compile nil

I run emacs 24.2.50.1 and auctex 11.86 on debian stable. When i open a tex file with $ emacs text.tex Emacs shows the following line 38 times in the Compile-Log buffer ...
8
votes
2answers
291 views

Matching the delimiters \{ and \} in AUCTeX

I'm using AUCTeX and would like the delimiters \{ and \} to be matched. How can I (permanently) achieve matching of these delimiters? The link I provided indicates that I should edit a syntax table, ...
8
votes
1answer
405 views

get emacs to automatically use biber instead of bibtex

I was reading the question titled Customizing emacs to use biblatex-biber instead of bibtex. In that question, user @PLK mentions that as of auctex 11.87, auctex should automatically check if you are ...
8
votes
4answers
508 views

Auctex: how to cause math mode dollars to be closed automatically with electric-pair

I use electric-pair mode to cause brackets to be automatically closed for me, so that when I enter (, { or [, the closing bracket is automatically also entered into the buffer and the cursor is placed ...
8
votes
2answers
763 views

Entering math mode in AUCTeX using \( and \)

As pointed out in this answer, using \( and \) in order to enter inline math mode in LaTeX is the recommended practice. However, this takes a bit longer if one compares it to $. Is there a way to ...
8
votes
1answer
92 views

Making AUCTeX aware of the TeX engine set in master file

Is there a way to make AUCTeX aware of the TeX engine local variable set in a master file when I compile from other files? master.tex: \documentclass{minimal} \usepackage{fontspec} \begin{document} ...
8
votes
2answers
379 views

Unable to reference new environments with RefTeX

I was trying to add new environments to AUCTeX doing what the RefTeX's manual says, so I added the following to my .emacs: (add-hook 'LaTeX-mode-hook 'turn-on-reftex) (setq reftex-label-alist ...
8
votes
0answers
146 views

Pronunciation of “AUCTeX” [closed]

I'd like to give a tutorial on AUCTeX to my colleagues but it occurs to me that I've never heard the name of this package pronounced. It seems the first three letters could be pronounced individually ...
7
votes
4answers
3k views

Customizing pdfLaTeX for a particular file with AUCTeX?

I'm trying to use the TikZ 'external' library, available as of PGF 2.10. This requires running pdfLaTeX with the option -shell-escape. I usually run pdfLaTeX from AUCTeX with the option ...
7
votes
1answer
192 views

AUCTeX changes name of pdf file when compiling with LuaTeX

I'm using AUCTeX with emacs 24.1 on Ubuntu 11.10. I have the TeX Command set to compile using LuaTeX and to produce pdfs. Everything works except that the name of the pdf changes from the file name ...
7
votes
1answer
519 views

Delete comments in tex file with Emacs+Auctex

I am working with other people LaTeX files and sometimes they look very messed up. I am looking for a way to delete all comments without changing the code. The problem is that I want to preserve all ...
7
votes
3answers
795 views

emacs auctex: how to get \frac{}{} and \bm{}?

How can I find out (in AUCTeX) if \frac{}{} and \bm{} have predefined keyboard shortcuts? I couldn't find these two.
7
votes
3answers
117 views

emacs+auctex: prevent region filling when inserting itemize

When inserting an itemize environment around some text (using C-c C-e) AucTeX insists on doing paragraph-filling on said text, which messes up my layout. Is there a simple way to prevent that ? ...
7
votes
1answer
639 views

How can I tell AUCTeX that breqn is a math environment?

I have recently been trying to use the breqn package to automatically break up my equations. However, I use emacs (and/or Aquamacs, depending on the machine I'm on) with Auctex, and it does not ...
7
votes
2answers
2k views

Mavericks upgrade screwed up my pdflatex (command not found)

so everything was working fine ... until i upgraded to os x mavericks (version 10.9.2) a couple days ago. using emacs version 24.3 (9.0) auctex version 11.87.3 after upgrade, tried to compile and ...
7
votes
1answer
240 views

How to configure Emacs and AUCTeX to perform Forward and Inverse Search

I have emacs23 and AucTeX installed on my Ubuntu system. I would like to change the default pdf viewer in emacs and enable forward and inverse search. How do I do it? I would like to share my ...
7
votes
2answers
2k views

Setting up forward search between Emacs+AUCTeX and Evince

Did anyone succeed setting up forward search between Emacs+AUCTeX and evince? In order to establish inverse/forward search between Emacs+AUCTeX and evince, it is necessary to: install new TeX Live ...
6
votes
5answers
797 views

emacs/aquamacs + latex/auctex: how to define one's own environments or commands?

I work with Aquamacs (emacs on Mac OS X; latest version) to compile .tex documents. Although AUCTeX provides environments such as enumerate etc., I would like to define a shortcut/macro to get my own ...
6
votes
1answer
472 views

Defining a new key combination in emacs to run Latex

I want to define a new key combination in my .emacs such that it will directly run the latex command, unlike C-c C-c Ret which gives me different options every time (like view). I am using xdvik for ...
6
votes
3answers
1k views

Formatting Bibtex entries using auctex

In general auctex makes a good job of formating latex. However, the formating for Bibtex doesn't seem that great. For example, I would tend to format my bibtex entries in this way: @article{Smith, ...