I'm trying to get titlesec to put the title of each chapter, section and subsection in a different page. Right now, I'm close, but there are two problems:
- titles show up twice in the index
- the index also is affected by the settings and its title is in a different page
Any help would be appreciated.
Cheers.
Code: Select all
Code, edit and compile here:
% !TeX spellcheck = es_ES\documentclass[12pt,a4paper,oneside]{book}\usepackage[spanish,activeacute]{babel}\usepackage[utf8]{inputenc}\usepackage{makeidx}\usepackage[bf,big,center]{titlesec}\titleformat{\chapter}[display]{\normalfont\Large\filcenter\sffamily}{\thechapter}{1pc}{\titlerule\vspace{1pc}%\Huge}[\newpage] % creates the new page\titleformat{\section}{\vspace*{\fill}\centering\normalfont\Large\bfseries}{\thechapter.\Alph{section}}{1em}{\Large}[\vspace*{\fill}\newpage]\titleformat{\subsection}{\vspace*{\fill}\centering\normalfont\Large\bfseries}{\thechapter.\Alph{section}.\arabic{subsection}}{1em}{\Large}%[\vspace*{\fill}\newpage]\titleformat{\subsubsection}{\vspace*{\fill}\centering\normalfont\Large\bfseries}{}{1em}{\Large}[\vspace*{\fill}]%[\vspace*{\fill}\newpage]\makeindex