Skip to main content

The PreTeXt Guide

Chapter 11 Basic Formatting

The PreTeXt Principles begin with “PreTeXt is a markup language that captures the structure of textbooks and research papers” (Item By a markup language, we mean that the syntax describes the structure of the document and not the presentation of the document. Thus, PreTeXt does not provide, for instance, a way to make text bold or italic or in a larger font. If an author seeks a specific type of local typesetting, then they need to pause and think about the reason for that typesetting. Is the reason to emphasize a word or phrase? Is the reason to alert the reader to a common mistake? Is it to designate that a word is a new term being defined by the author? There are ways to mark up such structural ideas in PreTeXt, and authors should conscientiously ensure that they use this markup.
To illustrate some of the key structural markup that leads to formatting, we include the listing and paragraph below.
  This is a new <term>piece of terminology</term>.
  Here is a word we have chosen to <em>emphasize</em>.
  <alert>This is an alert to the reader!</alert> This is a piece of
  <c>code typeset in a different font</c>.
Listing 11.0.1. Some basic content of a paragraph
The code in Listing 11.0.1 produces the following output:
This is a new piece of terminology. Here is a word we have chosen to emphasize. This is an alert to the reader! This is a piece of code typeset in a different font.