Questions tagged [latex]

Working with LaTeX documents, LaTeX coding, and LaTeX source blocks in other documents.

LaTeX is a document preparation system that uses macros with the TeX engine for producing scientific or technical books and articles of typeset quality.

Use tag for general questions about working with LaTeX documents in Emacs. Other tags may also be applicable depending on the question and specific feature or mode of Emacs. For example, there are many modes for working with LaTeX documents, three of the common ones are:

  • The basic tex-mode package included in GNU Emacs. Use the tag for questions pertaining to this mode.
  • The complete AUCTeX third-party package (included in XEmacs). AUCTeX provides advanced features, including syntax highlighting, completion macros in third-party packages, better support for complex compilations, preview of math equations. Use the tag for questions about AUCTeX.
  • For questions about LaTeX in org-mode, use the appropriate org tag as well. For example, for LaTeX exports, use .

For questions about (La)TeX and companion tools unrelated to Emacs, consult TeX - LaTeX Stack Exchange as well.

870 questions
10
votes
1 answer

Can emacs close open LaTeX tags automatically?

When using web-mode, typing a , . Is it possible to get the same thing in LaTeX? For example, if I have a \begin{foo}…
terdon
  • 745
  • 6
  • 21
9
votes
2 answers

Deactivate subscripts and superscripts raising / lowering in latex mode

On a new install, I noticed that Emacs systematically lowers or raises what it identifies as subscripts or superscripts (sometimes correctly, sometimes incorrectly...) due to the presence of _ or ^ in latex-mode. Syntax highlighting is enough for…
Xavier
  • 91
  • 3
6
votes
2 answers

Don't complain about unmatching parenthesis and brackets in latex math mode

In mathematical notation, parenthesis and brackets have overloaded meaning, and when it comes to represent intervals, the parenthesis/brackets don't have to match. For example, (1, 2] means an interval with left open and right closed. But…
Jason Hu
  • 201
  • 1
  • 8
5
votes
1 answer

In latex-mode is it possible to disable auto-fill-mode in between `\begin{figure}, \end{figure}`

I am working on tex files with LaTeX-mode. If possible, I want to use auto-fill-mode in some conditions. I was wondering is it possible to disable it in between some patterns like: \begin{figure}[ht] … \end{figure} where I want to apply…
alper
  • 1,370
  • 1
  • 13
  • 35
5
votes
1 answer

LaTeX closing $ signs makes cursor jump

I'm in LaTeX/PS mode and whenever I close my $ math statements the cursor jumps to the first $ and back to the closing $. How can I disable this?
user1766555
  • 163
  • 4
4
votes
1 answer

How to find the matching environment command in tex mode?

A latex environment looks like this: \begin{envName} body \end{envName} Is there a command to jump back-and-forth between matching \begin and \end commands? (One cannot simply use a regex search because environments can be nested)
jyp
  • 128
  • 7
3
votes
1 answer

How to automatically accept: Please answer y or n. Process `LaTeX' for document `program' running, kill it? (y or n)

When I save a LaTeX file, I want to compile it as well on the background. In order to achieve it I have done following module: (defun my-run-latex () (interactive) (save-all) (setq TeX-command-force "LaTeX") (setq TeX-clean-confirm t) …
alper
  • 1,370
  • 1
  • 13
  • 35
3
votes
0 answers

Edit ShareLaTeX document using Emacs

I was searching whether is is possible to edit a document from ShareLaTeX using Emacs in real time. Up to now I haven't find anything to do the job. So my question is if there is a good and reliable way to do that.
Adam
  • 2,447
  • 2
  • 22
  • 40
2
votes
1 answer

Ways to open the compiled pdf file of the current tex file

I would like to define a customized function to open the complied pdf file of the current tex file in the default pdf viewer of the system (say SumatraPDF.exe). I am primarily interested to a solution without AUCTeX/LateX mode facilities, though…
Name
  • 7,849
  • 4
  • 41
  • 87
2
votes
1 answer

How can I navigate through errors after compilation in `latex-mode`?

What I mean by debugging is the ability to navigate through errors after compilation. I read that this can be done in AUCTeX with the command C-c [backtick]. I was wondering if there was a similar command in the major latex mode from latex-mode.el.
Antoine
  • 205
  • 2
  • 6
2
votes
1 answer

"TeX-insert-quote" does not work anymore

Emacs "suddenly" stopped automatically inserting the correct quotes once I hit the " key. It seems to me that this is due to a duplicate installation of some package, but I can't put my finger on it. There are some commands that seem to duplicates,…
Marcus Riemer
  • 539
  • 6
  • 16
2
votes
1 answer

Latex failing with Cygwin

I'm on Windows 7, running GNU Emacs 24.4.1, and I have also installed Cygwin and I am trying to use Cygwin as the shell in Emacs. I followed the answer…
bkmoney
  • 323
  • 3
  • 10
2
votes
1 answer

Rich Text Format for LaTeX in Emacs

I have seen that the online LaTeX editor Overleaf has a nice Rich Text format so instead of this: you see this: You can also see it for yourselves without any login required if you go in the website and press "Create New Paper". How can I add this…
Adam
  • 2,447
  • 2
  • 22
  • 40
1
vote
2 answers

Using pdflatex with other languages than English

I am using latex to compose a letter. It works well in English, but how can I handle other languages (Spanish, French). Emacs actually prints the foreign characters, but when I run pdflatexon the file, pdflatex complains on some of the characters.
Dilna
  • 1
  • 3
  • 11
1
vote
1 answer

bug in the CTAN version of aux-renum.el

Emacs has been my LaTex editor for several years. Along with AucTex, I have been using the label/ref management utility for emacs supplied by aux-renum.el. It's available on the CTAN archive at aux-renum.el However, when I fired it the other day I…
1
2