Questions tagged [tex]

TeX is a typesetting system, where the output is defined by command-sequences. Note that https://tex.stackexchange.com is specifically dedicated to TeX questions.

TeX is a typesetting system, where the output is defined by command sequences. It was designed and mostly written by Donald Knuth. TeX was designed with two main goals in mind: to allow anyone to produce high-quality books using minimal effort, and to provide a system that would give exactly the same results on all computers, at any point in time.

There is a Stack Exchange site dedicated to TeX, which is a good place to ask any TeX-related questions.

Resources:

872 questions
15
votes
2 answers

Add in the LaTeX TOC an included PDF

In my document I include a PDF using \includepdf[pages=-]{./mypdf.pdf} The problem I'm having is how to add a TOC entry for this pdf. It supposed to be an appendix. I tried adding a new section in the appendix but of course the section name can't…
Heyyou'reQt
  • 153
  • 1
  • 1
  • 5
15
votes
6 answers

Why does Tex/Latex not speed up in subsequent runs?

I really wonder, why even recent systems of Tex/Latex do not use any caching to speed up later runs. Every time that I fix a single comma*, calling Latex costs me about the same amount of time, because it needs to load and convert every single…
Debilski
  • 66,976
  • 12
  • 110
  • 133
15
votes
3 answers

Do you use XeTeX or pdfTeX?

As far as I understand it (a few days of research here and there), there are two major TeX engines: pdfTeX and XeTeX. pdfTeX is the "standard", having been around since the early 1990s, renders straight to PDF, and improves on some minor formatting…
jparker
  • 1,569
  • 2
  • 16
  • 16
14
votes
3 answers

Rendering LaTeX to an image

I have read lots of questions and answers here but I haven't found a clear Question/Answer. I need to create a really simple webpage which allows users to enter LaTeX and generate a PNG (or other lightweight image format). The webpage contains only…
Daniel
  • 1,321
  • 12
  • 25
14
votes
2 answers

Redefining commands in a new environment

Two questions: Does LaTeX allow one to (re)define commands within a \newenvironment? I've tried using \renewcommand, \newcommand and \def in the before declaration but to no avail. How would one redefine \item when creating a new list…
gvkv
  • 1,894
  • 2
  • 22
  • 34
14
votes
4 answers

LaTeX Error with Sphinx: file `titlesec.sty' not found

While trying to generate the PDF documentation of a Sphinx project, I get this: ! LaTeX Error: File `titlesec.sty' not found. Type X to quit or to proceed, or enter new name. (Default extension: sty) Enter file name: I have installed the…
yucer
  • 4,431
  • 3
  • 34
  • 42
14
votes
1 answer

Use Agda's input method in other emacs mode?

How do I use Agda's input method to enter unicode characters in non-Agda mode? I don't see its name showing up when I try set-input-method. The reason I want to use Agda's input method instead of TeX is because there are characters I want that can't…
Alex
  • 1,184
  • 7
  • 15
14
votes
4 answers

LaTeX math mode and mbox mode

According to a doc I found around An \mbox within math mode does not use the current math font; rather it uses the typeface of the surrounding running text. In math mode, I would like to write something like a_{\mbox{foo}}. If I use this,…
Stefano Borini
  • 138,652
  • 96
  • 297
  • 431
13
votes
1 answer

How can you modify two matching delimiters at once with Emacs?

While this question concerns the formatting of LaTeX within Emacs (and maybe Auctex), I believe this can be applied to more general situations in Emacs concerning delimiters like parentheses, brackets, and braces. I am looking to be able to do the…
qgp07
  • 305
  • 1
  • 5
13
votes
1 answer

TeX in matplotlib on Mac OS X and TeX Live

I have the following Hello World code to try out TeX rendering with matplotlib on my Mac. import matplotlib.pyplot as plt from matplotlib import rc rc('text', usetex=True) rc('font', family='serif') plt.text(2,2,r"Hello World!") plt.show() With…
Kit
  • 30,365
  • 39
  • 105
  • 149
13
votes
2 answers

How to create automatic a list of items used in a LaTeX-document?

I want to add items in a LaTeX-document. Say for example, that I want add hints to the document. I create a command, so I can call something similar to this: \hint{foocareful}{Be careful with foo!}{foo is a very precious item and can easily be…
Mnementh
  • 50,487
  • 48
  • 148
  • 202
13
votes
6 answers

How to underline section-headings in LaTeX?

EDIT: As I see in the first answer, underline is the wrong word. I want a line under the section heading, separating the heading from the following text. I want to separate section headings from the following text with a horizontal line. At the…
Mnementh
  • 50,487
  • 48
  • 148
  • 202
12
votes
3 answers

Overleaf: is it possible to select, delete, or move multiple files at the same time?

I haven't found a way to select multiple files at the same time on overleaf, which makes deleting or moving many files very time consuming. Is there something I'm missing?
capybaralet
  • 1,757
  • 3
  • 21
  • 31
12
votes
8 answers

I get 'Error: '\U' used without hex digits in character string starting ""C:\U"' when starting R

I have the following problem when starting RStudio and when I try to compile a PDF from a .rnw format: Error: '\U' used without hex digits in character string starting ""C:\U" When starting RStudio or just R, this is what is inside my console: R…
antwalth
  • 331
  • 1
  • 2
  • 8
11
votes
1 answer

C source in .W file

I found a C source in these files with .w extensions. It seems like a mix of TeX code and C Programming Language. This is an example of these sources. How can I compile? PS: Excuse me for the silly question but I didn't found any documentation
mghis
  • 517
  • 1
  • 5
  • 14