Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [magic-comment]

Comments of the form % !TEX ... that can be used as directives in many tex editors

2
votes
1answer
407 views

Disable spell checking through magic comments

I use TeXstudio 2.11.2, and I want to know if there is a way to disable spell checking through magic comments. Something like this: % !TeX spellcheck = disable
4
votes
0answers
225 views

When and why should I use % !Mode:: “TeX:UTF-8” directive?

I often see the following lines are included at the beginning of the tex files: % !TEX TS-program = xelatex % !TEX encoding = UTF-8 Unicode % !Mode:: "TeX:UTF-8" Directives started with % !TEX are ...
2
votes
1answer
1k views

Texmaker magic comment

Is there any similar magic comment in Texmaker like those in Texstudio? Example:% !TeX program = xelatex
1
vote
1answer
739 views

How to change the color of a magic comment

In TeXStudio you can have magic comments: % !TeX. I want to change their foreground color, but can't find that option in the Syntax Highlighting tab in the configuration options. How can I change ...
22
votes
1answer
12k views

Tell TeXstudio to compile a particular document with LuaLaTeX

It is not hard to change the default compilation engine in TeXstudio from PDFLaTeX to LuaLaTeX (or any other engine for that matter). But if I only want to use LuaLaTeX for a single document, it gets ...
2
votes
0answers
109 views

Documentation of “%! TeX” codes [duplicate]

Possible Duplicate: When and why should I use %!TEX TS-program and %!TEX encoding? I want to create a list of "%! TeX" codes to a documentation file for my template and want it to be as complete, ...
117
votes
4answers
14k views

When and why should I use % !TEX TS-program and % !TEX encoding?

Occasionally, I see other people's documents starting with two lines like that: % !TEX TS-program = xelatex % !TEX encoding = UTF-8 Unicode It's clear to me that the first line declares the engine ...
5
votes
1answer
1k views

Bypass % !TEX TS-program =

Some LaTeX editors (TeXShop and TeXworks, for instance) allow a special comment line to define a default engine to use with a current document, like this : % !TEX TS-program = pdflatex It's really ...