Questions tagged [tex-core]

{tex-core} is for questions for syntax, semantics and expected behavior of TeX primitive control sequences, regardless of extensions (eTeX, etc.) formats (Plain or LaTeX) and macro packages (tikz). 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}.

Filter by
Sorted by
Tagged with
23
votes
7answers
4k views

What is the canonical way to write a for-loop macro?

At a basic level TeX does not provide a for-loop construct, but allows tail-end recursion, however Knuth defined \loop in the plain macros. Coders have been coming with variations of their own ever ...
6
votes
1answer
1k views

How to use \futurelet to define optional parameters

I am trying to create a simple macro using TeX with optional parameters: \elide[options]{} I understand a common way is to use \futurelet. So far the code is as follows: \documentclass[11pt]{...
7
votes
2answers
3k views

How to display filenames with underscores.

The following latex code uses fancyvrb VerbatimOut and VerbatimInput environment to write out and display code. The idea is to maintain only a latex file which contains code and documentation and ...
5
votes
2answers
775 views

Why do TeX list items use two backslashes?

In TeX packages one finds definitions of lists as: \def\l{\\\alpha\\\beta\\\gamma} The one backslash is understandable, it represent the active character for the macro i.e, \gamma, but what do the ...
15
votes
2answers
305 views

Difference between one glue and two glues after each other

Is there a difference between A\hskip 1pt \hskip 0pt plus 1fil B and A\hskip 1pt plus 1fil B ? Are these two glues the same in terms of spacing and (line-)breaking? Or do they just add up, as I ...
5
votes
2answers
389 views

How do I create a pdf file from old tex code?

How can I convert the old tex file below into a pdf? I would very much like to know as I have a few other files that I would like to convert. Thanks. PS: I selected the shortest example I had to hand....

1
30 31 32 33
34