Trying to customise chapter heading, i have trouble controlling the vertical spacing between the rule and the chapter name. I would like to use paragraph spacing instead of indentation, so i'm using the Koma options parskip=half*
But the spacing described before is bigger than with parskip=false and feels weird.
How can I define \chapterformat to avoid this issue?
Here is a somewhat MWE :
\documentclass[fontsize=12pt,french]{scrreprt}
\usepackage[utf8]{inputenc}
\usepackage{luatextra}
\usepackage{polyglossia}
\usepackage{blindtext}
\defaultfontfeatures{Ligatures=TeX} % To support LaTeX quoting style
\setmainfont{Cambria}
\setsansfont{Calibri}
\KOMAoption{chapterprefix}{true}
\KOMAoptions{%
parskip=half*
}%
\renewcommand*\raggedchapter{\centering}
\RedeclareSectionCommand[beforeskip=0pt,afterskip=8\baselineskip,innerskip=0pt]{chapter}
%\setkomafont{chapterprefix}{\normalsize\mdseries}
\renewcommand*{\chapterformat}{%
\chapappifchapterprefix{\nobreakspace}\thechapter\autodot%
\IfUsePrefixLine{%
{\parskip=0pt\par}\nobreak\vspace{-\parskip}\vspace{-.6\baselineskip}%
\rule{0.9\textwidth}{.5pt}%
}{\enskip}%
}
\newcommand\SectionFontStyle{\sffamily}
\setkomafont{sectioning}{\SectionFontStyle}
\addtokomafont{chapter}{\bfseries\scshape} % Chapter in samm capitals font
\begin{document}
\tableofcontents
\chapter{Chapter One}
\textbf{\KOMAScriptVersion}
\par
\Blindtext
\addchap{Chapter without number}
\Blindtext
\end{document}