1 | \definecolor{TitleColor}{rgb}{0,0,0} |
---|
2 | \definecolor{InnerLinkColor}{rgb}{0,0,0} |
---|
3 | \definecolor{OuterLinkColor}{rgb}{1.0,0.5,0.0} |
---|
4 | |
---|
5 | \newenvironment{underscoresplit}{\let\underscore\_ |
---|
6 | \renewcommand{\_}{\discretionary{\underscore}{}{\underscore}}}{} |
---|
7 | |
---|
8 | \let\oldtabulary\tabulary |
---|
9 | \let\endoldtabulary\endtabulary |
---|
10 | |
---|
11 | \renewenvironment{tabulary}{\underscoresplit\oldtabulary}{\endoldtabulary\endunderscoresplit} |
---|
12 | |
---|
13 | \let\oldprintindex\printindex |
---|
14 | |
---|
15 | \renewenvironment{printindex}{\underscoresplit\oldprintindex} |
---|
16 | |
---|
17 | \fvset{ |
---|
18 | numbers=left, |
---|
19 | numbersep=5pt, |
---|
20 | gobble=0, |
---|
21 | } |
---|
22 | |
---|
23 | \renewcommand{\maketitle}{% |
---|
24 | \let\spx@tempa\relax |
---|
25 | \ifHy@pageanchor\def\spx@tempa{\Hy@pageanchortrue}\fi |
---|
26 | \hypersetup{pageanchor=false}% avoid duplicate destination warnings |
---|
27 | \begin{titlepage}% |
---|
28 | \let\footnotesize\small |
---|
29 | \let\footnoterule\relax |
---|
30 | \par |
---|
31 | \begingroup % for PDF information dictionary |
---|
32 | \def\endgraf{ }\def\and{\& }% |
---|
33 | \pdfstringdefDisableCommands{\def\\{, }}% overwrite hyperref setup |
---|
34 | \hypersetup{pdfauthor={\@author}, pdftitle={\@title}}% |
---|
35 | \endgroup |
---|
36 | \begin{center}{% |
---|
37 | \vspace*{3cm} |
---|
38 | \includegraphics{logo.pdf} |
---|
39 | \vspace{3cm} |
---|
40 | \par |
---|
41 | {\rm\Huge \@title \par}% |
---|
42 | {\em\LARGE \py@release\releaseinfo \par} |
---|
43 | {\large |
---|
44 | \copyright \space \rtemscopyright \par |
---|
45 | \py@authoraddress \par |
---|
46 | }% |
---|
47 | }% |
---|
48 | \end{center}%\par |
---|
49 | \@thanks |
---|
50 | \end{titlepage}% |
---|
51 | \setcounter{footnote}{0}% |
---|
52 | \let\thanks\relax\let\maketitle\relax |
---|
53 | %\gdef\@thanks{}\gdef\@author{}\gdef\@title{} |
---|
54 | \if@openright\cleardoublepage\else\clearpage\fi |
---|
55 | \spx@tempa |
---|
56 | } |
---|
57 | |
---|
58 | \fancypagestyle{normal}{ |
---|
59 | \fancyhf{} |
---|
60 | \fancyfoot[LE,RO]{{\thepage}} |
---|
61 | \fancyfoot[LO]{{\ifnum\value{chapter}>0{\nouppercase{\rightmark}}\fi}} |
---|
62 | \fancyfoot[RE]{{\nouppercase{\leftmark}}} |
---|
63 | \fancyhead[LE,RO]{{\@title, \py@release}} |
---|
64 | \fancyhead[RE,LO]{{\ifnum\value{chapter}>0{\chaptername\:\thechapter\:Section\:\thesection}\fi}} |
---|
65 | \renewcommand{\headrulewidth}{0.4pt} |
---|
66 | \renewcommand{\footrulewidth}{0.4pt} |
---|
67 | } |
---|
68 | |
---|
69 | \fancypagestyle{plain}{ |
---|
70 | \fancyhf{} |
---|
71 | \fancyfoot[LE,RO]{{\thepage}} |
---|
72 | \renewcommand{\headrulewidth}{0pt} |
---|
73 | \renewcommand{\footrulewidth}{0.4pt} |
---|
74 | } |
---|
75 | |
---|
76 | \titleformat{\section}{\Large}% |
---|
77 | {\py@TitleColor\thesection}{0.5em}{\py@TitleColor}{\py@NormalColor} |
---|
78 | \titleformat{\subsection}{\large}% |
---|
79 | {\py@TitleColor\thesubsection}{0.5em}{\py@TitleColor}{\py@NormalColor} |
---|
80 | \titleformat{\subsubsection}{}% |
---|
81 | {\py@TitleColor\thesubsubsection}{0.5em}{\py@TitleColor}{\py@NormalColor} |
---|
82 | \titleformat{\paragraph}{\large}% |
---|
83 | {\py@TitleColor}{0em}{\py@TitleColor}{\py@NormalColor} |
---|
84 | |
---|
85 | \ChNameVar{\raggedleft\normalsize} |
---|
86 | \ChNumVar{\raggedleft \bfseries\Large} |
---|
87 | \ChTitleVar{\raggedleft \rm\Huge} |
---|
88 | |
---|
89 | \usepackage{enumitem} |
---|
90 | \setlist[description]{style=nextline,leftmargin=10pt} |
---|
91 | |
---|
92 | \let\oldsection\section |
---|
93 | \renewcommand\section{\clearpage\oldsection} |
---|
94 | |
---|
95 | \usepackage{titlesec} |
---|
96 | \setcounter{secnumdepth}{8} |
---|
97 | |
---|
98 | \renewcommand\thepart{\@Roman\c@part} |
---|
99 | \renewcommand\part{% |
---|
100 | \pagestyle{normal} |
---|
101 | \if@noskipsec \leavevmode \fi |
---|
102 | \cleardoublepage |
---|
103 | \vspace*{6cm}% |
---|
104 | \@afterindentfalse |
---|
105 | \secdef\@part\@spart} |
---|
106 | |
---|
107 | % fonts |
---|
108 | \usepackage{charter} |
---|
109 | \usepackage{rtemsextrafonts} |
---|