summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/classicthesis/classicthesis-arsclassica.sty
blob: ccaf2ff8b07b7089bccf9c88fd067440c6edd7da (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
%************************************************************
% classicthesis-arsclassica.sty
% Integrated into classicthesis with permission and adapted
% by André Miede and Ivo Pletikosić
% 2018
%************************************************************
% Copyright (C) 2008--2017 Lorenzo Pantieri
% http://www.lorenzopantieri.net/
%************************************************************

\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{classicthesis-arsclassica}[2018/05/20]

\ifdefined\classicthesis\else\RequirePackage{classicthesis}\fi


%************************************************************
% Fonts
%************************************************************
\ifthenelse{\boolean{xetex}\OR\boolean{luatex}}
    {\setsansfont[Ligatures=TeX,Numbers=OldStyle]{Iwona}}
    {\renewcommand{\sfdefault}{iwona}}
\renewcommand*{\ct@altfont}{\sffamily}

\ifthenelse{\boolean{ct@eulerchapternumbers}}% font for the chapter numbers; scale in classicthesis is 7
    {\DeclareFixedFont{\chapterNumber}{U}{eur}{b}{n}{50}}%
    {\DeclareFixedFont{\chapterNumber}{T1}{pplj}{m}{n}{50}}%

%************************************************************
% Caption
%************************************************************
\captionsetup{font=small,labelfont={sf,bf},format=hang}
\captionsetup[table]{skip=\medskipamount}

%************************************************************
% Itemize
%************************************************************
\renewcommand\labelitemi{\color{CTsemi}$\bullet$}

%************************************************************
% Headlines
%************************************************************
\renewcommand{\sectionmark}[1]{\markright{\textsc{\MakeTextLowercase{\thesection}} \spacedlowsmallcaps{#1}}}
\lehead{\mbox{\llap{\small\thepage\kern1em\color{CTsemi}\vline}\color{CTsemi}\hspace{0.5em}\headmark\hfil}}
\rohead{\mbox{\hfil{\color{CTsemi}\headmark\hspace{0.5em}}\rlap{\small{\color{CTsemi}\vline}\kern1em\thepage}}}
\renewcommand{\headfont}{\normalfont\sffamily}
\renewcommand{\pnumfont}{\small\sffamily}
\clearscrplain
\rofoot[\mbox{\makebox[0pt][l]{\kern1em\thepage}}]{}

%************************************************************
% Layout of the chapter-, section-, subsection-,
% subsubsection-, paragraph and description-headings
%************************************************************
% chapters
\newcommand\formatchapter[1]{%
  \vbox to \ht\strutbox{%
  \setbox0=\hbox{\chapterNumber\thechapter\hspace{10pt}\vline\ }%
  \advance\hsize-\wd0 \advance\hsize-10pt\raggedright%
  \spacedallcaps{#1}\vss}}
\titleformat{\chapter}[block]%
   {\normalfont\Large\sffamily}%
   {\textcolor{CTsemi}{\chapterNumber\thechapter}%
   \ \,\hspace{10pt}\vline\ }{10pt}%
   {\formatchapter}
% sections
\titleformat{\section}%
	 {\normalfont\Large\sffamily}{\textsc%
  {\MakeTextLowercase{\thesection}}}%
  {1em}{\spacedlowsmallcaps}
% subsections
\titleformat{\subsection}%
  {\normalfont\sffamily\bfseries}{\textsc{\MakeTextLowercase%
  {\thesubsection}}}{1em}{\normalsize}
% subsubsections
\titleformat{\subsubsection}%
  {\normalfont\sffamily\bfseries\itshape}{\textsc%
  {\MakeTextLowercase{\thesubsubsection}}}%
  {1em}{\normalsize\itshape}
% paragraphs
\titleformat{\paragraph}[runin]%
  {\normalfont\normalsize\sffamily\bfseries}{\textsc%
  {\MakeTextLowercase{\theparagraph}}}%
  {0pt}{\spacedlowsmallcaps}
% descriptionlabels
\renewcommand{\descriptionlabel}[1]{\hspace*{\labelsep}\bfseries\spacedlowsmallcaps{#1}}

\titlespacing*{\chapter}{0pt}{1\baselineskip}{2\baselineskip}
\titlespacing*{\section}{0pt}{2\baselineskip}{.8\baselineskip}[\marginparsep]
\titlespacing*{\subsection}{0pt}{1.5\baselineskip}{.8\baselineskip}[\marginparsep]
\titlespacing*{\paragraph}{0pt}{1\baselineskip}{1\baselineskip}
%************************************************************