11

Many symbols of the ASCII character set are assigned some special role in TeX (e.g. &, %, …). And many are also assigned a single-symbol macro (e.g. \%, \,, …). I was wondering whether a list of those non-letter and non-digit ASCII symbols exists, for which a macro exists.

Naturally, I could type them all out in a document, but something tells me that that will turn into more work than expected because it could generate a large number of errors (undefined control sequence). I was also unable to find such a list either here on TeX.SE or elsewhere.

Bonus points for including those symbols from the Latin-1 extension (excluding all diacritic-modified letters).

Because I realise that packages can (and will) define practically everything, there is no need to consider any when putting together this list. If you want to add what a few common packages do with certain symbols, feel free.

0

2 Answers 2

17

enter image description here

\documentclass[a4paper]{article}
\parindent0pt
\begin{document}
\ttfamily

\ifx\^^@\undefined\else
0: \string\^^@=\meaning\^^@\par
\fi
\count0=1
\loop
\ifnum\catcode\count0=11
\else
{\lccode`a=\count0
\lowercase{
\ifcsname a\endcsname
\the\count0:
\expandafter\string\csname a\endcsname=%
\expandafter\meaning\csname a\endcsname\par
\fi}%
}%
\fi
\ifnum\count0<255
\advance\count0 1
\repeat

\end{document}
2
  • 1
    +1 for the generated list. Also it was new to me, that the uppercase Greek letter psi is an ASCII letter at position 9 ;-) Nov 11, 2016 at 17:58
  • @HeikoOberdiek yes all the uppercase greek is squeezed into the control character range in OT1 (Gamma at position 0 used to break some pdf readers:-) Nov 11, 2016 at 18:00
9

Translation of David's list:

  • 9/\^^I (horizontal tabulator): explicit space as \␣
  • 13/\^^M (carriage return): explicit space as \␣
  • 32/\␣ (backslash, space): set an explicit space
  • 33/\!: a negative thin space in math mode
  • 34/\": diaeresis accent in text mode
  • 35/\#: hash sign in text mode
  • 36/\$: dollar in text or math mode
  • 37/\%: percent sign in text mode
  • 38/\&: ampersand in text mode
  • 39/\': acute accent in text mode
  • 40/\(: begin inline math
  • 41/\): end inline math
  • 42/\*: a line break point between factors of a product; if there is a line break, then the previous line ends with a thin space followed by a multiplication sign (×).
  • 44/\,: thin space in math mode
  • 45/\-: explicit hyphenation point with hyphen if hyphenated and without otherwise
  • 46/\.: dot accent in text mode
  • 47/\/: space for italic correction
  • 58/\:: medium space in math mode
  • 59/\;: thick space in math mode
  • 61/\=: macron accent in text mode, or in environment tabbing: set tabulator
  • 62/\>: medium space in math, or in environment tabbing: advance to next tabulator stop
  • 64/\@: sets the space factor to 1000, typical usage is after abbreviation periods following lowercase letters, e.g.: Mr.\@ John Doe
  • 91/\[: begin unnumbered display math
  • 92/\\: line end/new line
  • 93/\]: end unnumbered display math
  • 94/\^: circumflex accent in text mode
  • 95/\_: underscore in math and text mode
  • 96/\`: grave accent in text mode
  • 123/\{: left curly brace in math mode
  • 124/\|: vertical line as delimiter in math mode
  • 125/\}: right curly brace in math mode
  • 126/\~: tilde accent in text mode
0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.