Document Structure

This module provides utilities to define a document’s basic structure.

class simpletex.document.Document(document_class: str = 'article', size: str = '12pt')

Bases: simpletex.base.Environment

A class which manages a LaTeX document.

Upon instantiation, sets the input encoding to UTF-8 and declares the document class. This class does NOT manage the preamble (imports, newcommand declarations, etc.). The preamble is managed by the simpletex.Preamble class.

Create an empty document using the given document class and font size.

document_class : str
The LaTeX document class name to use.
size : str
The default font size to use.
class simpletex.document.Section(name: str)

Bases: simpletex.document.Title

Represents a LaTeX section.

Create an empty section with the given name.

name : str
The section name.
class simpletex.document.Subsection(name: str)

Bases: simpletex.document.Title

Represents a LaTeX subsection.

Create an empty subsection with the given name.

name : str
The subsection name.