summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2022-03-04 21:51:06 +0000
committerKarl Berry <karl@freefriends.org>2022-03-04 21:51:06 +0000
commit929e3919eb5fe0599a8e786175f177db4ee643db (patch)
tree95e785254ba3681935b102946cde1ea91e3b0db3
parent3906c3b7c7f447cc710bbb7ec7ff2b50c1ef1b75 (diff)
msu-thesis (4mar22) (branch)
git-svn-id: svn://tug.org/texlive/branches/branch2021.final@62408 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/texmf-dist/doc/latex/msu-thesis/README.md8
-rw-r--r--Master/texmf-dist/doc/latex/msu-thesis/msu-thesis.pdfbin224666 -> 242346 bytes
-rw-r--r--Master/texmf-dist/doc/latex/msu-thesis/msu-thesis.tex34
-rw-r--r--Master/texmf-dist/doc/latex/msu-thesis/samples/MSU-thesis-template.tex16
-rw-r--r--Master/texmf-dist/doc/latex/msu-thesis/samples/MSU-thesis-testfile.pdfbin196098 -> 196098 bytes
-rw-r--r--Master/texmf-dist/tex/latex/msu-thesis/msu-thesis.cls26
6 files changed, 67 insertions, 17 deletions
diff --git a/Master/texmf-dist/doc/latex/msu-thesis/README.md b/Master/texmf-dist/doc/latex/msu-thesis/README.md
index 37e6fc2f2e1..1f4d7cf16a1 100644
--- a/Master/texmf-dist/doc/latex/msu-thesis/README.md
+++ b/Master/texmf-dist/doc/latex/msu-thesis/README.md
@@ -1,17 +1,17 @@
-# MSU Thesis Class Version 3.0 2021/06/10
+# MSU Thesis Class Version 3.1 2022/03/03
-Copyright 2011-2021 by Alan Munn <amunn@msu.edu>
+Copyright 2011-2022 by Alan Munn <amunn@msu.edu>
This is a class file for producing dissertations and theses according to
the Michigan State University Graduate School Guidelines for Electronic
Submission of Master's Theses and Dissertations (March 2020).
-The class is based on the memoir document class, and thefore inherits
+The class is based on the `memoir` document class, and therefore inherits
all of the functionality of that class.
## Installation:
-The msu-thesis class is part of both TeXLive and MikTeX, so you should either already have it or should be able to install it with your package manager.
+The `msu-thesis` class is part of both TeXLive and MikTeX, so you should either already have it or should be able to install it with your package manager.
If you wish to install it locally, follow the directions below:
diff --git a/Master/texmf-dist/doc/latex/msu-thesis/msu-thesis.pdf b/Master/texmf-dist/doc/latex/msu-thesis/msu-thesis.pdf
index 96496dc77b2..dac5e635b89 100644
--- a/Master/texmf-dist/doc/latex/msu-thesis/msu-thesis.pdf
+++ b/Master/texmf-dist/doc/latex/msu-thesis/msu-thesis.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/msu-thesis/msu-thesis.tex b/Master/texmf-dist/doc/latex/msu-thesis/msu-thesis.tex
index 5afea970ad5..518060fe700 100644
--- a/Master/texmf-dist/doc/latex/msu-thesis/msu-thesis.tex
+++ b/Master/texmf-dist/doc/latex/msu-thesis/msu-thesis.tex
@@ -2,8 +2,8 @@
\documentclass[11pt]{article}
-\def\msuversion{3.0}
-\def\msudate{2021/06/10}
+\def\msuversion{3.1}
+\def\msudate{2022/03/03}
\title{\textbf{Using the MSU Thesis Class}}
\author{\textbf{Alan Munn}\\Department of Linguistics and Languages\\\texttt{\href{mailto:amunn@msu.edu}{amunn@msu.edu}}}
\date{Version \msuversion\\\msudate}
@@ -181,7 +181,7 @@ The \pkg{memoir} class replicates the functionality of many independent packages
\subsubsection{Caption delimiter}
Because the thesis office doesn't understand anything about punctuation it requires the colon that would appear in a caption to also appear in the contents lists. Since they don't care about the colon itself, but just consistency I've removed colons from the captions entirely, since leaving it in makes the contents lists look really stupid. But in case you or your advisor want the colon in captions, you can add the colon back in by using the Memoir command |\captiondelim{:\space}| and the class will make sure the Lists of Tables and Figures match in formatting.
\subsubsection{New lists}
-If you are using other kinds of floats such as listings, you should use the Memoir |\newlistof| command to make the relevant list. The class provides a macro |\msucaptiondelim| which can be used to make sure the formatting of the captions in the list-of-X match the setting you have for Figures and Tables. Here is an example of how you would add a listings list. The following code goes in your preamble:
+If you are using other kinds of floats such as listings, you should use the Memoir |\newlistof| command to make the relevant list. The class provides a macro |\msucaptiondelim| which can be used to make sure the formatting of the captions in the list-of-X match the setting you have for Figures and Tables. Here is an example of how you would add a listings list. For lists of algorithms, see section \ref{algorithms} below. The following code goes in your preamble:
\begin{quote}
\begin{lstlisting}
\newlistof{listoflistings}{lol}{List of Listings}
@@ -213,6 +213,25 @@ Another common kind of list is a List of Abbreviations. The thesis office seems
Your list of abbreviations here.
\end{lstlisting}
\end{quote}
+
+\subsection{Algorithm packages\label{algorithms}}
+Because the various algorithm formatting packages such as \pkg{algorithm2e} and \pkg{algorithmicx} (or its related packages) sometimes create incompatibilities with the \pkg{memoir} float methods, the class provides you with floating |{algorithm}| environment and the corresponding list of algorithms, so you do not have to create your own list of algorithms. Here are some specific important points about using \pkg{algorithm2e} and \pkg{algorithmicx}.
+\begin{itemize}[label=\textbullet]
+\item Do \emph{not} load the \pkg{algorithm} package.
+\item If you use the \pkg{algorithm2e} package you \emph{must} load it with the |[algo2e]| option (along with any other options you need).
+\end{itemize}
+\subsubsection{\pkg{algorithmicx} package} If you are using the \pkg{algorithmicx} package, any of its related packages (including its older predecessor \pkg{algorithmic}) which suggest that you use the \pkg{algorithm} package to create floating algorithms, you can load the \pkg{float} package to use the its float styling capabilities instead of loading the \pkg{algorithm} package. You should \emph{not} however use the \pkg{float} package to create new floating environments. You must use the \pkg{memoir} methods to create new floating environments and only then load the \pkg{float} package.
+
+If you would normally load the \pkg{algorithm} package to create floating algorithms do the following instead. If you are creating any other new floating environments (like listings as described above) you \emph{must} create these environments first \emph{before} loading the \pkg{float} package otherwise your document will not compile.
+\begin{quote}
+\begin{lstlisting}
+% This code should only appear AFTER you have created any other new lists
+\usepackage{float}
+\floatstyle{ruled}% or any of the predefined float styles
+\restylefloat{algorithm}
+\end{lstlisting}
+\end{quote}
+
\subsection{The \pkg{microtype} package and contents lists}
If you use the \pkg{microtype} package with |protrusion| set, it’s best to turn it off before your contents lists. You can do this by using |\microtypesetup{protrusion=false}|
before the contents lists and |\microtypesetup{protrusion=true}| afterwards. Schematically:
@@ -276,10 +295,11 @@ Appendix text goes here
\end{quote}
\subsubsection{Appendices per chapter}
-If you need to add an appendix or appendices to a chapter, you must use the \pkg{[chapterapp]} class option. The code for the appendices themselves is exactly as described above.
+If you need to add an appendix or appendices to a chapter, you must use the \pkg{[chapterapp]} class option. The code for the appendices themselves is exactly as described above. Note that per-chapter appendices should \emph{not} be preceded by the |\backmatter| command, which should only precede the global bibliography or appendices.
\subsection{Bibliographies}
-The class places no constraints on how you do your bibliography. If you have per-chapter bibliographies, you must use the |[chapterbib]| class option. Before any bibliography (whether global or per-chapter) you should use the |\makebibliographypage| command.
+The class places no constraints on how you do your bibliography. If you have per-chapter bibliographies, you must use the |[chapterbib]| class option. Before any bibliography (whether global or per-chapter) you should use the |\makebibliographypage| command. Note that per-chapter bibliographies should \emph{not} be preceded by the |\backmatter| command, which should only precede the global bibliography or appendices.
+
\subsubsection{Bibliography spacing}\label{bibspacing}
Please note that although bibliography entries must be single spaced, there must be a space between each entry. This parameter is set by your bibliography package and not by the class itself. If you are using \pkg{natbib} or \pkg{biblatex} these spacing parameters are set for you by the class. If you are using another package for your bibliography you are responsible for adjusting the relevant spacing parameters.
@@ -311,9 +331,9 @@ The latest copy of \pkg{msu-thesis} will always be available on \href{https://c
\subsection{Archiving your thesis for the future}
Since the current version of the \pkg{msu-thesis} class satisfies the Graduate School requirements at any one time, as these requirements change, you may find that if you need to recompile your thesis after you have graduated that the formatting changes. To avoid this, I would recommend saving an archived version of the \pkg{msu-thesis.cls} file in the same folder as your thesis file. You only need to do this once you have completely finished your thesis however; there's no need to do it during the writing process.
\subsection{Version history}
-Previous versions of \pkg{msu-thesis} (versions 1.0--1.4b) were created for non-electronic submission and should not be used. Versions 1.5--1.6 (the first electronic submission versions) contained a |\makeabstract| command and a separate |msuabstract| environment. These have been removed as of version 1.7. Users who are upgrading from earlier versions to version 1.7 do not need to change these commands however but their use will trigger a warning.) Version 2.0 implemented landscape pages; version 2.1 added support for \pkg{hyperref}. Versions 2.2--2.5 mainly accommodated to the ever changing whims of the MSU Graduate School. Version 2.6 fixed some appendix bugs introduced by the previous whim accommodation. Version 2.7 fixed various small spacing issues, fixed a bug which prevented a new chapter page to be a landscape page, added support for the \pkg{apacite} package, and updated degree options. Version 2.8 fixed some spacing and capitalization issues and added support for the public abstract. Version 2.9 removed subscript/superscript size restrictions, added font size options and made small spacing changes to appease the thesis office. Version 3.0 added full support for per-chapter bibliographies and appendices, and automated bibliography spacing for |natbib| and |biblatex| produced bibliographies.
+Previous versions of \pkg{msu-thesis} (versions 1.0--1.4b) were created for non-electronic submission and should not be used. Versions 1.5--1.6 (the first electronic submission versions) contained a |\makeabstract| command and a separate |msuabstract| environment. These have been removed as of version 1.7. Users who are upgrading from earlier versions to version 1.7 do not need to change these commands however but their use will trigger a warning.) Version 2.0 implemented landscape pages; version 2.1 added support for \pkg{hyperref}. Versions 2.2--2.5 mainly accommodated to the ever changing whims of the MSU Graduate School. Version 2.6 fixed some appendix bugs introduced by the previous whim accommodation. Version 2.7 fixed various small spacing issues, fixed a bug which prevented a new chapter page to be a landscape page, added support for the \pkg{apacite} package, and updated degree options. Version 2.8 fixed some spacing and capitalization issues and added support for the public abstract. Version 2.9 removed subscript/superscript size restrictions, added font size options and made small spacing changes to appease the thesis office. Version 3.0 added full support for per-chapter bibliographies and appendices, and automated bibliography spacing for |natbib| and |biblatex| produced bibliographies. Version 3.1 added support for an |{algorithm}| environment and a list of algorithms to combat incompatibilities with the \pkg{algorithm} and \pkg{algorithm2e} packages.
\section{Acknowledgements}
-Thanks to Lars Madsen, Ulrike Fischer and Peter Wilson for help with setting up parts of the memoir code for versions 1.0--1.4 (now eliminated due to changed requirements). Thanks to Wolfgang Sternefeld for supplying the \pkg{linguex} spacing fix code, Leo Liu for the landscape page numbering code, which greatly simplified my original version, and Florent Chervet for the \pkg{hyperref} code. Thanks also to the following students who have reported problems over the years: Irina Agafonova, Ali Al-jiboory, Dmitriy Bryndin, Greg Christian, Kyle Crayne, Matt Husband, Changkuk Jung, Adam Liter, William Muir, Alicia Parrish, Neil ver Planck, Adam Soliman, Erik Stitt, Michael Wojcik, Eremey Valetov, Matthew Vincent and Yisu Zhou. A special thank you to Non Thongprong who graciously provided a copy of his entire thesis which allowed me to debug some especially subtle spacing inconsistencies.
+Thanks to Lars Madsen, Ulrike Fischer and Peter Wilson for help with setting up parts of the memoir code for versions 1.0--1.4 (now eliminated due to changed requirements). Thanks to Wolfgang Sternefeld for supplying the \pkg{linguex} spacing fix code, Leo Liu for the landscape page numbering code, which greatly simplified my original version, and Florent Chervet for the \pkg{hyperref} code. Thanks also to the following students who have reported problems over the years: Irina Agafonova, Ali Al-jiboory, Julian Blank, Dmitriy Bryndin, Greg Christian, Kyle Crayne, Ciaron Hamilton, Matt Husband, Changkuk Jung, Adam Liter, William Muir, Alicia Parrish, Neil ver Planck, Adam Soliman, Erik Stitt, Michael Wojcik, Eremey Valetov, Matthew Vincent and Yisu Zhou. A special thank you to Non Thongprong who graciously provided a copy of his entire thesis which allowed me to debug some especially subtle spacing inconsistencies.
\appendix
\renewcommand{\thesection}{Appendix \Alph{section}}
diff --git a/Master/texmf-dist/doc/latex/msu-thesis/samples/MSU-thesis-template.tex b/Master/texmf-dist/doc/latex/msu-thesis/samples/MSU-thesis-template.tex
index c82f6e0020e..198c170a033 100644
--- a/Master/texmf-dist/doc/latex/msu-thesis/samples/MSU-thesis-template.tex
+++ b/Master/texmf-dist/doc/latex/msu-thesis/samples/MSU-thesis-template.tex
@@ -1,5 +1,5 @@
% This is a template for use with the MSU Thesis class
-% Vesion 3.0 2021/06/10
+% Version 3.1 2022/03/03
%
% Class options:
%[PhD] Doctor of Philosophy (default)
@@ -107,7 +107,11 @@ Your acknowledgements here.
\listoffigures % comment this out if you have no figures
%
% If you have a list of abbreviations/symbols it would go here preceded by a \clearpage
-% See the class documentation and the Memoir manual for how to create other lists
+% See the class documentation and the Memoir manual for how to create other lists
+%
+% If you are using an algorithm formatting package (e.g. algorithmicx or algorithm2e)
+% please read the class documentation carefully on how to use these packages with the class
+% The class provides an {algorithm} environment and a \listofalgorithms by default
%
\mainmatter
%
@@ -115,6 +119,9 @@ Your acknowledgements here.
% May violate thesis office rules
%\addtocontents{toc}{\protect\renewcommand{\protect\cftchapterdotsep} {\cftnodots}}
+% ALL documents using this class must have \chapter divisions
+% If you are using it for an MA/MS thesis you still need to have chapters, even if they are very small.
+
\chapter{Your first chapter}
%
% If you have pages that must appear in landscape mode, use the [lscape] documentclass option
@@ -143,7 +150,9 @@ Your acknowledgements here.
%
% If each chapter has its own set of appendices, then load the class with the [chapterapp] option
% and put your {appendix} or {appendices} environments at the end of each chapter.
-%
+% You should not use the \backmatter command before per-chapter material
+%
+% There should only be ONE \backmatter command in your document, and it should separate only the thesis from the bibliography
\backmatter
% The next lines add the dots back into the References/Bibliography heading
% of the TOC. Only uncomment this if you need to put the dots back in having removed them for Chapter headings.
@@ -166,6 +175,7 @@ Your acknowledgements here.
% If you need per-chapter bibliographies, you need to use the [chapterbib]
% class option and you would use \makebibliographypage before each
% chapter level bibliography and then the relevant bibliography command
+% You should not use the \backmatter command before per-chapter material
%
\end{document}
diff --git a/Master/texmf-dist/doc/latex/msu-thesis/samples/MSU-thesis-testfile.pdf b/Master/texmf-dist/doc/latex/msu-thesis/samples/MSU-thesis-testfile.pdf
index 1370069e3f3..d19cfa3677e 100644
--- a/Master/texmf-dist/doc/latex/msu-thesis/samples/MSU-thesis-testfile.pdf
+++ b/Master/texmf-dist/doc/latex/msu-thesis/samples/MSU-thesis-testfile.pdf
Binary files differ
diff --git a/Master/texmf-dist/tex/latex/msu-thesis/msu-thesis.cls b/Master/texmf-dist/tex/latex/msu-thesis/msu-thesis.cls
index 8fc9939364c..9d6c314e6f7 100644
--- a/Master/texmf-dist/tex/latex/msu-thesis/msu-thesis.cls
+++ b/Master/texmf-dist/tex/latex/msu-thesis/msu-thesis.cls
@@ -155,11 +155,13 @@
% Added global chapter counter for proper hyperrefs to appendices
% Added a formatting hook for appendix numbering. We'll see how this works in practice.
% Added spacing hooks for bibliographies to make users' lives a little easier
+% Version 3.0b 2021/07/14 Added msu@hchap counter for hyperref targets in appendices (unreleased)
+% Version 3.1 2022/03/03 Added support for List of Algorithms plus fixes for algorithm2e and algorithmicx etc
%
% Report bugs/problems/questions to <amunn@msu.edu>
%
-\def\msu@version{3.0}
-\def\msu@date{2021/06/10}
+\def\msu@version{3.1}
+\def\msu@date{2022/03/03}
\NeedsTeXFormat{LaTeX2e}
\ProvidesClass{msu-thesis}[\msu@date\space Michigan State University Thesis Class version \msu@version]
\newif\ifmsu@dissertation\msu@dissertationtrue % added v2.7 boolean for \msu@thesistype
@@ -256,6 +258,8 @@
\newcommand*{\msu@fieldseparator}{\textendash} % this is between the degree name and field of study
\newcounter{msu@hchap} % global counter for chapters used by hyperref
+% This may also be solved by using \hypersetup{hypertexnames=false}
+% hard to tell whether this is a better solution.
% make title 2in from top of page
@@ -332,6 +336,21 @@
\def\msu@chapfont{\bfseries}
\fi
+% Support for algorithm packages added v3.1
+% If using the algorithm2e package, you must load it with the algo2e package option
+% If you are using algorithmicx or its related versions you should not load
+% the algorithm package, but instead load the float package and then style
+% your algorithms accordingly using \floatstyle
+% Importantly you MUST load float after defining any new lists since it clobbers
+% the memoir float methods
+
+
+\newlistof{listofalgorithms}{loa}{List of Algorithms}
+\newfloat[chapter]{algorithm}{loa}{Algorithm}
+\newlistentry{algorithm}{loa}{0}
+\renewcommand*{\cftalgorithmname}{Algorithm\space}
+\renewcommand*{\cftalgorithmaftersnum}{\msucaptiondelim}
+
%
% This code technique from http://tex.stackexchange.com/q/232121/
% Makes appendices formatted as sections not chapters in the TOC
@@ -663,6 +682,7 @@
\let\msucaptiondelim\@contdelim
% Moved to AtBeginDocument to override apacite
\@ifpackageloaded{apacite}{\@tocbibfalse}{} % added 6/22/17
+\@ifpackageloaded{algorithm2e}{\let\@chapter=\algocf@original@chapter}{}% undoes algorithm2e redefinition of chapter added v3.1
% Make bibliography spacing more automatic for biblatex and natbib users 2021/06/10
% This should cover most cases. Otherwise just set single spacing
\@ifpackageloaded{biblatex}
@@ -695,7 +715,7 @@
\l@chapapp{\MakeLinkUppercase #1}{#2}{\cftchaptername}} % Format chapter names
\renewcommand*{\l@appendix}[2]{%
\l@chapapp{\MakeLinkUppercase #1}{#2}{\cftappendixname}} % Format appendix names (changed 13/12/17)
-\apptocmd{\@resets@pp}{\gdef\theHchapter{\Alph{msu@hchap}}}{}{} % get hypertargets in appendices right (added v3.0)
+\apptocmd{\@resets@pp}{\gdef\theHchapter{\arabic{msu@hchap}}}{}{} % get hypertargets in appendices right (added v3.0; fixed v3.0b)
}
% if no hyperref
{\relax}