I tried to use a header and footer layout I found here on this website. But I have some problems with changing the code to what I want. I want the pagenumbering to be like page x of y in the footer. It would be nice with this layout (just with page x of y instead of just page x):
\cfoot{\parbox{\textwidth}{\hrulefill\kern-0.6ex\raisebox{-0.5ex}{$\Bigl[$\makebox[2em][c]{\thepage}$\Bigr]$}\kern-0.5ex\hrulefill}}
But the pagenumbering is in the header and there aren't a space between the letters and the numbers as you can see in my minimal work example:
\documentclass[12pt,a4paper]{book}%generelt
\usepackage{fancyhdr}
\pagestyle{fancy}
\fancyhf{} % clear all headers and footers
\renewcommand{\headrulewidth}{0pt} % remove rule between header and text
\fancyhead[LE, RO]{\thepage of \pageref{LastPage}} % put page number in left header on even pages,
% right header on odd pages
\fancyhead[RE]{\nouppercase{\leftmark}} % remove uppercase on chapter title
\renewcommand{\chaptermark}[1]{\markboth{#1}{}} % remove "Chapter N." prefi
\usepackage{lastpage}
Another problem is that I would like to have a chapter numbering in the header. The design is really nice, but I would like to have the chapter number too, just like "CHAnumber| name of the chapter".
Is it possible to make this two changes? And how? Thank you very much for help!
fancyhdr
, how aboutscrlayer-scrpage
?