{tex-core} is for questions that are independent of formats and macro packages. Such questions usually relate to low-level TeX programming or the behaviour of TeX at an underlying level. Note that even Plain TeX is a format in itself; for questions about it, use {plain-tex}.

learn more… | top users | synonyms (1)

0
votes
0answers
7 views

pdfTeX warning (ext4): destination with the same identifier (name{choice.1}) has been already used, duplicate ignored [duplicate]

when compiling the following document: \documentclass[11pt]{exam} \usepackage{amsmath,amsbsy,amssymb,amsthm,cases,blkarray,mathrsfs,amsrefs,amsfonts,latexsym} ...
4
votes
2answers
132 views

\iftrue in \let “swallowing” the following \fi

I already searched for comparable questions, but found none with this problem. I have the following LaTeX formatting section to define inline and multiline comments that can be "in-commented" at one ...
0
votes
0answers
14 views

How to draw lines in matrix? [duplicate]

Can you help me to draw a some lines in matrix? I attached it in image : Thank you!
7
votes
6answers
375 views

Explode arguments in argument list

What does TeX do, when reading an argument? I wanted to write a command that has a comma separated list of arguments (\fun[a@b,c@d,e@f,g,]). Each argument should be exploded in two parts at the ...
46
votes
1answer
1k views

What are the incompatibilities of pdftex, xetex and luatex?

[Please correct me if my statements are wrong] TL;DR: pdftex, xetex and luatex exhibit different behaviour. What are these differences and why are they present. I know of three engines, which ...
14
votes
2answers
154 views

Unicode math at TeX primitive level

I am looking for information how to implement Math OTF font in XeTeX or LuaTeX at TeX primitive level (using XeTeX or LuaTeX primitives). There exist a LaTeX package unicode-math. Unfortunatelly, this ...
9
votes
2answers
51 views

Does \end command issue a \vfill

Does \end command issue a \vfill command? I notice that in plain TeX, you have a \bye that issues it but after some experimentation I think \end also issues a \vfill, which is rather confusing. ...
3
votes
5answers
27k views

Error Latex TeX capacity exceeded, sorry [input stack size=5000]

I want to test this template http://students.engr.scu.edu/~sschaeck/latexforthesis/. when i run the makefile i get this error .Please what does it mean this error here the code : ...
71
votes
2answers
5k views

The differences between TeX engines

I am confused about what TeX and its offspring (LaTeX, pdfTeX/pdfLaTeX, e-TeX, ConTeXt, LuaTeX, etc.) are. Some, like LaTeX, seem like add ons to TeX (maybe a change to the eyes and mouth, but not ...
5
votes
1answer
255 views

How does including graphics in TeX work?

How does I include an image (e.g. an eps) in plain TeX without using a package that does so for me? All other questions (like this one) don't actually answer the question how you include an image in ...
124
votes
3answers
24k views

What is the difference between \let and \def?

What is the difference between the \let and \def commands in TeX/LaTeX? Ideally please provide a simple example that will illustrate the difference between them.
6
votes
2answers
83 views

Can two \vtop boxes exist side by side?

So I am trying to see if I can put two \vtop boxes side by side. The below is the closest I have gotten. This is a kind of a "plain-tex in latex" example. ...
7
votes
2answers
77 views

How does TeX break paragraphs into lines when there is only two element in a pararaph?

Suppose we have the following code: \def\tp#1#2{#1\hskip 300cm minus 300cm\hbox{#2}} \tp{Hello}{World it is} and \def\tp#1#2{#1\hskip 300cm \hbox{#2}} \tp{Hello}{World it is} The first one gives ...
2
votes
1answer
120 views

How declare a new package language

I need writing normal text and some sentences in artifical conscript language. How writing small as possible package and how use it (include?) in file? My language have my own font and each glyphs is ...
5
votes
2answers
235 views

When does TeX choose to stretch the glue?

Suppose I type \hbox to \hsize{abc} \hbox{abc} \bye Now, since the first \hbox is set at \hsize, I am expecting the abc to be glued with maximum stretched glue. In the second \hbox, I expect abc ...
6
votes
1answer
70 views

The difference between `\the\numexpr` and `\number\numexpr`

I wonder if there is any functional difference between \the\numexpr and \number\numexpr. Some obscure context where they would yield different results? (I'm obviously aware that \the and \number ...
4
votes
1answer
29 views

How to use control symbols using \expandafter?

Suppose I want to typset P\' olya correctly in TeX but suppose my computer does not have the key invoking the character/symbol ' (This is of purely theoretical interest). Now, TeX lets you use \rq to ...
3
votes
2answers
42 views

How do I perform an expandable string comparison?

I need to perform a string comparison (string equality). If the macro is non-expandable (e.g. contains \def or \let), it causes problems in the place where it is used. I tried using \ifthenelse from ...
79
votes
4answers
36k views

How to expand TeX's “main memory size”? (pgfplots memory overload)

I'm compiling one pretty simple LaTeX file with few dozen of pgfplots. Now, I can compile part by part, but am unable to compile it all at once. I really need good precision for all those plots (noise ...
1
vote
0answers
48 views

How to define LaTeX like environment in plain TeX?

How do I define LaTeX like environment using TeX primitives? I have just started learning TeX using Knuth's TeX book and found it hard to implement the LaTeX like environment using TeX primitives. An ...
17
votes
0answers
143 views

Is there a reliable way to get the number of arguments of a command?

While pondering over a test to distinguish two versions of a command I came up with the following example: \documentclass{article} \begin{document} \def\testA#1{\#2->blabla} ...
5
votes
0answers
58 views

LuaTeX tex->dvi conversion code

I'm researching ways to teach computers to generate LaTeX code from Page Description Languages (PDL) like PostScript and PDF, using Machine Translation. For this to work, it would be majorly useful ...
19
votes
2answers
7k views

\llap (or \rlap) at the beginning of an indented paragraph

If I use a \llap{text} command at the beginning of an indented paragraph, the text is not indented and is put on the line above the paragraph. \documentclass{article} \begin{document} \parindent=2cm ...
15
votes
1answer
595 views

What is the programming term for the command invoking '\' in latex?

I don't think it would be called a delimiter. Is there a specific term for this character? Just to clarify, I'm talking the slash here: \frac{1}{2}
20
votes
3answers
221 views

Why is a discardable item not discardable?

I have the following code \output={\plainoutput \message{outputpenalty=\the\outputpenalty}} % for debugging \hrule \vskip21.9cm plus1pt % plus1pt because to avoid underfull vbox until output one ...
7
votes
2answers
1k views

Why is the \bye command not used by LaTeX?

Is there a technical reason why the \bye TeX command was replaced in LaTeX by \begin{document} and \end{document}? I suspect there must be a good technical reason behind this, as otherwise it would ...
9
votes
5answers
9k views

Writing Roman numbers in Equation

What is the command for writing roman numerals like I, II, IV etc. in an equation ? To be noted that my requirement is to write them within $$ ...$$ and not as counters or page numbers. Any light on ...
0
votes
0answers
7 views

Compiling a latex file .tex to a PDF File [closed]

I've downloaded a file from this link But i don't know anything about .tex extensions, i've googled it, it turned out to be a latex file. So I've downloaded & installed MacTex, but it doesn't ...
55
votes
5answers
3k views

What are TeX and LaTeX?

I'm surprised no one else has asked this question. It's not explained very well in the FAQ or site descriptions either. I know many of you will think "LMGTFY", "RTFM", or "ask wikipedia", but I'd ...
5
votes
0answers
63 views

How to tell LaTeX to throw a warning if argument is not being used?

In this question the given argument wasn't used, because #1 was missing.. One would actually assume an error or a warning be thrown. A little MWE based on 1: \documentclass{article} ...
9
votes
2answers
254 views

What is the maximum nesting depth of \input?

Large documents are best split into various files. Using \input allows to nest multiple files. What is the technical limit of \input regarding the nesting depth? I haven't found any clue searching ...
4
votes
1answer
65 views

Question about \maketoks macros from cwebmac.tex

Consider the following code from cwebmac.tex: {\setbox0=\hbox{\toksA={1.}\toksB={}\maketoks}\the\toksA} What does \maketoks macros do and how does it work? The following is a complete example ...
0
votes
0answers
81 views

TeX capacity exceeded, sorry [input stack size=5000] in LyX Classicthesis

I use classicthesis-LyX-v4.2_biblatex_bibtex8 I got this error message when I load hanging module into the parent document (probably my personal issue, as I tried it on the newly downloaded template, ...
2
votes
3answers
34 views

Retaining count values between blocks

How can one make a count retain values between different blocks e.g in nested loops? For example \newcommand\example {% \newcount\N \loop {\loop \the\N\quad \ifnum\N<5 ...
1
vote
0answers
29 views

Get the current state of all macroes

I was wondering if there was a way to save the current configuration state at some point in the document. For example, if I have the file A.tex \documentclass[10pt]{article} ...
7
votes
3answers
5k views

Resize all images in Latex to a percentage width

I am auto-generating multiple tex files using pandoc (one tex file for each of my chapters). Pandoc generates this tex code for each image. \begin{figure}[htbp] \centering ...
11
votes
2answers
181 views

How to typeset in initex?

Just curious how to typeset letter 'a' in initex without 'overfull' warnings. $ tex -ini '\font\f=cmr10\f a\end' This is TeX, Version 3.14159265 (TeX Live 2015/Debian) (INITEX) Overfull \hbox ...
17
votes
5answers
667 views

Basics of parsing

I'm trying to master the art of parsing text one character at a time. The following is what I've discovered so far. Is this as good as it gets? I would really prefer not to do all those \edefs as ...
9
votes
1answer
185 views

How does \delimiter work? How does it convert its argument into character(s?) and why?

studying the definition of \lvert (which just made me finally understand what does mean \@xp\@gobble and how it works \o/), I found the \delimiter command, with a numeric argument advanced by ...
3
votes
1answer
56 views

xdef and cedille

I need to xdef some data. In rare cases it'll contain cedilles like: \xdef\xxx{spam\c{e}eggs} \bye Unfortunately this failes. Is there a chance to get this working? (I'm on LaTeX in my code, using ...
7
votes
2answers
129 views

Expansion of \char in \def

In answering another question, I ran into some issues trying to use a combination of \def and \char. Consider the following example: \documentclass{minimal} \usepackage{etoolbox} ...
16
votes
3answers
952 views

Why is SVG not supported by the TeX backend?

I've always wondered why SVG is such a problem for many document creation tools. For example MS Office can't do it, Libre Office can only use very simple SVGs afaik and even in Latex we can't use them ...
3
votes
1answer
38 views

Underline (or otherwise format) all text in custom environment

I'm trying to define a custom environment, in which all text is underlined. I know the underline command underlines its input, but I can't figure out how to get it to work seamlessly with my ...
1
vote
0answers
67 views

Tips for using TEX / LaTeX for writing meeting protocols

I found TEX / LaTeX just over a week ago and I am very pleased with it. I used to hate writing documents on the computer because it felt so inefficient and messy with the word processors. TEX was ...
0
votes
1answer
43 views

Externalize pdf_tex like externalize tikz

I am using the workflow explained in this tutorial for typesetting images in my document: Tutorial for pdf_tex using inkscape Briefly, a vector image is imported into inkscape and then image itself is ...
2
votes
0answers
43 views

Macro with \afterassignment syntax?

Say for some reason I want to make a macro with input stream behaviour mimicking that of \afterassignment and \aftergroup. Namely, I want to absorb exactly one token from the input stream following ...
8
votes
7answers
245 views

unescaped macros

Is there a way to define a macro that does not start with \? for example, I'd like to have -> expand to \rightarrow since I like reading raw LaTeX and $\eps -> 0$ reads much nicer (to me...) ...
22
votes
1answer
281 views

Summary of TeX Capacity Limits

I seem to often run into capacity issues and have been upping the limits each time. There are several question on this site pertaining to these. However, there seems to be some conflicting information ...
56
votes
4answers
3k views

What is “expansion”?

I'm relatively new to (La)TeX, but I have a reasonable amount of experience with computational programming languages. Until I began learning (La)TeX, I'd never heard of "expansion"... So, what is ...
37
votes
2answers
3k views

What language is TeX implemented in?

I read on Wikipedia that the first version of TeX was written in SAIL. However, does anyone know what language later versions (i.e the current one) are implemented in?