Section mark styling and page number style

Im quite new to LaTex but i am willing to learn how to style my own Thesis instead of just copy and paste some code from a template.

Now im facing a problem. I would like to style my thesis similar to that example:

Sure, the CleanThesis Template can do that, but i dont really want to include all the other code which i maybe dont neeed at all.

Therefore i would like to ask you, how i can implement the red marked behaviour. In CleanThesis the big "Section" Numbers are in fact Chapter numbers. Since my thesis is based on the "article" class i dont have chapters at all. Is it also possible to style the main "sections"

\section{some Section}


according to my example? Or is it only possible for Chapters?

Thank you :)

Edit 1: It is also important for me to learn how to put the subsection number (here 2.1) beneath or "outside" of the textblock

Edit 2:

Now i have changed my class to scrreprt to include koma script. Then i added the following:

\definecolor{chaptercolor}{rgb}{0.36,0.73,0.82}

\setkomafont{chapter}{\normalfont\color{chaptercolor}\Huge}
\setkomafont{chapterprefix}{\Large}
\renewcommand*{\raggedchapter}{\raggedleft}
\renewcommand*{\chapterformat}{%
\MakeUppercase{\chapappifchapterprefix{}}%
\rlap{\enskip\resizebox{!}{2.2cm}{\thechapter} \rule{1.5mm}{4cm} }%
}

\RedeclareSectionCommand[beforeskip=8mm,afterskip=10mm]{chapter}


With the above code i got this:

How can i make the Text that it floats to left and define its margin from the chapter number? and how can i change the position of the line to the left side of the number?

Thanks

• I beg your pardon, but the report class does have chapters. This being said, you should take a look at the titlesec package for a custom formatting of section titles. – Bernard May 17 at 9:10
• yes, you are right. i meant the article class... Thanks, i will take a look at it. Is it also usefull to add the mentioned footer line beneath the page number? And can it also be used to put the section number beneath the text? – C. Hediger May 17 at 9:17
• Do you mean the section number also in the footer? – Bernard May 17 at 9:21
• No in the footer in only want the page number but with a blue line. – C. Hediger May 17 at 9:47
• Where, then, ‘the section number beneath the text’? – Bernard May 17 at 10:29

Here is a suggestion using KOMA-Script class scrreprt (onesided, without chapterprefix, section titles all left aligned) as mentioned in your "Edit 2" in the question:

\documentclass[paper=letter,DIV=11,
%twoside=true,open=right% if the document should be twosided
]{scrreprt}
\usepackage{blindtext}% only for dummy text
\usepackage{lmodern}% scalable font

\usepackage{xcolor}
\definecolor{chaptercolor}{rgb}{0.36,0.73,0.82}

\colorlet{ctcolorchapterline}{chaptercolor}
\colorlet{ctcolorchapternum}{chaptercolor}
\colorlet{ctcolorfooterline}{chaptercolor}
\colorlet{ctsectiontitles}{chaptercolor}

\cfoot*{}
\ofoot*{}

\DeclareNewLayer[
foreground,
oddpage,
foot,
contents={%
\hfill
\makebox[0pt][l]{%
\pagenumberrule
\hspace*{10pt}%
\pagemark
}%
}
]{pagenumber.odd}
\DeclareNewLayer[
clone=pagenumber.odd,
evenpage,
contents={%
\makebox[0pt][r]{%
\pagemark
\hspace*{10pt}%
\pagenumberrule
}%
}
]{pagenumber.even}
\newcommand*\pagenumberrule{%
{\color{ctcolorfooterline}\rule[\dimexpr-10cm+\ht\strutbox\relax]{1.25pt}{10cm}}%
}

\makeatletter
\renewcommand\chapterlinesformat[3]{%
\ifstr{#1}{chapter}
{%
\parbox[b][\ht\strutbox]{\textwidth}{%
\parbox[b]{\dimexpr\textwidth-3em\relax}{\raggedright#3}%
\makebox[3em][r]{%
\hfill
#2%
}%
}%
}{\@hangfrom{#2}{#3}}% <- original definition for other levels
}
\makeatother
\renewcommand\chapterformat{%
\textcolor{ctcolorchapterline}{\rule[-5pt]{2pt}{10cm}}%
{\fontsize{60}{60}\selectfont\textcolor{ctcolorchapternum}{\thechapter}}%
}

\renewcommand*\sectionlinesformat[4]{%
\makebox[0pt][r]{#3}{\textcolor{ctsectiontitles}{#4}}%
}

\begin{document}
\tableofcontents
\chapter{Chapter with short title}
\Blindtext[2]
\chapter{A test chapter with a long title that will span two lines}
\Blindtext
\blinddocument
\end{document}


Result:

• Wow! Thank you so much! works perfectly – C. Hediger May 17 at 13:11
• how can i change the fontstyle from normal to thin or to bold for the chapter number, section and chapter title? – C. Hediger May 17 at 16:19
• By default they are all bold. If they all should not be bold, add \addtokomafont{disposition}{\mdseries}. Please read the KOMA-Scirpt documentation: \addtokomafont, \setkomafont, ... – esdd May 17 at 22:48