1 \NeedsTeXFormat{LaTeX2e}
2 \ProvidesPackage{myclass}[]
4 %% Just use the original class and pass the options
5 \LoadClassWithOptions{report}
7 % Place page number at the outer foot edge of content pages
8 \usepackage[pagestyles]{titlesec}
9 \newpagestyle{mystyle}{\setfoot[\thepage][][]{}{}{\thepage}}
12 \renewcommand{\baselinestretch}{1.2}
13 \newcommand{\beforetitle}{}
14 \newcommand{\publisherlogos}{}
20 % Customize the titlepage: remove the date, place the publisher name, and
21 % load a specific file for the verso page, containing some legal notices
27 \def\titlerecto{\begin{titlepage}%
33 {\LARGE \@title \par}%
37 \begin{tabular}[t]{c}%
41 {\large \DBKpublisheraddress \par}
43 {\large \DBKpublishername \par}%
50 \def\titlepagefile{titlepg.input.tex}
51 \IfFileExists{\titlepagefile}{\input{\titlepagefile}}{}
54 % We have specified @openright to allow the chapters to start in
55 % either page (recto or verso), but we don't want that behavior for
56 % parts - The part heading should start in the right page (recto)
59 % When a \part clears the preceding page, we don't want the page
60 % number in it either.
64 \thispagestyle{empty}%
68 \null\newpage\thispagestyle{empty}%
73 \def\@endpart{\vfil\newpage}
75 % Allow line break on hyphen (-) in URLs, to make sure long URLs in
76 % footnotes do not pass out of the margins.
77 \usepackage[hyphens]{url}
79 \newenvironment{colophon}{
81 % FIXME change when page size changes, use {x}{x*1.2}
83 % Note, these numbers are not correct any more for the sizes mentioned:
84 % \fontsize{6.5}{7.8}\selectfont % fits in one 4.25x6.875" pocket size page
85 % \fontsize{7.5}{9}\selectfont % fits in one 5.06x7.71" size page
86 % \fontsize{9.1}{10.92}\selectfont % fits in one 5.5x8.5" digest size page
88 \fontsize{8.2}{9.84}\selectfont % fits in one 6x9'' size page
89 \setlength{\parskip}{0.5em} %
90 \setlength{\parindent}{0pt} %
94 \titleformat{\chapter}{\huge}{\thechapter.}{20pt}{\hyphenpenalty=10000 \Huge}
95 \titleformat{\section}{\Large}{\thesection}{1em}{}
96 \titleformat{\subsection}{\large}{\thesubsection}{1em}{}
97 %% \titleformat{\paragraph}{\normalsize}{\theparagraph}{1em}{}
98 %% \titleformat{\subparagraph}{\normalsize}{\thesubparagraph}{1em}{}
100 \usepackage{titletoc}
102 % indented subsection (in toc)
104 [0.0cm] % left margin
105 {\vskip 0.5em} % above code
107 {\Large\thecontentslabel\quad}%
109 {\Large} % unnumbered format
110 {\hfill \contentspage \vskip 0.2em} % filler-page-format, e.g dots
113 % indented subsection (in toc)
114 \titlecontents{chapter}
115 [0.0cm] % left margin
118 {\large\thecontentslabel.\quad}%
120 {\large} % unnumbered format
121 {\hfill \contentspage} % filler-page-format, e.g dots
123 % We have many short chapters. Avoid them all starting on right-side
124 % pages, as it wastes too much space
125 \let\cleardoublepage\clearpage