0

I am in the final weeks of my time as a PhD graduate student, and I need to fix one last item in my thesis to conform to my graduate school's thesis formatting requirements.

The graduate school requires that the Appendix chapter headings be centered while chapter headings in the main body of the text are left aligned.

How do I only center the the appendix chapter heading?

I've done a good deal of searching today on google and stack exchange to resolve this issue. A solution that involves \titlesec does not do as I would like without doing additional things that I do not want.

I apologize for not providing a MWE. Since my graduate school does not support latex, I am using templates for the thesis that have been maintained by former graduate students. The document has grown to be greatly bloated.

Thank you.

Edits: I have updated the question to better illustrate the problem.

I've found this link to be useful, although I haven't been able to implement a similar solution: How to change the title alignment just for the appendix sections?

I am using the appendix package and the document class thesis.cls. I use "\chapter{}" to create the chapter in the appendix. Below, I've posted some sections of the .cls file that I think are relevant and might help to fix the problem. I've also posted a MWE. If more of all of the class file would help someone find a result, it is posted on my google drive.

google drive link: https://drive.google.com/file/d/0B3QLUQGohKYlRlQ5cnRaNHBxMm8/view?usp=sharing

\newcommand{\chapter}{\if@openright\cleardoublepage\else\clearpage\fi
                %\thispagestyle{plain}%
                \global\@topnum\z@
                \@afterindentfalse
                \secdef\@chapter\@schapter}
\def\@chapter[#1]#2{\ifnum \c@secnumdepth >\m@ne
                   \if@mainmatter
                     \refstepcounter{chapter}%
                     \typeout{\@chapapp\space\thechapter.}%
                     \addcontentsline{toc}{chapter}%
                                {Chapter \protect\numberline{\thechapter}#1}%
                   \else
                     \addcontentsline{toc}{chapter}{#1}%
%                      \addcontentsline{toc}{chapter}{#1}%
                   \fi
                \else
                  \addcontentsline{toc}{chapter}{#1}%
                \fi
                \chaptermark{#1}%
  %             \addtocontents{lof}{\vspace{-\baselineskip}}%
                %\addtocontents{lot}{\protect\addvspace{10\p@}}%
                \if@twocolumn
                  \@topnewpage[\@makechapterhead{#2}]%
                \else
                  \@makechapterhead{#2}%
                  \@afterheading
                \fi}
\def\@makechapterhead#1{%
 % \vspace*{50\p@}%
 \vspace*{20\p@}
 {\parindent \z@ \raggedright \reset@font
  \ifnum \c@secnumdepth >\m@ne
  \if@mainmatter
    \large{ \bfseries \@chapapp{} \thechapter: \space}
 %      \par\nobreak
   %     \vskip 20\p@
    \fi
  \fi
  %  \interlinepenalty\@M
 \large{ \bfseries #1\par\nobreak}
 %\vskip 40\p@
 \vskip 10\p@
}}
   \def\@schapter#1{\if@twocolumn
               \@topnewpage[\@makeschapterhead{#1}]%
             \else
               \@makeschapterhead{#1}%
               \@afterheading
             \fi}
  \def\@makeschapterhead#1{%
  %  \vspace*{50\p@}%
 {\parindent \z@ \raggedright
  \reset@font
  \interlinepenalty\@M
   \normalsize \bfseries #1\par\nobreak
  %   \vskip 40\p@
   \vskip 10\p@
   }}





\documentclass[letterpaper,12pt,oneside]{Incl/thesis}
\usepackage[toc]{appendix}
\begin{document}
hello

\begin{appendices}
\chapter{asdf}
hello

\end{appendices}

\end{document}

Again, I would like "Appendix A: asdf" to be centered on the top of the page.

One solution that I just found was to replace "raggedright" with "centering" ... however that would change all chapter headings to the center. Instead of this, can I just add, for example, the lines

\def\@makechapterhead#1{%
 % \vspace*{50\p@}%
 \vspace*{20\p@}
 {\parindent \z@ \centering \reset@font
  \ifnum \c@secnumdepth >\m@ne
  \if@mainmatter
    \large{ \bfseries \@chapapp{} \thechapter: \space}
 %      \par\nobreak
   %     \vskip 20\p@
    \fi
  \fi
  %  \interlinepenalty\@M
 \large{ \bfseries #1\par\nobreak}
 %\vskip 40\p@
 \vskip 10\p@
}}

right after "\begin{appendices}" ? I have tried this, but it does not work. Is there a way I can renew this definition out of the .cls file?

gsandhu
  • 163
  • Welcome to TeX.SX! Please help us to help you and add a minimal working example (MWE) that illustrates your problem. It will be much easier for us to reproduce your situation and find out what the issue is when we see compilable code, starting with \documentclass{...} and ending with \end{document}. – Mike Renfro Apr 15 '15 at 20:06
  • Even if you can't post the entire thesis template here (and you shouldn't, if it's as bad as you say), is it available on the web somewhere? Without more details, it will be difficult to impossible to know which potential answers would conflict with packages already in your thesis, for example. – Mike Renfro Apr 15 '15 at 20:07
  • I have made an attempt to do so. – gsandhu Apr 15 '15 at 22:28
  • The bad news is, you're using a giant class from 1995. The good news is, I don't think the class is anything more than a renamed copy of book.cls (normally a thesis class would have a committee's signature page, formatting rules for margins, etc. -- these are entirely absent from your file). I think any fix you find that works with \documentclass{book} will work for your thesis as well. – Mike Renfro Apr 15 '15 at 22:57
  • 1
    You don't have to put the \def in the preamble. You can wait until right before the appendices start. – John Kormylo Apr 16 '15 at 03:02

1 Answers1

1

I think I found a solution, but it is not elegant. Basically, I went through the .cls file and added additional entries. I created new entries "chapterA" for everything that had "chapter". For the makechapterhead definitions, I changed raggedright to centering. Thus, I create centered chapters in the appendices with

\chapterA{asdf}
gsandhu
  • 163