Questions tagged [latex]

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

Filter by
Sorted by
Tagged with
2
votes
1answer
66 views

AUCTeX: only use monospace for rendering macros?

I've been using the fontify features of AUCTeX, as well as magic-latex-buffer, to display my TeX code in a more readable way. But I'm wondering if I can crank this up to 11: is there a way to render ...
0
votes
1answer
53 views

How to open a PDF after running tex-file?

I am able to run pdflatex via tex-file, and the PDF generates just fine. How would I go about automatically opening the resultant PDF file after generation?
0
votes
0answers
12 views

Syncing tex source with some environments (example mdframed)

I realize this is quite an edge case, but I am wondering if anyone can help me. I have source correlation set up in emacs as follows (setq TeX-source-correlate-start-server t TeX-source-...
0
votes
0answers
36 views

How to replace a LaTex macro with its argument?

I want to replace a macro with its argument, that's to say, if I have \newcommand{\foo}{FOO} I want to replace every occurence of \foo with its argument FOO in a specified region. I am trying to ...
0
votes
0answers
12 views

AUCTeX: inconsistent behaviour when compling (probably becuase of what I'm doing)

I cannot get AUCTeX to preview updates to multifile documents. I have the following config: (use-package tex :ensure auctex :config (setq-default TeX-master nil) (setq TeX-source-...
9
votes
5answers
3k views

org-mode ignore heading when exporting to latex

I have a problem where I want to structure my document visually with a heading but do not want it to actually execute a \section{Fake Heading} for the latex export. I imagine this would be ...
1
vote
2answers
175 views

Definitive answer to org-mode export HTML versus LaTeX

I keep being stymied by the apparent incompatibility of HTML and LaTeX export. Here's what I have in my .org file header: #+LATEX_CLASS: article #+LATEX_CLASS_OPTIONS: [american] #+LATEX_HEADER: \...
11
votes
3answers
1k views

Any science book written in org-mode?

I am thinking to write a physics book in org-mode. Although there are many open-source science books written in LaTeX to figure out its work-flow (and its source) I couldn't find any science book ...
1
vote
1answer
82 views

AUCTeX does not compile if the local variable is already set

I'm basically want to ask the question that was asked in Tex Stackexchange but was considered off-topic there (this is the link to the question). When I am trying to compile (using the command C-c C-...
12
votes
3answers
1k views

How to enlarge latex fragments in org mode at the same time as the buffer text?

I'm using org-mode in emacs, but I think the question is also relevant for auctex users. In org-mode you can show latex fragments, as the manual demonstrates. But: these fragments (mostly math ...
3
votes
1answer
1k views

Org mode subtitle not being exported to pdf

#+TITLE: My title #+SUBTITLE: My subtitle * Blah blah blah My subtitle isn't being exported, anyone know why? LaTeX export: https://pastebin.com/Wg2gVS12
1
vote
2answers
106 views

View command does not open pdf while in AUCTeX mode

Sometimes, after havin applied latex to my .tex file, instead of executing okular --unique my.pdf emacs tried to execute okular --unique my.pdf#src:332#("/folderToMyTex/my.tex" 0 61 (org-attr nil)) ...
1
vote
1answer
25 views

Org-mode verbatim tilde (=~=) is still processed by Latex back-end

I have some verbatim text containing a tilde, =some ~ text=. Now, org-mode is supposed to leave the tilde alone. However, upon exporting with the latex backend, I get the following in my .tex: \texttt{...
0
votes
0answers
35 views

How to properly render markdown latex in emacs cli using markdown-mode and pandoc?

I have been facing lately the following problem. I have installed markdown-mode and I've been using pandoc behind the scenes to communicate with markdown-mode and do the rendering. I've been trying ...
1
vote
1answer
77 views

Non-hex digit used for Unicode escape error when setting org-latex-classes

When I try to set org-latex-classes with the following code: (setq org-latex-classes '(("article" " \\documentclass[12pt,a4paper]{article} \usepackage{xeCJK} %\usepackage[heading]{...
4
votes
1answer
117 views

how to include remote images in org-mode export to LaTeX?

When I paste the URL of an image into an org-mode file and then export it to HTML, the remote image URL gets turned into an img tag and displayed in my HTML file without the need for me to save the ...
3
votes
2answers
65 views

What are the main differences between latexmk and C-c C-a from Auctex?

I was wondering if anyone knows if C-c C-a in AucTeX is using behind the scenes latexmk or not? I've tried looking into the source files for both C-c C-c and C-c C-a but I couldn't find in any those ...
0
votes
0answers
28 views

Emacs(AUCtex) can't recognize \input{~/Documents}

I have three MacOSs, and set different names for User and Home Folder. I take Emacs as my default editor in those devices. Using Emacs to edit tex-document, I found the code \input{~/Documents} and \...
1
vote
1answer
37 views

Change buffer background color on LaTeX compile error, or highlight errors more prominently?

I am using Emacs+Auctex to write LaTeX code. When compiling a document that contains an error, Emacs writes LaTeX errors in ‘*~/doc output*’. Use C-c ` to display. to the Messages buffer (and ...
0
votes
1answer
39 views

Exporting LaTeX commands to HTML/MathJax

I am writing a document that is specifying a language with associated grammar and semantics. For this I have written the specification in Latex, using a method very similar to the one presented here. ...
0
votes
0answers
13 views

Having tinybookmarks-insert using %%% in LaTeX mode buffers

I am using the package tinybookmarks.el from project emacs-tiny-tools. It provides nice commands, to insert a separation break line, which can be used as bookmark like this one from one of my Lisp ...
1
vote
1answer
30 views

Em dash before italic in org export

In my document, I have an em dash that needs to be followed by italics. Here's a minimal example: He was surprised—/excuse me/? The LATEX/PDF output includes the slashes and the text is not ...
0
votes
1answer
141 views

flyspell overrides company key bindings

I have the following in my init file. ;; ======= Company mode set up ============ (use-package company :ensure t :defer t :init (add-hook 'after-init-hook 'global-company-mode) :config (use-...
1
vote
3answers
1k views

Making pdf-tools work after successful compiling on mac os x

After installing the required dependencies with homebrew, I was able to compile pdf-tools . But I cannot make it work (I cannot see the pdf on emacs after compiling) I would like to know if somebody ...
0
votes
1answer
366 views

AUCTEX won't create dsc file

I'm using Emacs24 on windows with AUCTEX for Latex. When I try to toggle preview it doesn't show, insteed there is a little "not working" picture on each equation and I get an error Running `...
6
votes
1answer
799 views

How to set PDF export in polymode-mode to use xelatex engine?

Consider the below MWE of .Rmd file containing Arabic text which needs xelatex engine to be rendered by pandoc. As the documentation of the latter says putting this option would make it: --latex-...
0
votes
1answer
100 views

Custom verbatim environments/macros in AucTeX

Here's my MWE: \documentclass{article} \newenvironment{tscode}{}{} \def\tscode|#1|{} \begin{document} \tsinline|efwe| \begin{tscode} efihw$feiw$ \end{tscode} \end{document} % Local Variables: % ...
0
votes
1answer
241 views

My emacs does not use the LaTeX-includegraphics-extensions option in my .emacs file

I tried to customize my .emacs file adding the options to the macro command \includegraphics. I use Emacs 25.3.1 on MacOS. My .emacsfile is as follows: (package-initialize) (custom-set-variables '(...
3
votes
2answers
375 views

Org-mode #+include: — ignore configuration lines from included file

How can I have org #+INCLUDE: ignore configurations from the included files? I'm thinking of cases where I don't want Latex Classes to be messed up. For example, if I have two org files book.org and ...
2
votes
1answer
179 views

Efficient workflow to write a book in Org-mode

I plan to write a short statistics textbook using Org-mode. Even if some textbooks have been written using equivalent systems (e.g., the R package bookdown), I have no examples in mind of books ...
3
votes
1answer
78 views

Change overlaid text of an outline header?

Q: how do I add a new outline header regexp but change the overlaid text? I often write presentations with Beamer in LaTeX. As such, there are a lot of frame (ie, "slide") environments: \begin{...
2
votes
0answers
47 views

Indenting LaTeX code for \if \else \fi statements

This is related to this Emacs.SE question. I use the code from the answer: (setq LaTeX-begin-regexp "\\(?:begin\\|if@\\)\\b") (setq LaTeX-end-regexp "\\(?:end\\|else\\|fi\\)\\b") (defun LaTeX-indent-...
0
votes
2answers
185 views

Emacs/LaTeX displays _char as a subscript in the editor

Emacs seems to be doing some WYSIWYG with _, as if it were in math mode (in the picture, _ is followed by subscript 'o', inside the include statement. It shouldn't. I'm using Emacs/Tex out of the box, ...
0
votes
1answer
83 views

org-mode table/matrix in latex export

I have an issue when exporting a table using *matrix environments. The align string appears in the cell content, whatever it is specified or not #+CAPTION: my matrix #+ATTR_LATEX: :mode displaymath :...
0
votes
1answer
169 views

Creating table of content with the package titletoc in Org Mode for LaTex export produces strange lines of text

I use the LaTeX package titletoc to produce table of contents in some chapters or sections for Org-Mode LaTeX / PDF export with #+TOC: headlines 1 local But in the PDF file there is for example the ...
0
votes
1answer
88 views

opening brace alignment/indentation problem in LaTeX mode

I have an alignment/indentation problem in LaTeX mode. Every time I begin a line with an opening brace and I hit <TAB> or run an indentation command on the region, the brace becomes aligned with ...
2
votes
1answer
236 views

Disable flycheck for LaTeX

I use emacs with AUCTeX for editing tex files. I also use flycheck for some other programming language. How to disable flycheck in TeX mode ? I tried called flycheck-mode nil in the latex hook but ...
1
vote
0answers
68 views

orgmode latex export: alternative to \newpage?

In orgmode, is there a property I can set to a section that will output a pagebreak before it? Right now, I can do the following: * Section 1 ** Subsection 1 stuff ** Subsection 2 stuff \newpage ...
1
vote
2answers
722 views

LaTeX mode: How to select “pdflatex” instead of “latex” for a file automatically?

I have a LaTeX file using lots of PDF figures (mostly because converting figures to EPS is a waste of disk space), so it requires to use pdflatex. I added there lines to the end of my main file: %% ...
3
votes
1answer
423 views

prettify-symbols-mode and multi-character replacements?

With prettify-symbols-mode it is possible to replace strings by a character, or a character composition, e.g. ;; \lambda → λ (push '("\\lambda" . ?λ) prettify-symbols-alist) Optionally, it allows ...
2
votes
2answers
124 views

Emacs Org-mode + Letter class = Unknown latex class 'letter'

I want to use Emacs with org-mode to export notes using 'letter' class. Texlive is installed in a Mac, and have many classes to export. But Emacs in org-mode only work with: article, report and book: ...
1
vote
0answers
50 views

Automatic preview generation with AUCTeX

Right now, when using AUCTeX's preview feature, I have to manually refresh the previews after I change existing sources or write new text. I have to run preview-document every time, which is both ...
0
votes
1answer
32 views

How to turn off Latex/MathJax buffer symbol conversion in org-mode

Whenever I write, say, \Rightarrow inside of $$, I immediately see the actual right-pointing arrow substituted in. Unfortunately, this does not travel well between GUI-based Emacs and Emacs started -...
2
votes
1answer
50 views

AUCTeX fontification for any command: overkill?

Reading the AUCTeX manual I see that it is possible to add expressions to those one wants to highlight in a .tex file. There are also many specific suggestions around for how to add specific commands ...
2
votes
1answer
50 views

Spacemacs pdf-tools inverse search with keyboard possible?

I am running spacemacs and pdf-tools on Ubuntu 18.04. It does work quite well, however now I asked myself whenever there is an option to do inverse search (or to make a new command doing inverse ...
0
votes
0answers
51 views

Semantic linefeeds (one sentence per line) in Emacs

I'm trying to get Emacs to insert a line break at the end of each sentence as I type. (Why? Makes for easier version control of tex files.) Looking around I found a few places with some suggestions ...
1
vote
0answers
55 views

Auctex previews, change foreground color of text

I am using a dark theme and the latex previews from auctex are created with black text color. How can I change it? What I can do is change the background color to white (in Preview Reference Face ...
0
votes
1answer
28 views

Avoid Adding Backslash to Curly Brackets when Exporting Latex

I want to export an org tree to latex, but whenever I have a command that nests curly brackets, org export will automatically prepend all brackets with a backslash. For example, the tree: Exports to ...
8
votes
4answers
1k views

Show math formula in emacs when coding

Is it possible that emacs shows real formulas in the editor if they are written in Latex or similiar? I am asking because it would be much more readable if you are coding (in lets say python or C++) ...
0
votes
0answers
41 views

Org-mode parameters for custom table environment for LaTeX

I am using an overridden table environment based on tabular to get some custom cell coloring based on row alternation (similar to what rowcolors does, but also allowing column color variation at the ...

1 2 3 4 5 11