-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstyles.tex
More file actions
142 lines (122 loc) · 4.24 KB
/
styles.tex
File metadata and controls
142 lines (122 loc) · 4.24 KB
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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
%!TEX root = std.tex
%% styles.tex -- set styles for:
% chapters
% pages
% footnotes
%%--------------------------------------------------
%% create chapter style
\makechapterstyle{valstd}{%
\renewcommand{\beforechapskip}{\onelineskip}
\renewcommand{\afterchapskip}{\onelineskip}
\renewcommand{\chapternamenum}{}
\renewcommand{\chapnamefont}{\chaptitlefont}
\renewcommand{\chapnumfont}{\chaptitlefont}
\renewcommand{\printchapternum}{\chapnumfont\thechapter\quad}
\renewcommand{\afterchapternum}{}
}
%%--------------------------------------------------
%% create page styles
\makepagestyle{valpage}
\makeevenhead{valpage}{\copyright\,\textsc{Valpineware}}{}{\textbf{\docno}}
\makeoddhead{valpage}{\copyright\,\textsc{Valpineware}}{}{\textbf{\docno}}
\makeevenfoot{valpage}{\leftmark}{}{\thepage}
\makeoddfoot{valpage}{\leftmark}{}{\thepage}
\makeatletter
\makepsmarks{valpage}{%
\let\@mkboth\markboth
\def\chaptermark##1{\markboth{##1}{##1}}%
\def\sectionmark##1{\markboth{%
\ifnum \c@secnumdepth>\z@
\textsection\space\thesection
\fi
}{\rightmark}}%
\def\subsectionmark##1{\markboth{%
\ifnum \c@secnumdepth>\z@
\textsection\space\thesubsection
\fi
}{\rightmark}}%
\def\subsubsectionmark##1{\markboth{%
\ifnum \c@secnumdepth>\z@
\textsection\space\thesubsubsection
\fi
}{\rightmark}}%
\def\paragraphmark##1{\markboth{%
\ifnum \c@secnumdepth>\z@
\textsection\space\theparagraph
\fi
}{\rightmark}}}
\makeatother
\aliaspagestyle{chapter}{valpage}
%%--------------------------------------------------
%% set heading styles for main matter
\newcommand{\beforeskip}{-.7\onelineskip plus -1ex}
\newcommand{\afterskip}{.3\onelineskip minus .2ex}
\setbeforesecskip{\beforeskip}
\setsecindent{0pt}
\setsecheadstyle{\large\bfseries\raggedright}
\setaftersecskip{\afterskip}
\setbeforesubsecskip{\beforeskip}
\setsubsecindent{0pt}
\setsubsecheadstyle{\large\bfseries\raggedright}
\setaftersubsecskip{\afterskip}
\setbeforesubsubsecskip{\beforeskip}
\setsubsubsecindent{0pt}
\setsubsubsecheadstyle{\normalsize\bfseries\raggedright}
\setaftersubsubsecskip{\afterskip}
\setbeforeparaskip{\beforeskip}
\setparaindent{0pt}
\setparaheadstyle{\normalsize\bfseries\raggedright}
\setafterparaskip{\afterskip}
\setbeforesubparaskip{\beforeskip}
\setsubparaindent{0pt}
\setsubparaheadstyle{\normalsize\bfseries\raggedright}
\setaftersubparaskip{\afterskip}
%%--------------------------------------------------
% set heading style for annexes
\newcommand{\Annex}[3]{\chapter[#2]{(#3)\protect\\#2\hfill[#1]}\relax\label{#1}}
\newcommand{\infannex}[2]{\Annex{#1}{#2}{informative}}
\newcommand{\normannex}[2]{\Annex{#1}{#2}{normative}}
%%--------------------------------------------------
%% set footnote style
\footmarkstyle{\smaller#1) }
%%--------------------------------------------------
% set style for main text
\setlength{\parindent}{0pt}
\setlength{\parskip}{1ex}
\setlength{\partopsep}{-1.5ex}
%%--------------------------------------------------
%% set caption style and delimiter
\captionstyle{\centering}
\captiondelim{ --- }
% override longtable's caption delimiter to match
\makeatletter
\def\LT@makecaption#1#2#3{%
\LT@mcol\LT@cols c{\hbox to\z@{\hss\parbox[t]\LTcapwidth{%
\sbox\@tempboxa{#1{#2 --- }#3}%
\ifdim\wd\@tempboxa>\hsize
#1{#2 --- }#3%
\else
\hbox to\hsize{\hfil\box\@tempboxa\hfil}%
\fi
\endgraf\vskip\baselineskip}%
\hss}}}
\makeatother
%%--------------------------------------------------
%% set global styles that get reset by \mainmatter
\newcommand{\setglobalstyles}{
\counterwithout{footnote}{chapter}
\counterwithout{table}{chapter}
\counterwithout{figure}{chapter}
\renewcommand{\chaptername}{}
\renewcommand{\appendixname}{Annex }
}
%%--------------------------------------------------
%% change list item markers to number and em-dash
\renewcommand{\labelitemi}{---\parabullnum{Bullets1}{\labelsep}}
\renewcommand{\labelitemii}{---\parabullnum{Bullets2}{\labelsep}}
\renewcommand{\labelitemiii}{---\parabullnum{Bullets3}{\labelsep}}
\renewcommand{\labelitemiv}{---\parabullnum{Bullets4}{\labelsep}}
%%--------------------------------------------------
%% set section numbering limit, toc limit
\maxsecnumdepth{subparagraph}
\setcounter{tocdepth}{1}