titlesec

Headings of a document's own design.

Loading

\usepackage{titlesec}

A module of its own, compiled into mLaTeX: the package's commands are defined over mLaTeX's primitives.

Commands

\chaptertitlename, \color, \filcenter, \filinner, \filleft, \filouter, \filright, \subsection, \thesection, \thesubsection, \thetitle, \titleclass, \titleformat, \titlelabel, \titlerule, \titlespacing.

Example

A document that uses it, from mLaTeX's own tests, so it compiles as written, and below it what mLaTeX sets from it in your browser:

titlesec.tex
\documentclass{article}
\usepackage{titlesec}
\usepackage{xcolor}
\begin{document}
\titleformat{\section}{\Large\bfseries\color{blue}}{\thesection}{1em}{}[\titlerule]
\titlespacing*{\section}{0pt}{12pt}{6pt}
\titleformat{\subsection}[runin]{\bfseries}{\thesubsection}{0.5em}{}
\section{A designed heading}
\subsection{Run in} text follows.
\end{document}
OutputLoading mLaTeX in your browser
Loading mLaTeX

Limits

Frames and other code after the title are ignored.