[Tex/LaTex] fncychap package – reduce vertical gap/space between header and chapter heading

chaptersfncychapsectioningvertical alignment

The package fncychap, using \chapter places the chapter heading 1/3 down the page. How can we place it closer to the top? That is; the words "Test Chapter" closer to the header "My Header" in the minimal working example (MWE) below?

\documentclass[twoside,a4paper,11pt,Final]{book}
\usepackage{fancyhdr}
\usepackage[Bjornstrup]{fncychap}

\begin{document}

    \fancyhf{} 
    \pagestyle{fancy} 

    \fancyfoot[RE,RO]{Page Number: \thepage}
    \fancyhead[RE,RO]{My Header: \thesection}

    \let\cleardoublepage\clearpage

    \chapter{Test Chapter}
    \thispagestyle{fancy}
    Some writing in the chapter.

\end{document}

Best Answer

Like the standard classes, fncychap puts a vertical space of 50pt before the chapter heading. This code redefines the two chapter head macros, you may adjust the argument of \vspace, I set it to 10 pt:

\makeatletter
\renewcommand*{\@makechapterhead}[1]{%
  \vspace*{10\p@}%
  {\parindent \z@ \raggedright \normalfont
    \ifnum \c@secnumdepth >\m@ne
      \if@mainmatter%%%%% Fix for frontmatter, mainmatter, and backmatter 040920
        \DOCH
      \fi
    \fi
    \interlinepenalty\@M
    \if@mainmatter%%%%% Fix for frontmatter, mainmatter, and backmatter 060424
      \DOTI{#1}%
    \else%
      \DOTIS{#1}%
    \fi
  }}
% For the case \chapter*:
\renewcommand*{\@makeschapterhead}[1]{%
  \vspace*{10\p@}%
  {\parindent \z@ \raggedright
    \normalfont
    \interlinepenalty\@M
    \DOTIS{#1}
    \vskip 40\p@
  }}
\makeatother

You could define a TeX length to store the value, then you would do better than the package which directly uses numerical values in its macros.