-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathpgnumchapter_nums.sty
67 lines (57 loc) · 2.87 KB
/
pgnumchapter_nums.sty
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
% from report.cls
% modified the pagestyle to fancy so that page numbers print in the
% upper left corner on pages with new chapters
% Modified the chapter titles to only print the chapter title
% Modified the first page of the chapter to start printing at the top of the page
\renewcommand\chapter{\if@openright\cleardoublepage\else\clearpage\fi
\pagestyle{fancy}%
\global\@topnum\z@
\@afterindentfalse
\secdef\@chapter\@schapter}
\def\@chapter[#1]#2{\ifnum \c@secnumdepth >\m@ne
\refstepcounter{chapter}%
\typeout{\@chapapp\space\thechapter.}%
\addcontentsline{toc}{chapter}%
{\protect\numberline{\thechapter}#1}%
\else
\addcontentsline{toc}{chapter}{#1}%
\fi
\ifnum\value{chapter}=1 %% begin chapter 1 with arabic numbers on page number 1
\pagenumbering{arabic}
\fi
\chaptermark{#1}%
\addtocontents{lof}{\protect\addvspace{10\p@}}%
\addtocontents{lot}{\protect\addvspace{10\p@}}%
\if@twocolumn
\@topnewpage[\@makechapterhead{#2}]%
\else
\@makechapterhead{#2}%
\@afterheading
\fi}
\def\@makechapterhead#1{%
% \vspace*{50\p@}%
{\parindent \z@ \raggedright \normalfont
\ifnum \c@secnumdepth >\m@ne
% uncomment 9/4 below
\normalsize\bfseries \@chapapp\space \thechapter %%% this prints "Chapter N"
%%% we are only printing the chapter name
\par\nobreak
% \vskip 20\p@
\fi
\interlinepenalty\@M
\normalsize \bfseries #1\par\nobreak
\vskip 40\p@
}}
%this text is from report.cls - to change the size of the subsection headings so they aren't giant.
\renewcommand\section{\@startsection {section}{1}{\z@}%
{-3.5ex \@plus -1ex \@minus -.2ex}%
{2.3ex \@plus.2ex}%
{\normalfont\normalsize\bfseries}}
\renewcommand\subsection{\@startsection{subsection}{2}{\z@}%
{-3.25ex\@plus -1ex \@minus -.2ex}%
{1.5ex \@plus .2ex}%
{\normalfont\normalsize\bfseries}}
\renewcommand\subsubsection{\@startsection{subsubsection}{3}{\z@}%
{-3.25ex\@plus -1ex \@minus -.2ex}%
{1.5ex \@plus .2ex}%
{\normalfont\normalsize\bfseries}}