I'm writing my Thesis but I have run into some layout troubles, I'm using the standard book document class, which results in my Chapters headings in the form of:
Chapter #
Name of my chapter
I was looking for a way to change it, removing the "Chapter #" from it to the form of:
Name of my chapter
I have tried doing what I wanted with the following code on my main file, although I don't know if it is ideal, like I said in the comments I have tried with the /titlesec but I couldn't remove the chapter number:
\renewcommand{\@makechapterhead}[1]{\vspace*{50\p@}%
{\parindent \z@ \raggedright \normalfont
\hrule % horizontal line
\vspace{5pt}% % add vertical space
\interlinepenalty\@M
\Huge \scshape #1\par % chapter title
\vspace{5pt}% % add vertical space
\hrule % horizontal rule
\nobreak
\vskip 2\baselineskip
}}
\renewcommand{\@makeschapterhead}[1]{%
\vspace*{50\p@}%
{\parindent \z@ \raggedright
\normalfont
\hrule % horizontal line
\vspace{5pt}% % add vertical space
\interlinepenalty\@M
\Huge \scshape #1\par % chapter title
\vspace{5pt}% % add vertical space
\hrule % horizontal line
\nobreak
\vskip 2\baselineskip
}}
I also need to set the spacing after the chapter heading to two lines as it's one of the requirements from my university, I'm currently trying to do it with the \vskip #\baselineskip
but I'm getting a bigger spacing than the one I wanted so I'm guessing it has to do with the \Huge
format modifier I used but I'm not sure.
Best Answer
Here's a possible solution using the titlesec package; setting the value of
\aftertitleunit
to\baselineskip
, you can then use*2
in the fourth mandatory argument of\titlespacing
to obtain the desired vertical spacing between the title and the following text. You didn't provide information on the spacing before the title so I used50pt
, but you can change this value to the one that best suits your needs. To maintain consistency between the numbered and unnumbered chapters I used two\titleformat
commands with similar settings: one for the numbered chapters and another one, using thenumberless
key, for the unnumbered ones:Taking into account the edit to the original question, you can add
\normalsize
just before\vskip2\baselineskip
:And here's the same layout but using
titlesec
: