Home General LaTeX tips and tricks → Fancy chapter titles [Previous Page] [Question index] [Next Page]

13. How do you get fancy chapter titles?


Answer

Use the fncychap package by Ulf Lindgren.

This package predefines six types of ‘fancy’ chapter title formats. You can define your own using these as a starting point or, as I did, simply tweak one of the existing formats until it is to your liking.


Example usage

In the preamble:


\usepackage[Lenny]{sty/fncychapleo}

The ‘Lenny’ style is one of the predefined styles. Since I made some minor changes to it (based in turn on original modifications by fellow PhD student Jos Dingjan), I'm using my own version of the style file. Consult the thesis sources for full details.

In the manuscript:


\chapter{Compiler Construction Tools}


Result, before

'Before' screenshot

Result, after

'After' screenshot

Things to watch out for

The Helvetica-Narrow chapter title font shown above is a result of my font-tweaking the ‘Lenny’ style, not of the sectsty package described in the previous tip. This is because using a fncychap style will override the sectsty font definition, at least as far as chapter titles are concerned.

If you just want to use the standard chapter title format (as in the ‘before’ shot), but with a different font, using sectsty will be sufficient:

'After' screenshot

[Previous page] [Question index] [Next page]

Leo Breebaart (leo@lspace.org)
Last updated: 27 June 2016