-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathucdavisthesis.dtx
executable file
·2333 lines (2331 loc) · 88.9 KB
/
ucdavisthesis.dtx
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
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
% \iffalse meta-comment
%
% ucdavisthesis.dtx
%
% Copyright (C) Copyright 2007, 2008, 2009, 2010 by Ryan Scott
%
% Adapted from UCLA THESIS/DISSERTATION CLASS -- for LaTeX version 2e
% (C) Copyright 1995 by John Heidemann.
% Taken from UCLA THESIS/DISSERTATION CLASS (version 0.94 BETA, 5/23/91)
% (C) Copyright 1988 Richard B. Wales. All Rights Reserved.
% by Richard B. Wales.
% Taken from DISSERTATION style (1/10/86)
% by Dorab Patel and Eduardo Krell
%
% Additional features/ideas taken from ucd_dissertation_template.tex
% A file from the UC Davis Mathematics Department
% ------------------------------------------------------------
%
% This file may be distributed and/or modified under the
% conditions of the LaTeX Project Public License, either
% version 1.2 of this license or (at your option) any later
% version. The latest version of this license is in:
%
% http://www.latex-project.org/lppl.txt
%
% and version 1.2 or later is part of all distributions of
% LaTeX version 1999/12/01 or later.
%
% \fi
%
% \iffalse
%<*driver>
\ProvidesFile{ucdavisthesis.dtx}
%</driver>
%
%<class>\NeedsTeXFormat{LaTeX2e}[1999/12/01]
%<class>\ProvidesClass{ucdavisthesis}
%<*class>
[2010/03/13 v1.1 UCDavis thesis class]
%</class>
%<ucd10pt>\ProvidesFile{ucdthesis10.clo}%
%<ucd10pt> [2009/02/22 v1.0 ucdavisthesis class 10pt size option]
%<ucd11pt>\ProvidesFile{ucdthesis11.clo}%
%<ucd11pt> [2009/02/22 v1.0 ucdavisthesis class 11pt size option]
%<ucd12pt>\ProvidesFile{ucdthesis12.clo}%
%<ucd12pt> [2009/02/22 v1.0 ucdavisthesis class 12pt size option]
%<ucd13pt>\ProvidesFile{ucdthesis13.clo}%
%<ucd13pt> [2009/02/22 v1.0 ucdavisthesis class 13pt size option]
%
%<*driver>
\documentclass{ltxdoc}
%\EnableCrossrefs
% \DisableCrossrefs
% \CodelineIndex %codelineindex or pageindex, not both
% \PageIndex
\RecordChanges
\begin{document}
\DocInput{ucdavisthesis.dtx}
\end{document}
%</driver>
% \fi
%
% \CheckSum{3036}
%
%% \CharacterTable
%% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
%% Lower-case \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
%% Digits \0\1\2\3\4\5\6\7\8\9
%% Exclamation \! Double quote \" Hash (number) \#
%% Dollar \$ Percent \% Ampersand \&
%% Acute accent \' Left paren \( Right paren \)
%% Asterisk \* Plus \+ Comma \,
%% Minus \- Point \. Solidus \/
%% Colon \: Semicolon \; Less than \<
%% Equals \= Greater than \> Question mark \?
%% Commercial at \@ Left bracket \[ Backslash \\
%% Right bracket \] Circumflex \^ Underscore \_
%% Grave accent \` Left brace \{ Vertical bar \|
%% Right brace \} Tilde \~}
%
% \changes{v0.8}{2007/09/13}{Initial version. Still working out bugs.}
%
% \changes{v0.9}{2008/09/12}{First full implementation. Fixed UMI abstract and page number location.}
%
% \changes{v0.99}{2009/02/12}{Fixed prelim page numbering problem. Fixed typos in documentation.}
%
% \changes{v1.0}{2009/02/23}{Release version. UMI abstract left margin fixed. Added \texttt{\textbackslash singlespacing} and \texttt{\textbackslash committee} commands.}
%
% \changes{v1.1}{2010/03/13}{Updated Title page; committee member names appear under signature lines. Updated \texttt{\textbackslash committee} command to accept up to five committee members. Fixed \texttt{\textbackslash singlespacing} usage in example file.}
%
% \GetFileInfo{ucdavisthesis.dtx}
%
% \DoNotIndex{\{,\},\ ,\',\.,\@M,\@MM,\@@input,\@Alph,\@alph,\@addtoreset,\@arabic}
% \DoNotIndex{\@badmath,\@centercr,\@cite}
% \DoNotIndex{\@dotsep,\@empty,\@float,\@gobble,\@gobbletwo,\@ignoretrue}
% \DoNotIndex{\@listI,\@listi,\@listii,\@listiii,\@listiiv,\@listv,\@listvi}
% \DoNotIndex{\@latex@warning,\@input,\@ixpt,\@m,\@minus,\@mkboth}
% \DoNotIndex{\@ne,\@nil,\@nomath,\@openbib@code,\@plus,\@roman,\@Roman,\@set@topoint}
% \DoNotIndex{\@tempboxa,\@tempcnta,\@tempdima,\@tempdimb}
% \DoNotIndex{\@tempswafalse,\@tempswatrue,\@viipt,\@viiipt,\@vipt}
% \DoNotIndex{\@vpt,\@warning,\@xiipt,\@xipt,\@xivpt,\@xpt,\@xviipt}
% \DoNotIndex{\@xxpt,\@xxvpt,\\,\ ,\addpenalty,\addtolength,\addvspace}
% \DoNotIndex{\advance,\addcontentsline,\ast,\baselinestretch,\begin,\begingroup}
% \DoNotIndex{\bfseries,\bigskip,\bgroup,\box,\bullet}
% \DoNotIndex{\cdot,\cite,\CodelineIndex,\cr,\day,\DeclareOption}
% \DoNotIndex{\def,\DisableCrossrefs,\divide,\DocInput,\documentclass}
% \DoNotIndex{\DoNotIndex,\egroup,\ifdim,\else,\fi,\em,\endtrivlist}
% \DoNotIndex{\EnableCrossrefs,\end,\end@dblfloat,\end@float,\endgroup}
% \DoNotIndex{\endlist,\everycr,\everypar,\ExecuteOptions,\expandafter}
% \DoNotIndex{\fbox,\footnotesize}
% \DoNotIndex{\filedate,\filename,\fileversion,\fontsize,\framebox,\gdef}
% \DoNotIndex{\global,\halign,\hangindent,\hbox,\hfil,\hfill,\hrule}
% \DoNotIndex{\hsize,\hskip,\hspace,\hss,\if@tempswa,\ifcase,\or,\fi,\fi}
% \DoNotIndex{\ifhmode,\ifvmode,\ifnum,\iftrue,\ifx,\fi,\fi,\fi,\fi,\fi}
% \DoNotIndex{\input}
% \DoNotIndex{\jobname,\kern,\labelsep,\labelwidth,\leftmargin,\leavevmode,\let,\leftmark}
% \DoNotIndex{\list,\llap,\long,\m@ne,\m@th,\mark,\markboth,\markright}
% \DoNotIndex{\month,\newcommand,\newcounter,\newenvironment}
% \DoNotIndex{\NeedsTeXFormat,\newdimen,\newif}
% \DoNotIndex{\newlength,\newpage,\nobreak,\noindent,\normalsize,\normalfont,\null,\number}
% \DoNotIndex{\numberline,\OldMakeindex,\OnlyDescription,\p@}
% \DoNotIndex{\parindent,s\pagestyle,\par,\paragraph,\paragraphmark,\parfillskip}
% \DoNotIndex{\penalty,\PrintChanges,\PrintIndex,\ProcessOptions}
% \DoNotIndex{\protect,\ProvidesClass,\raggedbottom,\raggedright,\quad}
% \DoNotIndex{\refstepcounter,\relax,\renewcommand,\RequirePackage}
% \DoNotIndex{\rightmargin,\rightmark,\rightskip,\rlap,\rmfamily}
% \DoNotIndex{\secnumdepth, \secdef,\selectfont,\setbox,\setcounter,\setlength}
% \DoNotIndex{\settowidth,\sfcode,\skip,\sloppy,\slshape,\space}
% \DoNotIndex{\symbol,\the,\textsc,\textwidth,\thechapter,\thepage}
% \DoNotIndex{\thispagestyle,\trivlist,\typeout,\tw@}
% \DoNotIndex{\undefined,\uppercase,\usecounter,\usefont,\usepackage}
% \DoNotIndex{\vfil,\vfill,\viiipt,\viipt,\vipt,\vskip,\vspace}
% \DoNotIndex{\wd,\xiipt,\year,\z@}
%
% \title{The \textsf{ucdavisthesis} class\thanks{This document
% corresponds to \textsf{ucdavisthesis}~\fileversion,
% dated~\filedate.}}
% \author{Ryan Scott \\ \texttt{[email protected]}}
%
% \date{Printed \today}
%
% \maketitle
%
% \tableofcontents
%
% \section{Introduction} \label{sec.intro}
%
% The \textsf{ucdavisthesis} class is a \LaTeXe{} class that allows you to create a dissertation or thesis which conforms to UC Davis formatting requirements as of 2010. The output document has the necessary preliminary pages, margins, page number placement, etc. This class also provides most of the macros available in the |report| class, allowing for chapters, sections, etc. Please check the Graduate Studies web page (http://gradstudies.ucdavis.edu/students/filing.html) for any changes or updates. For general help with \LaTeX, please check out the \LaTeX FAQ (http://www.tex.ac.uk/faq), the CTAN web site (http://www.ctan.org/), or the comp.text.tex Google Group (http://groups.google.com/group/comp.text.tex).
%
% This manual is typeset according to the conventions of the \LaTeX{} \textsc{docstrip} utility which enables the automatic extraction of the \LaTeX{} macro source files.
%
%
% \section{Usage} \label{sec.usage}
% To create a dissertation or thesis which conforms to UC Davis requirements load the class with
% \begin{quote}
% |\documentclass|\oarg{class-options}|{ucdavisthesis}|
% \end{quote}
% at the beginning of your your \LaTeXe{} source file. The \meta{class-options}
% are entered as a comma separated list (no spaces). They are described in detail in
% Section~\ref{sec.options}. The other commands (macros) necessary to put
% together a complete document are explained in Section~\ref{sec.commands}.
%
% Please look through the |Sample_Dissertation_Main.tex| file and its subfiles for the proper macro order and helpful suggestions for formatting and organization of your thesis.
%
% \section{Class Options} \label{sec.options}
% The \textsf{ucdavisthesis} class is in itself an alteration of the standard \texttt{report} class, thus it keeps most of its class options except those options that would make the document non-conforming and aren't likely to be used for drafts (e.g., |twocolumn|, |notitlepage| and |a4paper|). If you find yourself wanting \texttt{report} features that are not available, please let me know.
%
% The possible options for the \textsf{ucdavisthesis} class are (default values are in angle brackets):
% \begin{description}
% \item[\texttt{MA\quad MS\quad ME\quad $\langle$PhD$\rangle$\quad DEngr}]\ \\ This option formats the title pages to conform to the requirements for a particular degree.
% \item[\texttt{single\quad $\langle$double$\rangle$}]\ \\ Sets the document line spacing. NOTE: single line spacing is non-conforming to the UCD format. However, even when using |double| spacing, environments like footnotes, captions and references are kept to single spacing. If there are problems with a particular environment becoming double spaced when using certain packages (e.g., \textsf{natbib} or \textsf{chapterbib}), see the |\singlespacing| command.
% \item[\texttt{twoside}] $\langle$\textit{false}$\rangle$\\ Two-sided printing (for a duplex printer). Adjusts margins and placement of page numbers and headers appropriately. NOTE: two-sided printing is non-conforming to the UCD Format.
% \item[\texttt{openright\quad $\langle$openany$\rangle$}]\ \\ This option only makes sense when using the \texttt{twoside} option. \texttt{openright} forces chapters to begin on odd (right-hand) pages only. The default, \texttt{openany} will start a chapter on the next page, whether it is even or odd.
% \item[\texttt{draft\quad draftcls\quad $\langle$final$\rangle$}]\ \\ \textsf{ucdavisthesis} provides two draft modes as well as the normal final mode. The \texttt{draft} and \texttt{draftcls} options provide additional information in the running header, including the text ``DRAFT'', the time and date, etc. Additionally, \texttt{draft} puts every package used in the document into draft mode (disabling rendering of figures for most graphics packages), while \texttt{draftcls} confines the draft mode behavior to just the class file.
% \item[\texttt{nofigureslist}] $\langle$\textit{false}$\rangle$\\ Suppress printing of the List of Figures.
% \item[\texttt{notableslist}] $\langle$\textit{false}$\rangle$\\ Suppress printing of the List of Tables.
% \item[\texttt{nohyphenatetitles\quad $\langle$hyphenatetitles$\rangle$}]\ \\ Choose whether to hyphenate section (and subsection...) titles.
% \item[\texttt{10pt\quad 11pt\quad $\langle$12pt$\rangle$\quad 13pt}]\ \\ Font size to use in the body of document (i.e., normalsize). Appropriate font sizes are chosen for the usual array of text size macros (e.g., |\small|, |\large|, |\Large|, etc.). Any of the four size options are acceptable according to the UCD Format.
% \end{description}
%
% \section{Class Commands} \label{sec.commands}
% This class file provides many commands that must be used to correctly format your dissertation or thesis. Some are self explanatory, others more obscure. I try to describe them all below.
%
% \subsection{Preliminary Page Commands}
% Use the following commands to produce all of the preliminary pages (e.g., title page, abstract, etc.). Theses should be used before the |\makeintropages{}| command is issued.
%
% \DescribeMacro{\title} This command sets the dissertation/thesis title. Formatting commands are allowed in the argument (e.g., |\textit{}|). The title must always be specified.
% \begin{quote}
% |\title|\marg{title}
% \end{quote}
%
%
% \DescribeMacro{\author} This command sets the dissertation/thesis author. Only one author is allowed. The author must always be specified.
% \begin{quote}
% |\author|\marg{author's name}
% \end{quote}
%
%
% \DescribeMacro{\authordegrees} Specify the author's previous degrees on the \textsc{Title Page}. Separate entries with the end line command |\\ |. The author's degrees must always be specified.
% \begin{quote}
% |\authordegrees|\marg{list of degrees}
% \end{quote}
% For example:
% \begin{quote}
% |\authordegrees||{B.S. (University of California, Davis) 1978||\\|
% | M.S. (University of California, Berkeley) 1980}|
% \end{quote}
%
%
% \DescribeMacro{\officialmajor} Set the official major name (in the degree title).
% e.g., Electrical and Computer Engineering, Applied Science, Russian, or Entomology.
% The official name of your major must always be specified.
% \begin{quote}
% |\officialmajor|\marg{major's name}
% \end{quote}
%
%
% \DescribeMacro{\graduateprogram} Set the graduate program name.
% It is only used on the UMI abstract page. The graduate program name may be
% the same as the official major.
% \begin{quote}
% |\graduateprogram|\marg{program name}
% \end{quote}
%
%
% \DescribeMacro{\thesis} Set the document type to |Thesis|, and the degree name to the command's argument. This command is normally not needed, since an |MA| or |MS| option to |\documentclass| will do the same thing in all standard situations.
%
%
% \DescribeMacro{\dissertation} Set the document type to |Dissertation|, and the degree name to the command's argument. This command is normally not needed, since a |PhD| or |DEngr| option to |\documentclass| will do the same thing in all standard situations.
%
%
% \DescribeMacro{\degreemonth} Set the month in which the degree will be \textbf{conferred}, typically, March, June, September or December. Default is the current month
% (this may not be correct!).
% \begin{quote}
% |\degreemonth|\marg{month}
% \end{quote}
%
%
% \DescribeMacro{\degreeyear} Set the year in which the degree will be conferred.
% Default is the current year.
% \begin{quote}
% |\degreeyear|\marg{year}
% \end{quote}
%
%
% \DescribeMacro{\committee} This command will place the committee members' names under the approval lines. ``Chair'' should appear with the first member's name. There may be up to five (seriously?) committee members. Leave unused arguments empty. Your committee member names must be specified.
% \begin{quote}
% |\committee|\marg{mem 1}\marg{mem 2}\marg{mem 3}\marg{mem 4}\marg{mem 5}
% \end{quote}%
%
%
% \DescribeMacro{\copyrightyear} Set the year which appears in the copyright
% notice. Default is the degree year (see above).
% \begin{quote}
% |\copyrightyear|\marg{year}
% \end{quote}
%
%
% \DescribeMacro{\nocopyright} Don't include a copyright notice at all. No page
% will be produced in its place. Default behavior is to include a copyright page.
% \begin{quote}
% |\nocopyright|
% \end{quote}
%
%
% \DescribeMacro{\titlesize} Print the document title (on the \textsc{Title} and
% \textsc{Abstract} pages) at a particular size. Default is |\Large|
% (17-point when using 12pt option). Although any \LaTeX{} type size name will be
% accepted, the only other non-default value likely to give satisfactory
% results is |\LARGE| (20-point when using 12pt option).
% \begin{quote}
% |\titlesize|\marg{size name}
% \end{quote}
%
%
% \DescribeMacro{\dedication} The argument's text is used as the dedication (in a |\center| environment) on the \textsc{Dedication} page. Default is not to have a dedication.
% \begin{quote}
% |\dedication|\marg{text}
% \end{quote}
%
%
% \DescribeMacro{\acknowledgments} The argument's text is used for the
% \textsc{Acknowledgments} page. Default is not to have an \textsc{Acknowledgments} page.
% \begin{quote}
% |\acknowledgments|\marg{text}
% \end{quote}
%
%
% \DescribeMacro{\abstract} The argument's text is used as the dissertation/thesis
% abstract. You must include an abstract. There is no limit on length.
% \begin{quote}
% |\abstract|\marg{text}
% \end{quote}
%
%
% \DescribeMacro{\makeintropages} Generate the introductory pages in the proper
% sequence. This command is placed just before your first chapter or section.
%
%
% \subsection{UMI Abstract Formatting}
% This is usually only used in the final preparation of the dissertation.
%
%
% \DescribeMacro{\UMIabstract} The text in the argument is used as the UMI abstract.
% Otherwise, it defaults to using the text from |\abstract| (hence the square brackets).
% However, the UMI abstract can't exceed 350 words in length. The UMI abstract is separate
% from the dissertation abstract and should NOT be included as part of the submitted
% dissertation. Normally this command is called at the end of the main file,
% just before |\end{document}|. The command is ignored if |twoside| is enabled.
% \begin{quote}
% |\UMIabstract|[$\langle$\textit{text}$\rangle$] $\Leftarrow\,$\textbf{Note: square brackets}
% \end{quote}
%
%
% \subsection{Text Formatting Commands}
% These are commands you can use to customize the fonts and font sizes used in the headings. A command is also provided to produce single spacing in certain environments.
%
%
% \DescribeMacro{\singlespacing} Set the line spacing to single spacing. Usually |\singlespacing|
% is required with packages that modify or redefine particular environments (i.e., |thebibliography|).
% For example, if using the |natbib| package, use the command:
% \begin{quote}
% |\renewcommand{\bibfont}{\singlespacing}|
% \end{quote}
% The |\bibfont| command will make the text \emph{within} references single spaced while
% there will still be double spacing between each reference. This works even if the
% |chapterbib| package with the |sectionbib| option is used.
%
%
%
% \DescribeMacro{\chapternamesize} Set the size of the chapter name (i.e, `Chapter').
% Default size is |\Huge|.
%
%
% \DescribeMacro{\chapternamefont} Set the font of the chapter name (i.e, `Chapter').
% Default font is |\bfseries|.
%
%
% \DescribeMacro{\chaptertitlesize} Set the size of the chapter title.
% Default size is |\huge|.
%
%
% \DescribeMacro{\chaptertitlefont} Set the font of the chapter title.
% Default font is |\bfseries|.
%
%
% \DescribeMacro{\secfontsize} Set the font type and size of the section title.
% Default is |\bfseries\Large|.
%
%
% \DescribeMacro{\subsecfontsize} Set the font type and size of the subsection title.
% Default is |\bfseries\large|.
%
%
% \DescribeMacro{\ssubsecfontsize} Set the font type and size of the subsubsection title.
% Default is |\bfseries\normalsize|.
%
%
% \StopEventually
%
% \section{Implementation and Source Code Listing for the Class File}
% This section deals with the package source code. Please, do not read this unless you really need it or have some strange fascination with inspecting \LaTeX{} internals (like me). The comments are very short and they typically just tell you where you are. If you are experiencing any problems when testing this class, please send me an email and I will try to solve it.
%
% Also, please feel free to send me emails about feature requests, improvements to the code, or changes to the formatting requirements.
% \bigskip
%
% Require \texttt{ifthen} package to process options.
% \begin{macrocode}
%<*class>
\RequirePackage{ifthen}
% \end{macrocode}
%
% A command to keep track of the font size option chosen.
% \begin{macrocode}
\newcommand\@ptsize{}
% \end{macrocode}
%
% Define some booleans to control class options like draft mode, list of figures, etc.
% \begin{macrocode}
\newif\if@openright % Set to true if openright option set
\newif\if@draft % Set to true if draft option set
\@draftfalse
\newif\if@draftcls % Set to true if draft class option set
\@draftclsfalse
\newif\if@figures
\@figurestrue % Make List of Figures
\newif\if@tables
\@tablestrue % Make List of Tables
% \end{macrocode}
%
% Some booleans to keep track of where we are in the document processing.
% \begin{macrocode}
\newif\if@prelimpages % Set to false after producing preliminary pages
\@prelimpagestrue
% \end{macrocode}
% \subsection{Title Page Macros}
% Define the title page macros.
% \begin{macrocode}
\def\@title{NO TITLE!?!}
\def\@author{NO AUTHOR!?!}
\def\@authordegrees{NO DEGREES!?!}
\def\@memberone{NAME!?!}\def\@membertwo{NAME!?!}\def\@memberthree{NAME!?!}
\def\@memberfour{}\def\@memberfive{}
\def\@titlesize{\large}
\def\@titleskip{\bigskip}
\def\@alttitleskip{\medskip}
\renewcommand{\title}[1]{\def\@title{#1}}
\renewcommand{\author}[1]{\def\@author{#1}}
\newcommand{\titlesize}[1]{\def\@titlesize{#1}}
\newcommand{\authordegrees}[1]{\def\@authordegrees{#1}}
\newcommand{\committee}[5]
{\def\@memberone{#1}\def\@membertwo{#2}\def\@memberthree{#3}
\def\@memberfour{#4}\def\@memberfive{#5}
}
% \end{macrocode}
%
% The following commands set the official major and graduate program.
% \begin{macrocode}
\def\@officialmajor{NO OFFICIAL MAJOR!?!}
\newcommand{\officialmajor}[1]{\def\@officialmajor{#1}}
\def\@graduateprogram{NO GRADUATE PROGRAM!?!}
\newcommand{\graduateprogram}[1]{\def\@graduateprogram{#1}}
% \end{macrocode}
%
% The following commands will process the |MA|, |MS|, |ME|, |PhD|, or |DEngr|
% option. (The default is |PhD|.)
% \begin{macrocode}
\newcommand{\thesis}[1]
{\def\@thesisname{thesis}
\def\@Thesisname{Thesis}
\def\@degreename{#1}
}
\newcommand{\dissertation}[1]
{\def\@thesisname{dissertation}
\def\@Thesisname{Dissertation}
\def\@degreename{#1}
}
\dissertation{Doctor of Philosophy} % default
% \end{macrocode}
%
% The following commands set the year in which the degree will be
% awarded, as well as the year of copyright.
% \begin{macrocode}
\def\@degreeyear{\number\year} % default is current year
\def\@degreemonth{\ifcase\month\or
January\or February\or March\or April\or May\or June\or
July\or August\or September\or October\or November\or December\fi}
\def\@copyrightyear{\number\year} % default is current year
\newif\if@cyrset
\@cyrsetfalse
\newcommand{\degreeyear}[1]
{\def\@degreeyear{#1}\if@cyrset\else\def\@copyrightyear{#1}\fi}
\newcommand{\degreemonth}[1]{\def\@degreemonth{#1}}
\newcommand{\copyrightyear}[1]{\def\@copyrightyear{#1}\@cyrsettrue}
% \end{macrocode}
% \subsection{Option Declarations}
% Now, we declare the class options.
% \begin{macrocode}
\DeclareOption{PhD}{} % default -- nothing more to do
\DeclareOption{DEngr}{\dissertation{Doctor of Engineering}}
\DeclareOption{MA}{\thesis{Master of Arts}}
\DeclareOption{MS}{\thesis{Master of Science}}
\DeclareOption{ME}{\thesis{Master of Engineering}}
%
\DeclareOption{10pt}{\renewcommand\@ptsize{10}}
\DeclareOption{11pt}{\renewcommand\@ptsize{11}}
\DeclareOption{12pt}{\renewcommand\@ptsize{12}} % default size
\DeclareOption{13pt}{\renewcommand\@ptsize{13}}
%
\DeclareOption{nofigureslist}{\@figuresfalse}
\DeclareOption{notableslist}{\@tablesfalse}
\DeclareOption{openright}{\@openrighttrue}
\DeclareOption{openany}{\@openrightfalse}
% \end{macrocode}
%
% \subsubsection{Line Spacing Definitions}
% The following commands will process the |single| or |double| option.
% (The default is |double|.) This controls inter-line spacing.
% \begin{macrocode}
\def\@singlespacing{1.0}
\def\@doublespacing{1.5} % see LaTeX manual for explanation of value
\let\@spacing=\@doublespacing
\newcommand{\@titlespacing}{1.2} % Spacing to use in chapter and section titles
\DeclareOption{single}{\let\@spacing=\@singlespacing%
\let\@titlespacing=\@singlespacing}
\DeclareOption{double}{\let\@spacing=\@doublespacing}
% \end{macrocode}
%
% The following definitions provide a way to get single spacing in some types
% of environments like |thebibliography|. Just resetting |\baselinestretch|
% does not seem to work with some of the packages like |natbib|. The code is
% taken from |setspace.sty| version 6.7 by Geoffrey Tobin.
%
% Line spacing command
% \begin{macrocode}
\newcommand{\setstretch}[1]{%
\def\baselinestretch{#1}%
\@currsize}%
% \end{macrocode}
%
% Allow users to modify the |\SetSinglespace| value to something slightly
% more or less than 1 to help with unusual font heights (when compared to
% their point size).
%
% \begin{macrocode}
\newcommand{\SetSinglespace}[1]{%
\def\setspace@singlespace{#1}}
\SetSinglespace{1}
% \end{macrocode}
%
% This is the command to call when you want single spacing in a particular
% environment.
%
% \begin{macrocode}
\newcommand{\singlespacing}{%
\setstretch {\setspace@singlespace}% normally 1
\vskip \baselineskip} % Correction for coming into |\singlespacing|
% \end{macrocode}
%
% Modification of the \LaTeX{} command |\@setsize| The meanings of the
% arguments to |\@setsize| appear to be (whatever these may signify):
% current size; font baselineskip; ignored (!); and font size.
%
% \begin{macrocode}
\def\@setsize#1#2#3#4{%
\@nomath#1%
\let\@currsize#1%
\baselineskip #2%
\baselineskip \baselinestretch\baselineskip
\parskip \baselinestretch\parskip
\setbox\strutbox \hbox{%
\vrule height.7\baselineskip
depth.3\baselineskip
width\z@}%
\skip\footins \baselinestretch\skip\footins
\normalbaselineskip\baselineskip#3#4}
% \end{macrocode}
%
% \subsubsection{Mark Overfull hboxes}
% Overfull hboxes are marked.
% \begin{macrocode}
\DeclareOption{draft}{\setlength{\overfullrule}{5pt}\@drafttrue\@draftclstrue}
\DeclareOption{draftcls}{\setlength{\overfullrule}{5pt}\@draftfalse\@draftclstrue}
\DeclareOption{oneside}{\@twosidefalse \@mparswitchfalse}
\DeclareOption{twoside}{\@twosidetrue \@mparswitchtrue}
\DeclareOption{final}{\setlength{\overfullrule}{0pt}\@draftfalse\@draftclsfalse}
% \end{macrocode}
%
% Provide Chapter and Section title font and size control
% \begin{macrocode}
\def\@chapternamesize{\Huge}
\newcommand{\chapternamesize}[1]{\def\@chapternamesize{#1}}
\def\@chapternamefont{\bfseries}
\newcommand{\chapternamefont}[1]{\def\@chapternamefont{#1}}
\def\@chaptertitlesize{\huge}
\newcommand{\chaptertitlesize}[1]{\def\@chaptertitlesize{#1}}
\def\@chaptertitlefont{\bfseries}
\newcommand{\chaptertitlefont}[1]{\def\@chaptertitlefont{#1}}
\def\@secfontsize{\bfseries\Large}
\newcommand{\secfontsize}[1]{\def\@secfontsize{#1}}
\def\@subsecfontsize{\bfseries\large}
\newcommand{\subsecfontsize}[1]{\def\@subsecfontsize{#1}}
\def\@ssubsecfontsize{\bfseries\normalsize}
\newcommand{\ssubsecfontsize}[1]{\def\@ssubsecfontsize{#1}}
% \end{macrocode}
%
% Provide way to make hyphenating titles optional.
% \begin{macrocode}
\newboolean{hyphenatetitles}
\setboolean{hyphenatetitles}{true}
\DeclareOption{nohyphenatetitles}{\setboolean{hyphenatetitles}{false}}
\DeclareOption{hyphenatetitles}{\setboolean{hyphenatetitles}{true}}
% \end{macrocode}
%
% Set default options and then execute the options.
% \begin{macrocode}
\ExecuteOptions{double,12pt,oneside,final,openany}
\ProcessOptions\relax
% \end{macrocode}
%
% Redefine how |\cleardoublepage| works so that it behaves differently when the |twoside|
% option is chosen.
% \begin{macrocode}
\renewcommand{\cleardoublepage}{\clearpage%
\if@twoside
\ifodd\c@page
\else
\null\thispagestyle{empty}\newpage% make a blank page
\fi
\fi}
% \end{macrocode}
%
% \subsection{Page Layout}
% UCD format requires only letter paper size be used.
% \begin{macrocode}
\setlength{\paperheight}{11in}
\setlength{\paperwidth}{8.5in}
% \end{macrocode}
%
% All margin dimensions measured from a point one inch from top and side
% of page (standard \TeX{}). A little extra (0.1 in) is added on each side
% to ensure that the text will fall within the thesis margin limits
% even if photo-copying enlarges or misaligns it slightly.
%
% According to the UCD format, margins are to be 1.5 inch left,
% 1 inch top, right, and bottom with the page numbers allowed
% to be outside these margins.
%
% \subsubsection{Side Margins}
% \begin{macrocode}
\if@twoside % twoside is non-conforming to UC format
\setlength{\oddsidemargin}{0.6in} % these are added to
\setlength{\evensidemargin}{0.1in} % LaTeX's 1 inch left margin
\else % Note that \oddsidemargin = \evensidemargin
\setlength{\oddsidemargin}{0.6in} % these are added to LaTeX's
\setlength{\evensidemargin}{0.6in} % 1 inch left margin.
\fi
% \end{macrocode}
%
% \subsubsection{Vertical Spacing}
% Top of page:
% |\topmargin| is the nominal distance from \LaTeX{}'s 1 inch top margin to the top of the box containing the running head. |\headheight| is the height of the box containing the running head. |\headsep| is the space between the running head and text.
%
% \begin{macrocode}
\setlength{\topmargin}{-0.6in}
\setlength{\headheight}{0.2in}
\setlength{\headsep}{0.5in}
% \end{macrocode}
%
% Bottom of page:
% |\footskip| is the distance from baseline of box containing foot to baseline of last line of text.
% \begin{macrocode}
\setlength{\footskip}{0.6in}
% \end{macrocode}
%
% \subsubsection{Dimensions of Text}
% |\textheight| is the height of the text (including footnotes and figures, excluding running header and footer). |\textwidth| is the width of text line.
% \begin{macrocode}
\setlength{\textheight}{8.8in}
\setlength{\textwidth}{5.8in}
% \end{macrocode}
%
% A |\raggedbottom| command causes `ragged bottom' pages: pages set to
% natural height instead of being stretched to exactly |\textheight|.
%
% \subsubsection{Input Font Size Info}
% The appropriate |ucdthesis1x.clo| file defines things that depend on the type size.
% In order to meet the UCD requirements, font size must be between 10
% and 13 points.
%
% \begin{macrocode}
\input{ucdthesis\@ptsize.clo} % \@ptsize is determined by the class option
% \end{macrocode}
%
% \subsection{Lists}
%
% \subsubsection{Enumerate}
% Enumeration is done with four counters: |enumi|, |enumii|, |enumiii|
% and |enumiv|, where |enumN| controls the numbering of the $N$th level
% enumeration. The label is generated by the commands |\labelenumi|
% ... |\labelenumiv|. The expansion of |\p@enumN\theenumN| defines the
% output of a |\ref| command.
%
% \begin{macrocode}
\renewcommand\theenumi{\@arabic\c@enumi}
\renewcommand\theenumii{\@alph\c@enumii}
\renewcommand\theenumiii{\@roman\c@enumiii}
\renewcommand\theenumiv{\@Alph\c@enumiv}
\newcommand\labelenumi{\theenumi.}
\newcommand\labelenumii{(\theenumii)}
\newcommand\labelenumiii{\theenumiii.}
\newcommand\labelenumiv{\theenumiv.}
\renewcommand\p@enumii{\theenumi}
\renewcommand\p@enumiii{\theenumi(\theenumii)}
\renewcommand\p@enumiv{\p@enumiii\theenumiii}
% \end{macrocode}
%
% \subsubsection{Itemize}
% Itemization is controlled by four commands: |\labelitemi|, |\labelitemii|,
% |\labelitemiii|, and |\labelitemiv|, which define the labels of the various
% itemization levels.
%
% \begin{macrocode}
\newcommand\labelitemi{\textbullet}
\newcommand\labelitemii{\normalfont\bfseries \textendash}
\newcommand\labelitemiii{\textasteriskcentered}
\newcommand\labelitemiv{\textperiodcentered}
% \end{macrocode}
%
% \subsubsection{Verse}
% The verse environment is defined by making clever use of the
% list environment's parameters. The user types |\\| to end a line.
% This is implemented by |\let'in| |\\| equal |\@centercr|.
%
% \begin{macrocode}
\newenvironment{verse}
{\let\\\@centercr
\list{}{\itemsep \z@
\itemindent -1.5em%
\listparindent\itemindent
\rightmargin \leftmargin
\advance\leftmargin 1.5em}%
\item\relax}
{\endlist}
% \end{macrocode}
%
% \subsubsection{Quotation}
% Fills lines and indents paragraph.
%
% \begin{macrocode}
\newenvironment{quotation}
{\list{}{\listparindent 1.5em%
\itemindent \listparindent
\rightmargin \leftmargin
\parsep \z@ \@plus\p@}%
\item\relax}
{\endlist}
% \end{macrocode}
%
% \subsubsection{Quote}
% Same as quotation except no paragraph indentation.
%
% \begin{macrocode}
\newenvironment{quote}
{\list{}{\rightmargin\leftmargin}%
\item\relax}
{\endlist}
% \end{macrocode}
%
% \subsubsection{Labels}
% To change the formatting of the label, you must redefine
% |\descriptionlabel|.
% \begin{macrocode}
\newenvironment{description}
{\list{}{\labelwidth\z@ \itemindent-\leftmargin
\let\makelabel\descriptionlabel}}
{\endlist}
\newcommand*\descriptionlabel[1]{\hspace\labelsep
\normalfont\bfseries #1}
% \end{macrocode}
%
% \subsection{Other Environments}
% \subsubsection{Default Title Page}
% In the normal environments, the |titlepage| environment does nothing but
% start and end a page.
% \begin{macrocode}
\newenvironment{titlepage}
{%
\newpage
\thispagestyle{prelim}%
}%
{\newpage
\if@twoside\else
\fi
}
% \end{macrocode}
%
% \subsubsection{Array and Tabular}
% |\arraycolsep| is half the space between columns in an array environment. |\tabcolsep| is half the space between columns in a tabular environment. |\arrayrulewidth| is the width of rules in array and tabular environment. |\doublerulesep| is the space between adjacent rules in array or tabular environment.
% \begin{macrocode}
\setlength\arraycolsep{5\p@}
\setlength\tabcolsep{6\p@}
\setlength\arrayrulewidth{.4\p@}
\setlength\doublerulesep{2\p@}
% \end{macrocode}
%
% \subsubsection{Tabbing}
% |\tabbingsep| is the space used by the |\'| command (see \LaTeX{} manual).
% \begin{macrocode}
\setlength\tabbingsep{\labelsep}
% \end{macrocode}
%
% \subsubsection{Minipage}
% |\@minipagerestore| is called upon entry to a minipage environment to
% set up things that are to be handled differently inside a minipage
% environment. In the current styles, it does nothing.
% \begin{macrocode}
\skip\@mpfootins = \skip\footins
% \end{macrocode}
%
% \subsubsection{Framebox}
% |\fboxsep| is the space left between box and text by |\fbox| and |\framebox|. |\fboxrule| is the width of rules in box made by |\fbox| and |\framebox|.
% \begin{macrocode}
\setlength\fboxsep{3\p@}
\setlength\fboxrule{.4\p@}
% \end{macrocode}
%
% \subsection{Chapters and Sections}
% \subsubsection{Define Counters}
%
% |\newcounter|\marg{NEWCTR}[OLDCTR] Defines NEWCTR to be a counter, which is reset to zero when counter OLDCTR is stepped. Counter OLDCTR must already be defined.
% \begin{macrocode}
\newcounter {part}
\newcounter {chapter}
\newcounter {section}[chapter]
\newcounter {subsection}[section]
\newcounter {subsubsection}[subsection]
\newcounter {paragraph}[subsubsection]
\newcounter {subparagraph}[paragraph]
% \end{macrocode}
%
% For any counter CTR, |\theCTR| is a macro that defines the printed version of counter CTR. It is defined in terms of the following macros:
%
% |\arabic|\marg{COUNTER} : The value of COUNTER printed as an arabic numeral.
% |\roman|\marg{COUNTER} : Its value printed as a lower-case roman numeral.
% |\Roman|\marg{COUNTER} : Its value printed as an upper-case roman numeral.
% |\alph|\marg{COUNTER} : Value of COUNTER printed as a lower-case letter: 1 = a, 2 = b, etc.
% |\Alph|\marg{COUNTER} : Value of COUNTER printed as an upper-case letter: 1 = A, 2 = B, etc.
%
% \begin{macrocode}
\renewcommand \thepart {\@Roman\c@part}
\renewcommand \thechapter {\@arabic\c@chapter}
\renewcommand \thesection {\thechapter.\@arabic\c@section}
\renewcommand\thesubsection {\thesection.\@arabic\c@subsection}
\renewcommand\thesubsubsection{\thesubsection .\@arabic\c@subsubsection}
\renewcommand\theparagraph {\thesubsubsection.\@arabic\c@paragraph}
\renewcommand\thesubparagraph {\theparagraph.\@arabic\c@subparagraph}
% \end{macrocode}
%
% \subsubsection{Chapter Name}
% |\@chapapp| is initially defined to be `CHAPTER'. The |\appendix| command
% redefines it to be `APPENDIX'.
% \begin{macrocode}
\newcommand\@chapapp{\chaptername}
% \end{macrocode}
%
% |\secdef|\marg{UNSTARCMDS}\marg{STARCMDS}
%
% When defining a |\chapter| or |\section| command without using |\@startsection|, you can use |\secdef| as follows:
% \begin{quote}
% |\def\chapter|{ ... |\secdef| |\CMDA| |\CMDB| }\\
% |\def\CMDA|[\# 1]\# 2\marg{ ... } Command to define |\chapter|[...]\marg{...}\\
% |\def\CMDB|\# 1\marg{ ... } Command to define |\chapter*|\marg{...}
% \end{quote}
% \subsubsection{Part Macro}
% \begin{macrocode}
\newcommand\part{%
\if@openright
\cleardoublepage % Starts new page.
\else
\clearpage
\fi
\thispagestyle{thshead} % Page style of part page is 'thshead'
\@tempswafalse % @tempswa := false
\null\vfil % Add fil glue to center title
\bgroup \centering % BEGIN centering
\secdef\@part\@spart}
% \end{macrocode}
%
% \begin{macrocode}
\def\@part[#1]#2{\ifnum \c@secnumdepth >-2\relax % IF secnumdepth > -2
\refstepcounter{part}% % THEN step part counter
\addcontentsline{toc}{part}{\thepart\hspace{1em}#1}% add toc line
\else % ELSE add unnumbered line
\addcontentsline{toc}{part}{#1}%
\fi % End if
\markboth{}{}
\ifnum \c@secnumdepth >-2\relax % IF secnumdepth > -2
\normalsize\bfseries Part\thepart % THEN Print 'Part' and number
\par % in \normalsize bold.
\vskip 20\p@ % Add space before title.
\fi
\huge\bfseries #2\par\@endpart} % Print Title in \huge bold.
% \end{macrocode}
% Print title in |\normalsize| boldface
% \begin{macrocode}
\def\@spart#1{\normalsize\bfseries #1\par\@endpart} %
% \end{macrocode}
%
% |\@endpart| finishes the part page
% \begin{macrocode}
\def\@endpart{\vfil\newpage % End page with 1fil glue.
\if@twoside
\if@openright
\null
\thispagestyle{empty}%
\newpage
\fi
\fi
\if@tempswa % IF @tempswa = true
\twocolumn % THEN \twocolumn
\fi}
% \end{macrocode}
%
% \subsubsection{Chapter Macro}
% \begin{macrocode}
\newcommand\chapter{%
\if@openright\cleardoublepage\else\clearpage\fi % Starts new page.
\if@prelimpages % Are we on preliminary pages?
\thispagestyle{prelim} % if yes, format for preliminary pages
\else
\thispagestyle{thshead} % Otherwise it is the main text
\fi
\global\@topnum\z@ % Prevents figures at top of first page in chapter.
\@afterindentfalse % Suppress indent in first paragraph,
\secdef\@chapter\@schapter} % change to \@afterindenttrue to indent.
% \end{macrocode}
%
% \begin{macrocode}
\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
\chaptermark{#1}%
\addtocontents{lof}{\protect\addvspace{10\p@}}% Adds between-chapter space
\addtocontents{lot}{\protect\addvspace{10\p@}}% to lists of figs & tables.
\@makechapterhead{#2}%
\@afterheading} % Routine called after chapter and section heading.
% \end{macrocode}
%
% |\@makechapterhead|\marg{TEXT} Makes the heading for the |\chapter| command.
% \begin{macrocode}
\def\@makechapterhead#1{%
\vspace*{50\p@}%
{\renewcommand\baselinestretch{\@titlespacing}% set spacing for chapter title
\parindent \z@ \raggedright \normalfont
\ifnum \c@secnumdepth >\m@ne
\@chapternamefont\@chapternamesize \@chapapp\space \thechapter
\par\nobreak
\vskip 20\p@
\fi
\interlinepenalty\@M
\@chaptertitlefont\@chaptertitlesize #1\par\nobreak
\vskip 40\p@
}\renewcommand\baselinestretch{\@spacing}\@normalsize}% return to \@spacing
% \end{macrocode}
%
% |\@makeschapterhead|\marg{TEXT} Makes the heading for the |\chapter*| command.
% \begin{macrocode}
\def\@schapter#1{\@makeschapterhead{#1}\@afterheading}
% \end{macrocode}
%
% \begin{macrocode}
\def\@makeschapterhead#1{% % Heading for \chapter* command
\vspace*{-30\p@}% % Space at top of page.
{\parindent \z@ \raggedright
\normalfont
\interlinepenalty\@M
\centering \large \scshape% % Title font.
#1\par\nobreak % Title and TeX penalty to prevent page break.
\vskip 20\p@ % Space between title and text.
}}
% \end{macrocode}
% \subsubsection{Sectioning Macros}
% |\@startsection|\marg{NAME}\marg{LEVEL}\marg{INDENT}\marg{BEFORESKIP}\\
% \marg{AFTERSKIP}\marg{STYLE} optional * [ALTHEADING]\marg{HEADING}
%
% Generic command to start a section.\\
% NAME : e.g., 'subsection'\\
% LEVEL : a number, denoting depth of section -- e.g., chapter=1,\\
% section = 2, etc. A section number will be printed if\\
% and only if LEVEL $\leq$ the value of the secnumdepth\\
% counter.\\
% INDENT : Indentation of heading from left margin
% BEFORESKIP : Absolute value = skip to leave above the heading.
% If negative, then paragraph indent of text following
% heading is suppressed.
% AFTERSKIP : if positive, then skip to leave below heading,
% else - skip to leave to right of run-in heading.
% STYLE : commands to set style
% If '*' missing, then increment the counter. If it is present, then
% there should be no [ALTHEADING] argument. A sectioning command
% is normally defined to \@startsection + its first six arguments.
% Note: for ?SKIP, negation applies to all components of a skip -- the
% negative of (10pt plus 5pt minus 2.5pt) is (slightly surprisingly)
% (-10pt plus -5pt minus -2.5pt)
% \begin{macrocode}
\ifthenelse{\boolean{hyphenatetitles}}{%
\newcommand{\TitleHyphenation}{}%
}{%
\newcommand{\TitleHyphenation}{%
\pretolerance=10000%
\hyphenpenalty=200%
\raggedright}%
}
\newcommand\section{\@startsection {section}{1}{\z@}%
{-2.0ex \@plus -.5ex \@minus -.2ex}%
{.75ex \@plus.1ex}%
{\normalfont\renewcommand\baselinestretch{\@titlespacing}%
\@secfontsize\TitleHyphenation}}
\newcommand\subsection{\@startsection{subsection}{2}{\z@}%
{-1.5ex\@plus -.5ex \@minus -.2ex}%
{.5ex \@plus .1ex}%
{\normalfont\renewcommand\baselinestretch{\@titlespacing}%
\@subsecfontsize\TitleHyphenation}}
\newcommand\subsubsection{\@startsection{subsubsection}{3}{\z@}%
{-1.0ex\@plus -.3ex \@minus -.1ex}%
{.5ex \@plus .1ex}%
{\normalfont\renewcommand\baselinestretch{\@titlespacing}%
\@ssubsecfontsize\TitleHyphenation}}
% \end{macrocode}
%
% Because |\{sub,}paragraph| are in-line, we allow hyphenation always.
% \begin{macrocode}
\newcommand\paragraph{\@startsection{paragraph}{4}{\z@}%
{.75ex \@plus.2ex \@minus.1ex}%