0

Is there a way to set the headmark (name of the capter in the header) in the same height with the image?

\documentclass[12pt,DIV=10,ngerman,headings = normal,listof = totoc,bibliography = totoc,index = totoc]{scrreprt}
\usepackage{babel}
\usepackage[latin1]{inputenc}
\usepackage{setspace}
\onehalfspacing
\usepackage{geometry}
\geometry{left=30mm,right=30mm,top=25mm,bottom=45mm,headheight=21mm}
\usepackage[demo]{graphicx}
\usepackage{xcolor} 
\usepackage[automark,headsepline=1pt]{scrlayer-scrpage}
\renewcommand*{\chapterpagestyle}{scrheadings} 
\clearpairofpagestyles

%\ihead{\textsc{}\\ [1ex]{\headmark}}
\ihead{\headmark}

\rohead{\includegraphics[width=3cm,height=1cm]{Test}}  
\renewcommand{\headfont}{\color{gray}\normalfont\small}
\begin{document} 
\chapter{no depth}
\chapter{with a g}
\end{document}

And with a very little margin to the headsepline?

1

Maybe you want something like

enter image description here

\documentclass[12pt,DIV=10,ngerman,headings=normal,listof=totoc,bibliography=totoc,index=totoc]{scrreprt}
\usepackage{babel}
\usepackage[latin1]{inputenc}
\usepackage{setspace}
\onehalfspacing
\usepackage{geometry}
\geometry{left=30mm,right=30mm,top=25mm,bottom=45mm,headheight=21mm}
\usepackage[demo]{graphicx}
\usepackage{xcolor}
\usepackage[automark,headsepline=1pt]{scrlayer-scrpage}
\clearpairofpagestyles
\ihead{\headmark}
\rohead{\raisebox{0pt}[\ht\strutbox]{\includegraphics[width=3cm,height=1cm]{Test}}}% <- changed
\addtokomafont{pagehead}{\color{gray}\normalfont\small}% <- changed
\renewcommand*{\chapterpagestyle}{scrheadings}

\begin{document} 
\chapter{test}
\chapter{with a g}
\end{document}

You could modify the layer with the head sepline to change its vertical position:

\ModifyLayer[addvoffset=5pt]{scrheadings.head.below.line}

If option plainheadsepline=true is set, you also have to modify the layer for the plain style:

\ModifyLayer[addvoffset=5pt]{plain.scrheadings.head.below.line}
  • Yes, it is! Thank you. – kolja Feb 27 at 5:40
  • If my answer solves your issue, then you can upvote and maybe except it. – esdd Feb 27 at 9:19
0

And to change the margin of the headspline to the Text and image:

\ModifyLayer[addvoffset=5pt]{scrheadings.head.below.line}
\ModifyLayer[addvoffset=5pt]{plain.scrheadings.head.below.line}

Source: Lower headsepline

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for?Browse other questions tagged or ask your own question.