Skip to main content

The PreTeXt Guide

Section 29.6 Styling

The PreTeXt conversion to HTML creates standard HTML elements, with styles controlled by CSS via class names (and not so much via the element names). As evidence of this, building HTML without the accompanying Javascript and CSS renders in a readable fashion, albeit quite plain (as one would expect). This section describes ways that a publisher can influence the style by using the publication file to specify the use of alternate CSS files. See Subsection 44.4.10 for exact syntax for the following options.

Colors.

The default file, colors_default.css contains documentation on how to design a color theme.

Style.

A file may be used to control the look of content, such as consistently putting a colored box with a border around certain blocks. As of 2022-12-15, the two options are default and oscarlevin.

Table of Contents, Knowls, Banner, Navigation Bar, and Shell.

These user-interface (UI) elements can be styled with their own CSS.

Development.

Please join us on the pretext-dev discussion group if you want to create alternate styles.