# Line break between \partname\thepart and \part in formatted header

How can I get the formatted \part to show Part I in one line and the Name of the Part One in the other line (line break) as it shows in the \chapter without formatting?

\documentclass{report}
\usepackage{titlesec}
%For defining the style of the part
\titleclass{\part}{top}\titleformat{\part}{\centering\normalfont\Large}{\partname\hspace{2pt}\thepart\hspace{2pt}}{2pt}{}
\begin{document}
\part{Name of the Part One}
\chapter{Name of the Chapter One}
\section{Section One}
Some text!
\section{Section Two}
Some text!
\end{document}


I don´t know if it´s exactly what you want but you can use \titleformat{\part}{display} to set the label to another line.

You can reproduce the formatting of part as chapter with the code below and change the formatting setting for the partname. The last parameter is the formatting for the title of the part.

\documentclass{report}
\usepackage{titlesec}
%For defining the style of the part
%\titleclass{\part}{top}\titleformat{\part}{\centering\normalfont\Large}{\partname\hspace{2pt} \thepart\hspace{2pt}}{2pt}{}

%part formatted same as chapter
\titleformat{\part}[display]{\normalfont\huge\bfseries}{\partname\ \thepart} % partname formatting
{20pt} % vertical space
{\Huge} %part title formatting

\begin{document}
\part{Name of the Part One}
\chapter{Name of the Chapter One}
\section{Section One}
Some text!
\section{Section Two}
Some text!
\end{document}


and you get:

• Thanks for your reply! But my challenge is to get that result with the formatted \part, if I don't format I get that result but then it does not fit the layout required for my paper. – hehe_br Nov 14 '14 at 17:03
• didn't understand yet. What´s exactly the layout required?? – Smarzaro Nov 14 '14 at 17:43
• the one that is set in the example by the \titleformat{\part}...! Without the formatting the font size is too big and with \titleclass{\part}{top} I get some more space to have a mini table of contents on the part page. – hehe_br Nov 14 '14 at 17:52
• See the edit I made in the answer. I think you can change to fit your needs. – Smarzaro Nov 14 '14 at 17:53
• Yes, this works perfectly! Thanks for your help! – hehe_br Nov 14 '14 at 17:57