{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)

4
votes
0answers
33 views

Release space in the string pool

I managed to get a capacity exceeded message by adding a bit too many named coordinates to a number of tikzpictures and so started to test and now wonder if it is possible to release unneeded space in ...
1
vote
0answers
17 views

Issues with inserting bibliography from Mendeley

I am new to LaTeX. I cannot import a saved bibliography from Mendeley to my LaTeX file. My current code reads this in the preamble:- \documentclass[12pt,a4paper]{report} \usepackage{natbib} \...
11
votes
3answers
294 views

Why does \boxN clear the box?

I understand that w.l.o.g. \box0 puts the content of box 0 and clears the content of box 0, while \copy0 puts the content of box 0 and does not change the content of box 0 at all. Whenever I do \...
2
votes
1answer
63 views

Circuitikz Inverter Open Collector Symbol

I'm looking for the symbol of the Open Collector Inverter in Circuitikz, but I can't find it. Anyone knows how to do it?
16
votes
3answers
560 views

The "^'' glyph in the TeXBook

TeX, plain TeX, within the source of the Texbook of Don Knuth, there is use of ^ in different command sequences, and in text bites. Is there a special meaning to ^ in TeX primitives, in plain TeX, ...
7
votes
1answer
76 views

Macro overloading, catcode redefining… or how can I parse XML with TeX?

Given this code that barely parse XML and print it as SXML (s-exp XML, aka lisp-style XML, aka XML-with-parenthesis): \catcode`@=11 \let\@xp\expandafter \def\@makeletter#1#2\@nil{\catcode`#1 \ifx\...
24
votes
2answers
1k views

Why can't caret and tilde be escaped with backslash alone?

I can escape some special characters with a backslash. \documentclass{article} \begin{document} \# \$ \% \& \_ \{ \} \end{document} But why can't I escape ^ and ~ with a backslash alone? For ...
2
votes
1answer
30 views

Forcing $ unescaped to error, not use math-mode

I am copying and pasting paragraphs into a LaTeX document from a report that contains frequent $ signs. I would like any unescaped $ to result in an error and perhaps a reminder to escape them. (Math ...
13
votes
3answers
226 views

Accessing TeX token or exporting filtered plain text

(updated according to gained information) In the context of keyword extraction from arbitrary (La)TeX documents and simple manipulations with them (automated annotation), I would like to be able to ...
3
votes
1answer
30 views

Use temporary length \dimen255, temporary count \count255

This Question is mainly important for package writing: I read in the TeX-Book that \count255 and \dimen255 are traditionally used for temporary. Now the number of registers has risen (see this ...
2
votes
0answers
88 views

Can I Use LaTeX to Convert UK to US Spellings? [closed]

I have written a paper using LaTeX. My supervisor wishes to use US English for our paper to submit to an American journal. However, I'm based in New Zealand and have written the entire paper in LaTeX ...
7
votes
1answer
130 views

What are the limited resources in LaTeX/TeX?

I heard, that some resources (or maybe all) are limited. The number of lengths seems to be limited to 2^8 (1 byte). Are there any other limited resources and if yes, which are these or where can this ...
0
votes
0answers
8 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} \usepackage{enumerate,enumitem,textcomp,...
4
votes
2answers
139 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
15 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
386 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 ...
14
votes
2answers
169 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
52 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. ...
5
votes
1answer
259 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 ...
6
votes
2answers
98 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. \documentclass[fontsize=13pt,letterpaper,]{...
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 ...
5
votes
2answers
242 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
81 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
30 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
48 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 ...
1
vote
0answers
52 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 ...
19
votes
0answers
172 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} \typeout{\meaning\...
5
votes
0answers
65 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 ...
20
votes
3answers
229 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 ...
16
votes
1answer
619 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}
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 ...
5
votes
0answers
67 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} \usepackage{...
9
votes
2answers
266 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
68 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
102 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
36 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} \usepackage[margin=1in]{...
11
votes
2answers
184 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 (5....
9
votes
1answer
188 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
62 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
130 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} \usepackage{xstring}...
0
votes
0answers
8 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 ...
17
votes
3answers
956 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
43 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
69 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
46 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
47 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 ...
22
votes
1answer
290 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 ...
0
votes
0answers
55 views

What language is TeXLive written in? [duplicate]

I read that TeX was written in SAIL and re-writen in Pascal. Do we still use that version today? In my Linux distribution, I use TeX-Live. Does that also use the Pascal version? Wikipedia says the ...
2
votes
1answer
133 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 ...