4

I've found a thesis with really beautiful chapter headings that I would like to use. What package am I going to need and how would I go about creating a heading that looks like the one below. Also, if you have or know of any nice headings do please share! chapter heading

  • 1
    Welcome to TeX.SX! Please help us to help you and add a minimal working example (MWE) that illustrates your problem. It will be much easier for us to reproduce your situation and find out what the issue is when we see compilable code, starting with \documentclass{...} and ending with \end{document}. – Henri Menke Aug 3 '14 at 10:46
  • @HenriMenke I don't think that an MWE is appropriate for this question – Kartik Aug 3 '14 at 13:03
6

Here's an option using the titlesec package:

screenshot

I've used the general format of the titleformat command:

% from the titlesec package
%\titleformat{ command }
%             [ shape ]
%             { format }{ label }{ sep }{ before-code }[ after-code ]

You can find more information by studying the documentation, and by viewing other similar questions on this site.

Here's a complete MWE to play with:

% arara: pdflatex
\documentclass{report}
\usepackage{lipsum}
\usepackage[explicit]{titlesec}

% title format for the chapter
\titleformat{\chapter}
    {\bfseries\large}
    {}
    {0pt}
    {\titlerule[3pt]~\raisebox{-1.5pt}{\sc{Chapter}~\thechapter}~\titlerule[3pt]%
            \\\vspace{.05cm}\titlerule\\\filcenter #1 \\\vspace{.25cm}\titlerule}
\begin{document}
\chapter{First chapter}
\lipsum[1]
\chapter{Second chapter}
\lipsum[2]

\end{document}

You mention that you might like to see other ideas; here's another one, again using the titlesec package but without the explicit option - I have used the tcolorbox package to put a box around the chapter number. I don't know if I'd recommend it for a thesis, but it might give you some further ideas:

screenshot

Here's the code:

% arara: pdflatex
% !arara: indent: {overwrite: yes}
\documentclass{report}
\usepackage{lipsum}
\usepackage{titlesec}
\usepackage{tcolorbox}
\tcbuselibrary{skins}

% title format for the chapter
% custom chapter
\titleformat{\chapter}
{\normalfont\Large\filleft\bfseries}                    % format applied to label+text
{}                                                      % label
{1pc}                                                   % horizontal separation between label and title body
{%
    % draw a box around the chapter number
    \begin{tcolorbox}[
            enhanced,flushright upper,
            boxrule=1.4pt,
            colback=white,colframe=black!50!yellow,
            drop fuzzy midday shadow=black!50!yellow,
        width=2.8cm]
        \resizebox{2cm}{!}{\color{gray!80}\thechapter}%
    \end{tcolorbox}\Huge} % before the title body
[]                        % after the title body
\begin{document}
\chapter{First chapter}
\lipsum[1]
\chapter{Second chapter}
\lipsum[2]

\end{document}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.