diff options
author | Karl Berry <karl@freefriends.org> | 2019-05-08 21:15:22 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2019-05-08 21:15:22 +0000 |
commit | 6f272323ab4ef903d4e94df73f8f35be51b1f20d (patch) | |
tree | 344bee012f7f2eb897321d300f0a537299563454 /Master | |
parent | 78b1605f1f5a0899ce94e74a533fe20e7a2ae747 (diff) |
mlacls (8may19)
git-svn-id: svn://tug.org/texlive/trunk@51049 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rw-r--r-- | Master/texmf-dist/doc/latex/mlacls/BUGS.md | 3 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/mlacls/CHANGELOG.md | 17 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/mlacls/README.md | 31 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/mlacls/example.tex | 66 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/mlacls/mla-example.bib (renamed from Master/texmf-dist/doc/latex/mlacls/example.bib) | 0 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/mlacls/mla-example.pdf | bin | 0 -> 60124 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/latex/mlacls/mla-example.tex | 86 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/mlacls/mla.pdf | bin | 249997 -> 296896 bytes | |||
-rw-r--r-- | Master/texmf-dist/source/latex/mlacls/mla.dtx | 494 | ||||
-rw-r--r-- | Master/texmf-dist/source/latex/mlacls/mla.ins | 12 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/mlacls/mla.cls | 34 |
11 files changed, 446 insertions, 297 deletions
diff --git a/Master/texmf-dist/doc/latex/mlacls/BUGS.md b/Master/texmf-dist/doc/latex/mlacls/BUGS.md index bf40b4f9395..5eb659f1aa6 100644 --- a/Master/texmf-dist/doc/latex/mlacls/BUGS.md +++ b/Master/texmf-dist/doc/latex/mlacls/BUGS.md @@ -1,7 +1,8 @@ Bugs ==== -None currently known. +* Specifying both options `mla7` and `mla8` doesn't return an error, + but instead falls back to `mla7`. Reporting --------- diff --git a/Master/texmf-dist/doc/latex/mlacls/CHANGELOG.md b/Master/texmf-dist/doc/latex/mlacls/CHANGELOG.md deleted file mode 100644 index 1d391c57844..00000000000 --- a/Master/texmf-dist/doc/latex/mlacls/CHANGELOG.md +++ /dev/null @@ -1,17 +0,0 @@ -Changelog -========= - -0.2 (02 May 2019) ------------------ - -* Greatly improved documentation (incl. README) -* Added `endnotes` environment -* Corrected several minor spacing issues -* Changed section headers to small-caps -* Added support for PDF metadata -* Changed document date format to day-month-year - -0.1 (26 Apr 2019) ------------------ - -* Initial release diff --git a/Master/texmf-dist/doc/latex/mlacls/README.md b/Master/texmf-dist/doc/latex/mlacls/README.md index 1cc67aefc7f..366d2dca3a6 100644 --- a/Master/texmf-dist/doc/latex/mlacls/README.md +++ b/Master/texmf-dist/doc/latex/mlacls/README.md @@ -6,19 +6,19 @@ LaTeX class for MLA papers. Abstract -------- -Whilst the TeX family of programs is widely used in the sciences -and academia overall, there seems to be a lack of support for -the humanities, which commonly adhere to MLA format for -student papers and reports. - -Though there *are* -[MLA-style packages available](https://ctan.org/pkg/mla-paper), -none met the expectations of the author (who was mostly -just nit-picky about elegance in code). -So *voilĂ *, there now exists a proper `mla.cls`: -a simple, straightforward class for composing papers -almost perfectly adherent to the -[MLA style guide](https://style.mla.org/). +In the United States, secondary and undergraduate students +are generally expected to adhere to the format prescribed by +the Modern Language Association (MLA) for typewritten essays, +research papers and writings. +Sadly, the tool of choice is usually Microsoft Word, +even amongst those fluent with TeX. + +Though there *are* some templates and tools to aid in writing +in the MLA format using LaTeX, none fully met the expectations +of the author. +So *voilĂ *, there now exists an `mla.cls` proper: +a simple, straightforward class for composing papers almost +perfectly adherent to the MLA style guide. Documentation ------------- @@ -34,7 +34,7 @@ $ gv mla.dtx (If you're getting this package from [CTAN](https://ctan.org), a file called `mla.pdf` should already be provided.) -For an example file, refer to `example.tex` and `example.bib`, +For an example file, refer to `mla-example.tex` and `mla-example.bib`, or to the appendix in the documentation. Installation @@ -63,9 +63,6 @@ Submit a merge request on the [GitLab repository](https://gitlab.com/ssterling/mlacls/). I rarely look at the GitHub mirror. -If there's something in [`TODO.md`](./TODO.md), it's likely -a high-priority want, right under bug fixes. - Bugs ---- diff --git a/Master/texmf-dist/doc/latex/mlacls/example.tex b/Master/texmf-dist/doc/latex/mlacls/example.tex deleted file mode 100644 index fd65b2ba31f..00000000000 --- a/Master/texmf-dist/doc/latex/mlacls/example.tex +++ /dev/null @@ -1,66 +0,0 @@ -\documentclass[mla7]{mla} - -\title{Sample MLA Document} -\author{John Doe} -\professor{Dr Suzie Que} -\course{\LaTeX\ 101} -\date{\today} - -% This will be explained later! -\addbibresource{example.bib} - -\begin{document} - -\begin{paper} - -This is an example document using ``mla.cls''. -The header is automatically printed for you when calling the -``paper'' environment, which is why we jumped straight into -writing our body. - -\section{A section} - -Our professor prefers we section our paper since it's -\emph{really} long: -\begin{blockquote} -I really hope you do this right, John. -I got tired of reading that twenty-page paper with no logical breaks! -Just divide it into sections already, even though the MLA style guide -doesn't tell you to. -It's technically not \emph{prohibited}, I guess. \cite{que2019} -\end{blockquote} -That's when the ``\textbackslash{}section'' commands come in handy. -You can even create a subsection!\endnote{It's just like in the -normal ``article'' class.} - -\subsection{Subsection} - -Notice we cited something above in the blockquote. -That's where ``workscited'' comes in handy with perfect MLA format! -(The ``example.bib'' file follows this whole example.) -But, before that\ldots didn't we specify an endnote somewhere? - -\end{paper} - -\begin{notes} - -% It's also important you use the MLA template -% provided with the class, lest it look wrong. - -\printendnotes[mla] - -\end{notes} - -\begin{workscited} - -% It's important to use ``heading=none'' here, since the -% ``workscited'' environment already prints it out for us. - -% Also, notice we had to include the bibliography file -% in the preamble. That's important! - -\printbibliography[heading=none] - -\end{workscited} - -\end{document} diff --git a/Master/texmf-dist/doc/latex/mlacls/example.bib b/Master/texmf-dist/doc/latex/mlacls/mla-example.bib index e53fca0b8c7..e53fca0b8c7 100644 --- a/Master/texmf-dist/doc/latex/mlacls/example.bib +++ b/Master/texmf-dist/doc/latex/mlacls/mla-example.bib diff --git a/Master/texmf-dist/doc/latex/mlacls/mla-example.pdf b/Master/texmf-dist/doc/latex/mlacls/mla-example.pdf Binary files differnew file mode 100644 index 00000000000..690425a18d5 --- /dev/null +++ b/Master/texmf-dist/doc/latex/mlacls/mla-example.pdf diff --git a/Master/texmf-dist/doc/latex/mlacls/mla-example.tex b/Master/texmf-dist/doc/latex/mlacls/mla-example.tex new file mode 100644 index 00000000000..24a032ad332 --- /dev/null +++ b/Master/texmf-dist/doc/latex/mlacls/mla-example.tex @@ -0,0 +1,86 @@ +\documentclass[mla8]{mla} + +\title{Sample MLA Document} +\author{John Doe} +\professor{Dr. Suzie Que} +\course{\LaTeX\ 101} +\date{\today} + +% The .bib file (explained later) must be included in the preamble +\addbibresource{mla-example.bib} + +\begin{document} + +\begin{paper} + +This is an example document using ``mla.cls''. +The header is automatically printed upon using the ``paper'' class, +which is why there is no ``\textbackslash{}maketitle''. + +\section{Professors who prefer sections} + +Sometimes, research papers can become unmanageably lengthy. +In that case, section headings can help divide up the ideas +to make it more accessible to the reader. +Though this paper is short, section headings are employed +as an example of the ``mla'' class' capabilities. + +Some professors may explicitly require or denounce use of headings. +Dr. Suzie Que of Anytown, PA requires they be used for anything +longer than five pages: +\begin{blockquote} +John---so help me God---if you turn in another twenty-page research +paper with no logical breaks I will hang you at the stake. +Even though the MLA style guide doesn't say anything about +section headings, they're not actually prohibited. +So, if you turn in \emph{anything} longer than five pages to me +and there isn't a \emph{single} break or section heading, +I will dock your grade to an F. +Capisce? \cite{que2019} +\end{blockquote} +Despite her language, she does have a point to say. + +\subsection{Subsections} + +Alongside regular top-level sections, one can use +``\textbackslash{}subsection'' commands too\endnote{Section commands +in ``mla.cls'' work identical to those of the ``article'' class.}. + +\section{Using endnotes} + +As one may notice, the above subsection used an endnote. +These can simply be cited with +``Yada yada text\textbackslash{}endnote\{more info\ldots\}.'' +Endnotes can be easily printed in correct format by calling +``\textbackslash{}printendnotes[mla]'' within the +``notes'' environment. + +\section{Using bibliographies} + +Dr. Suzie Que was cited in the above blockquote. +The ins-and-outs of ``biblatex'' will not be explained in this +document, so please refer to online documentation such as the +``BibLaTeX Cheat Sheet''. + +Just as with the endnotes, +the bibliography can be easily printed in correct format by calling +``\textbackslash{}printbibliography[heading=none]'' within the +``workscited'' environment. +(The ``heading=none'' part is important; the ``workscited'' environment +already prints one.) + +\end{paper} + +\begin{notes} + +\printendnotes[mla] + +\end{notes} + +\begin{workscited} + +\printbibliography[heading=none] + +\end{workscited} + +\end{document} diff --git a/Master/texmf-dist/doc/latex/mlacls/mla.pdf b/Master/texmf-dist/doc/latex/mlacls/mla.pdf Binary files differindex 3e1b9ae8ee9..683af471675 100644 --- a/Master/texmf-dist/doc/latex/mlacls/mla.pdf +++ b/Master/texmf-dist/doc/latex/mlacls/mla.pdf diff --git a/Master/texmf-dist/source/latex/mlacls/mla.dtx b/Master/texmf-dist/source/latex/mlacls/mla.dtx index 76ac4506b90..41c17781920 100644 --- a/Master/texmf-dist/source/latex/mlacls/mla.dtx +++ b/Master/texmf-dist/source/latex/mlacls/mla.dtx @@ -7,63 +7,46 @@ % version 1.3 of this license or any later version. % The latest version of this license is in: % -% http://www.latex-project.org/lppl.txt +% https://www.latex-project.org/lppl/lppl-1-3c/ % -% and version 1.3 or later is part of all distributions -% of LaTeX version 2005/12/01 or later. +% and version 1.3c or later is part of all distributions +% of LaTeX version 2008/05/04 or later. % % \fi - -% \iffalse % -% \section{Identification} +% \iffalse % -% For the \textsf{driver} code: +% \section*{Documentation driver} +% \addcontentsline{toc}{section}{Documentation driver} % +% \begin{macrocode} %<*driver> \ProvidesFile{mla.dtx} %</driver> -% -% The \Dclass{mla} class has only been tested with \LaTeXe , -% so we will make sure it doesn't get included in something else: -% \begin{macrocode} + %<mla>\NeedsTeXFormat{LaTeX2e} -% \end{macrocode} -% -% Announce the class name and its version: -% \begin{macrocode} %<mla>\ProvidesClass{mla} %<*mla> - [2019/05/02 v0.2 MLA Paper Class] + [2019/05/07 v0.3 MLA Paper Class] %</mla> -% \end{macrocode} -% -% \subsection{Documentation driver} -% -% The following is a boilerplate documentation driver for \TeX{}. -% In short, it produces the documentation you're currently reading. -% -% \begin{macrocode} + %<*driver> \documentclass{ltxdoc} \AtBeginDocument{\RecordChanges\CodelineIndex\EnableCrossrefs} -\AtEndDocument{\PrintIndex} -% These bits are some common shorthand I picked up +%% These bits are some common shorthand I picked up: \newcommand*{\Dfile}[1]{\texttt{#1}} \newcommand*{\Dopt}[1]{\textsf{\small #1}} \newcommand*{\Dctr}[1]{\textsl{\small #1}} -\newcommand*{\Dclass}[1]{\textsf{#1}} +\newcommand*{\Denv}[1]{\texttt{#1}} +\newcommand*{\Dcls}[1]{\textsf{#1}} \newcommand*{\Dpkg}[1]{\textsf{#1}} -\newcommand*{\Denv}[1]{\textsf{#1}} -% Needed for the appendix +%% Needed for the appendix \usepackage{verbatim} -% I just want section headers in my PDF +%% Fancy PDF \usepackage[hidelinks]{hyperref} - -% Manually specify PDF metadata \hypersetup{ pdfinfo={ Title=The MLA class, @@ -72,6 +55,71 @@ } } +%% A couple things are cited in the docs +\usepackage{filecontents} +\begin{filecontents}{mla.bib} +@book{mlahb, + author = {{Modern Language Association of America}}, + shortauthor = {{Modern Language Association}}, + title = {The {MLA} Handbook for Writers of Research Papers}, + shorttitle = {Handbook}, + edition = {8}, + year = {2016}, + publisher = {{Modern Language Association of America}}, + howpublished = {Print}, + isbn = {9781603292627} +} +@online{owlmla, + title = {{MLA} General Format}, + journaltitle = {{P}urdue Online Writing Lab}, + institution = {Purdue University}, + howpublished = {Web}, + urldate = {2019-05-06}, + url = {https://owl.purdue.edu/owl/research_and_citation/mla_style/mla_formatting_and_style_guide/mla_general_format.html} +} +@online{owlendnotes, + title = {{MLA} Endnotes and Footnotes}, + journaltitle = {{P}urdue Online Writing Lab}, + institution = {Purdue University}, + howpublished = {Web}, + urldate = {2019-05-06}, + url = {https://owl.purdue.edu/owl/research_and_citation/mla_style/mla_formatting_and_style_guide/mla_endnotes_and_footnotes.html} +} +\end{filecontents} +\usepackage[backend=biber]{biblatex} +\addbibresource{mla.bib} + +%% Just thought it'd be cool to use `acro' +\usepackage{acro} +\DeclareAcronym{US}{short=US,long=United States} +\DeclareAcronym{MLA}{short=MLA,long=Modern Language Association} +\DeclareAcronym{CTAN}{short=CTAN, + long=Comprehensive \TeX\ Archive Network} +\DeclareAcronym{OWL}{short=OWL,long=Purdue Online Writing Lab} +\DeclareAcronym{PDF}{short=PDF,long=Portable Document Format} +\DeclareAcronym{LPPL}{short=LPPL,long=\LaTeX\ Project Public License} + +%% For a few different things +%%\usepackage{semantic-markup} +\usepackage{csquotes} +\newcommand{\foreign}[1]{\textit{#1}} +\newcommand{\term}[1]{\textit{#1}} +\newcommand{\soCalled}[1]{\textquote{#1}} +\newcommand{\mentioned}[1]{\textquote{#1}} + +%% Reset footnotes per page +\usepackage[perpage]{footmisc} + +%% Technical info +\def\myemail{ssterling@firemail.cc} + +%% For the sake of consistency, I guess +\GlossaryPrologue{\pdfbookmark[0]{Change history}{ch} + \section*{Change history}} + +%% Comment this if you don't want to produce a changelog +\AtEndDocument{\PrintChanges} + \GetFileInfo{mla.dtx} \begin{document} @@ -79,6 +127,7 @@ \end{document} %</driver> % \end{macrocode} +% % \fi % % \CheckSum{0} @@ -99,27 +148,41 @@ % Grave accent \` Left brace \{ Vertical bar \| % Right brace \} Tilde \~} % -% \title{The \Dclass{mla} class\thanks{This document corresponds to -% \Dclass{mla}~\fileversion, dated \filedate.}} -% \author{Seth Price \\ \texttt{ssterling@firemail.cc}} -% \date{\filedate} +% \title{The \Dcls{mla} class\thanks{This document corresponds to +% \Dcls{mla}~\fileversion, dated \filedate.}} +% \author{Seth Price \\ \href{mailto:\myemail}{\texttt{\myemail}}} +% \date{\today} % % \maketitle % % \begin{abstract} -% Whilst the \TeX\ family of programs is widely used in the sciences -% and academia overall, there seems to be a lack of support for -% the humanities, which commonly adhere to MLA format for -% student papers and reports. -% -% Though there \emph{are} MLA-style packages available, -% none met the expectations of the author (who was mostly -% just nit-picky about elegance in code). -% So \textit{voil\`a}, there now exists a proper \Dfile{mla.cls}: +% In the \acl{US}, secondary and undergraduate students +% are generally expected to adhere to the format prescribed by +% the \ac{MLA} for typewritten essays, research papers and writings. +% Sadly, the tool of choice is usually Microsoft Word, +% even amongst those fluent with \TeX . +% +% Though there \emph{are} some templates and tools to aid in +% writing in the \ac{MLA} format using \LaTeX , +% none fully met the expectations of the author. +% So \foreign{voil\`a}, there now exists an \Dfile{mla.cls} proper: % a simple, straightforward class for composing papers -% almost perfectly adherent to the MLA style guide. +% almost perfectly adherent to the +% \ac{MLA} style guide\footfullcite{mlahb}. % \end{abstract} % +% \section*{Licensing} +% \label{sec:licensing} +% +% The files contained in this package +% may be distributed and/or modified under the +% conditions of the \ac{LPPL}, either +% version 1.3 of this license or any later version. +% The latest version of this license is in +% \url{https://www.latex-project.org/lppl/lppl-1-3c/}, +% and version 1.3c or later is part of all distributions +% of \LaTeX\ version 2008/05/04 or later. +% % \tableofcontents % % \StopEventually{} ^^A @@ -127,18 +190,19 @@ % \section{Initial code} % \label{sec:initial_code} % -% The \Dclass{mla} class is based off the \Dclass{article} class, -% so common macros such as \cs{textit} or \cs{figure} are -% useable as expected. -% Not to say we won't be re-defining a lot of macros, though. +% The \Dcls{mla} class uses the \Dcls{article} class as its base. +% Thanks to this, macros such as \cs{textit} or \cs{textsuperscript} +% work as expected and won't have to be re-defined. % \begin{macrocode} \LoadClass[letterpaper,12pt]{article} % \end{macrocode} % % \begin{macro}{\mladate} -% MLA requires use of \textit{day month year} dates, not \TeX's -% standard \textit{month, day year}. -% Here we'll define our own \cs{mladate} to give correct output. +% The \citetitle{mlahb} requires use of the \term{day month year} +% date format, not \TeX 's standard \term{month day, year}. +% The macro \cs{mladate} will format \cs{date} accordingly. +% +% \changes{v0.2}{2019/05/02}{Added macro} % \begin{macrocode} \newcommand{\mladate}{% \the\day\ @@ -163,28 +227,45 @@ % \section{Options} % \label{sec:options} % -% Some instructors will still require usage of the seventh edition of MLA. -% MLA 8e is the default for this class, but either can be explicitly specified -% with the \Dopt{mla8} or \Dopt{mla7} options. -% All this actually does is change the edition specified to the -% \Dclass{biblatex} package when loaded in in -% section~\ref{sec:loading_packages}. +% Some teachers and professors might still require using +% the seventh edition of the \citetitle{mlahb}, +% while others will likely use the eighth edition. +% Which edition to implement can be explicitly specified +% with the \Dopt{mla7} and \Dopt{mla8} class options. +% The only difference this makes within the \Dcls{mla} class itself +% is the citation format used by \Dpkg{biblatex}. % +% \changes{v0.3}{2019/05/06}{Improved options parsing to avoid +% contradiction and undefined behavior} % \begin{macrocode} -\DeclareOption{mla7}{% - \def\blopts{style=mla,noremoteinfo=false,showmedium=true} -} -\DeclareOption{mla8}{% - \def\blopts{style=mla-new,noremoteinfo=false,showmedium=false} -} +\DeclareOption{mla7}{\def\@optMlaSeven} +\DeclareOption{mla8}{\def\@optMlaEight} +% \end{macrocode} +% +% \changes{v0.3}{2019/05/07}{Added \Dopt{mla8alt} option} +% Some versions of \Dpkg{biblatex-mla} might not recognize +% the \Dopt{style=mla-new} option for the eighth edition. +% In this case, one can specify \Dopt{mla8alt} +% to the \Dcls{mla} class. +% \begin{macrocode} +\DeclareOption{mla8alt}{\def\@optMlaEightAlt} % \end{macrocode} % % \subsection{Processing} % \label{sec:processing} % -% The default is to use the eighth edition of MLA. -% Just in case something changes, however, it's wise to explicitly -% specify \Dopt{mla8} in \cs{documentclass}. +% A friendly warning will be provided when an unknown option +% is provided. +% +% \begin{macrocode} +\DeclareOption*{% + \ClassWarning{mla}{Unknown option `\CurrentOption'; ignoring} +} +% \end{macrocode} +% +% By default, the eighth edition of the \citetitle{mlahb} is used. +% To future-proof your documents for upcoming editions, however, +% it may be wise to explicitly specify \Dopt{mla8}. % % \begin{macrocode} \ExecuteOptions{mla8} @@ -194,59 +275,90 @@ % \section{Loading packages} % \label{sec:loading_packages} % -% The \Dclass{mla} class requires the following packages to work: +% The \Dcls{mla} class requires the following packages\footnote{All +% of the required packages are available for download +% on the \ac{CTAN} if unavailable on your system: +% \url{https://www.ctan.org/}.}: % +% \changes{v0.3}{2019/05/07}{Replaced obsolete \Dpkg{times} package +% with \Dpkg{newtxtext}} % \begin{macrocode} \RequirePackage{enotez} \RequirePackage{fancyhdr} \RequirePackage{fullpage} \RequirePackage{indentfirst} \RequirePackage{ragged2e} -\RequirePackage{times} +\RequirePackage{newtxtext} \RequirePackage{titlesec} \RequirePackage{xstring} % \end{macrocode} % -% And after all that, we finally load \Dpkg{biblatex} for the bibliography. -% The other packages here are prerequisites for \Dpkg{biblatex-mla}. +% The following consists of prerequisites for \Dpkg{biblatex-mla}: +% +% \changes{v0.2}{2019/05/02}{Hid hyperlink boxes in \acs{PDF} output} +% \changes{v0.2}{2019/05/02}{Added support for \acs{PDF} metadata} % \begin{macrocode} \RequirePackage[american]{babel} \RequirePackage{csquotes} \RequirePackage{hanging} \RequirePackage[hidelinks,pdfusetitle]{hyperref} -\RequirePackage[\blopts,backend=biber]{biblatex} % \end{macrocode} % -% \section{Document Layout} +% And finally, \Dpkg{biblatex}. +% The \Dcls{mla} class options dictate what options are passed to +% \Dpkg{biblatex}, hence the \term{if-then} clauses. +% Due to the nature of the code, earlier editions specified +% will override later versions (this will later be fixed). +% +% \begin{macrocode} +\ifdefined\@optMlaSeven + \RequirePackage[style=mla,noremoteinfo=false,showmedium=true, + backend=biber]{biblatex} +\else + \ifdefined\@optMlaEightAlt + \RequirePackage[style=mla,noremoteinfo=false, + showmedium=false,backend=biber]{biblatex} + \else\ifdefined\@optMlaEight + \RequirePackage[style=mla-new,noremoteinfo=false, + showmedium=false,backend=biber]{biblatex} + \fi\fi +\fi +% \end{macrocode} +% +% \section{Document layout} % \label{sec:document_layout} -% -% Now for the difficult part. -% A lot of professors are \emph{really} strict when it comes to laying out -% the paper right, so we can't take any chances here. % % \subsection{Font} % \label{sec:font} % -% The \Dpkg{times} package was already loaded in -% section~\ref{sec:loading_packages}, and the font size was set to -% 12pt when loading the \Dclass{article} class in -% section~\ref{sec:initial_code}. +% The \Dpkg{newtxtext} package was already loaded in +% section~\ref{sec:loading_packages}, +% and the font was set to 12pt when loading the \Dcls{article} class +% in section~\ref{sec:initial_code}. % This should be metric-compatible with the infamous Times New Roman, -% the \textit{de facto} standard of the MLA format. +% the \foreign{de facto} standard of the +% \ac{MLA} format\footnote{According to the popular, oft-referenced +% \ac{OWL}: \citeurl{owlmla}.}. % -% \subsection{Line spacing and breaking} +% \subsection{Line breaking and spacing} % \label{sec:line_breaking} % -% The MLA prescribes perfect double-spacing, but \LaTeX\ does it -% a little \emph{too} perfect, putting one less line of text on the -% paper than expected from the ``industry standard'', Microsoft Word. -% We'll compensate by setting the line spacing to \textit{just enough}. +% The \citetitle{mlahb} prescribes exact double-spacing, +% the definition of which varies between typesetters. +% With these parameters exact, \LaTeX\ produces 23 lines of text +% whereas the \soCalled{industry standard} +% Microsoft Word\footnote{Microsoft Word 97 through 2016, +% and likely following versions as well.} produces 24. +% To compensate, line spacing is set to \emph{just enough}: +% % \begin{macrocode} \linespread{1.99} % \end{macrocode} % -% To further adhere to the MLA style guide, we'll forego all hyphenation -% and allow weird line breaks and uncanny whitespace. +% Though not explicitly denounced in the \citetitle{mlahb}, +% most \ac{MLA}-style papers don't hyphenate or adjust spacing +% for pretty typesetting. +% % \begin{macrocode} \hyphenpenalty 10000 \pretolerance 10000 @@ -255,10 +367,9 @@ % \subsection{Paragraphing} % \label{sec:paragraphing} % -% MLA prescribes half-inch indents on the first line of each paragraph -% with no spaces in between. -% (Some professors will request you separate sections of lengthy papers, -% however; just put a paragraph in between the two consisting of ``\cs{par}''.) +% The \citetitle{mlahb} specifies half-inch first-line indentation +% for each paragraph and no extra spacing in between. +% % \begin{macrocode} \setlength{\parindent}{0.5in} \setlength{\RaggedRightParindent}{\parindent} @@ -266,24 +377,27 @@ \setlength{\topsep}{0em} % \end{macrocode} % -% MLA also cares more about consistent page count than beautiful typesetting. -% So, we'll accept our fate and allow orphans and widows for the sake of -% uniform line count. +% And, for the sake of consistent 24-line papers, +% orphans and widows are explicitly allowed. +% % \begin{macrocode} \widowpenalty 0 \clubpenalty 0 \interlinepenalty 0 % \end{macrocode} % -% We also want flush-left ragged lines. +% For a final heinous crime against typesetting, +% the \citetitle{mlahb} advises flush-left/ragged-right alignment. % (This is acheived with the \Dpkg{ragged2e} package.) +% % \begin{macrocode} \RaggedRight % \end{macrocode} % % \begin{environment}{noindent} -% The \Denv{noindent} environment works a little wonky when working with -% the \Dpkg{ragged2e} package, so we'll re-define it. +% The \Denv{noindent} environment doesn't work as expected +% in conjunction with \Dpkg{ragged2e}, hence the re-definition. +% % \begin{macrocode} \renewenvironment{noindent}{% \edef\tmpind{\parindent} @@ -293,32 +407,32 @@ \undef{\tmpind} } % \end{macrocode} -% % \end{environment} % % \subsection{Page layout} % \label{sec:page_layout} % -% The MLA uses standard ``letter-size'' paper, and that's almost -% all we have in America anyway. -% The paper size was already set to letter when loading the -% \Dclass{article} class in section~\ref{sec:initial_code}. +% With few exceptions, the \ac{US} uses \soCalled{letter-size} paper. +% The paper size was already set when loading the \Dcls{article} class +% in section~\ref{sec:initial_code}. +% +% Furthermore, the \citetitle{mlahb} dictates uniform one-inch margins +% on said paper. +% This was already set by the \Dpkg{fullpage} package as loaded +% in section~\ref{sec:loading_packages}. +% The \cs{textheight} and \cs{textwidth} definitions are here +% just for good measure. % -% Furthermore, -% the MLA prescribes uniform one-inch margins on said letter-size paper. -% This is taken care of with the \Dpkg{fullpage} package loaded in -% section~\ref{sec:loading_packages}. The \cs{textheight} and \cs{textwidth} -% definitions are here just for good measure. % \begin{macrocode} \setlength{\textheight}{9in} \setlength{\textwidth}{6.5in} % \end{macrocode} -% +% % \subsection{Running head} % \label{sec:running_head} % -% The running head in MLA style is simply the author's surname -% followed by the page number, right-aligned. +% The running head in \ac{MLA} style is simply the author's surname +% followed by the current page number, right-aligned. % This is managed using the \Dpkg{fancyhdr} and \Dpkg{xstring} packages. % % \begin{macrocode} @@ -332,9 +446,8 @@ \fancyhead[RO]{{\StrBehind{\@author}{ }[\last]\last} \thepage} % \end{macrocode} % -% I have to fully admit I don't know what the following code -% actually does, but I tweaked around the variables to get it all -% in the right place. +% The following code is largely a hack to align the header +% in the middle of the one-inch margin above the body text. % % \begin{macrocode} \setlength{\headheight}{18pt} @@ -342,45 +455,36 @@ \setlength{\voffset}{-34pt} % \end{macrocode} % -% \section{Document Markup} +% \section{Document markup} % \label{sec:document_markup} % % \subsection{The header} % \label{sec:the_header} % -% \begin{macro}{\title} -% \begin{macro}{\author} -% \begin{macro}{\date} -% The \cs{title}, \cs{author} and -% \cs{date} macros are already defined in \Dfile{latex.dtx}. -% Their definitions are shown here for reference. -% \begin{macrocode} -% \newcommand*{\title}[1]{\gdef\@title{#1}} -% \newcommand*{\author}[1]{\gdef\@author{#1}} -% \newcommand*{\date}[1]{\gdef\@date{#1}} -% \end{macrocode} -% \end{macro} -% \end{macro} -% \end{macro} -% -% The following, however, are unique to the \Dclass{mla} class. +% The \cs{title}, \cs{author} and \cs{date} macros work as expected. +% The following, however, are unique to the \Dcls{mla} class. % % \begin{macro}{\professor} -% The name of whoever assigned the paper, i.e. ``Dr Marjorie Stewart''. +% The instructor who assigned the paper, i.e. +% \mentioned{Dr. Marjorie Stewart}. +% % \begin{macrocode} \newcommand*{\professor}[1]{\gdef\@professor{#1}} % \end{macrocode} % \end{macro} +% % \begin{macro}{\course} -% The course for which this paper was assigned, i.e. ``ENGL 101-02''. +% The course for which this paper was assigned, i.e. +% \mentioned{ENGL 101-02}. +% % \begin{macrocode} \newcommand*{\course}[1]{\gdef\@course{#1}} % \end{macrocode} % \end{macro} % -% We make sure the internal macros used to store the above information -% are empty, lest something weird happen. \cs{date}, however, -% is generally set to the current date. +% To prevent undefined behavior, the internal macros used +% to store the above information are set empty (except for \cs{date}). +% % \begin{macrocode} \title{} \author{} @@ -388,11 +492,14 @@ \course{} \date{\today} % \end{macrocode} -% +% % \begin{macro}{\makemlaheader} -% This command prints out the standard five-line MLA header, -% including the centered title. -% (Note the use of \cs{mladate}; see section \ref{sec:initial_code}.) +% This command finally prints out the standard four-line +% \ac{MLA} header, as well as the title. +% (Note the use of \cs{mladate}; see section~\ref{sec:initial_code}.) +% +% \changes{v0.2}{2019/05/02}{Changed date format to +% \term{day month year}} % \begin{macrocode} \newcommand{\makemlaheader}{% \begin{noindent} @@ -406,23 +513,33 @@ % \end{macrocode} % \end{macro} % -% \begin{macro}{\maketitle} -% And we'll just re-define \cs{maketitle} to execute \cs{makemlaheader}. +% For simplicity's sake, \cs{maketitle} is directly aliased +% to \cs{makemlaheader}. +% % \begin{macrocode} \renewcommand{\maketitle}{\makemlaheader} % \end{macrocode} -% \end{macro} % % \subsection{Sectioning} % \label{sec:sectioning} % % \begin{macro}{\section} +% \changes{v0.2}{2019/05/02}{Changed heading to small-caps} % \begin{macro}{\subsection} +% \changes{v0.2}{2019/04/27}{Properly formatted} +% \changes{v0.2}{2019/05/02}{Changed heading to small-caps} % \begin{macro}{\subsubsection} -% Customary section headers are rather straightforward and only consist of -% the section number in Arabic numerals, a space and the section name, -% flush left. -% However, for the sake of clarity, we'll put ours in small-caps. +% \changes{v0.2}{2019/04/27}{Properly formatted} +% \changes{v0.2}{2019/05/02}{Changed heading to small-caps} +% Section headings are neither defined nor discouraged +% in the \citetitle{mlahb}, though commonly used in longer papers. +% Customary section headings are rather straightforward, +% consisting of the section number in Arabic numerals, a space, +% and the section name with no special decoration\footnote{According to +% the popular, oft-referenced \ac{OWL}: \citeurl{owlmla}.}. +% +% However, for the sake of clarity, the section headings in this class +% will be set in small-caps. % % \begin{macrocode} \renewcommand{\thesection}{\@arabic\c@section} @@ -430,8 +547,8 @@ \renewcommand{\thesubsubsection}{\thesubsection.\@arabic\c@subsubsection} % \end{macrocode} % -% Un-fancifying the section headers is acheived using the -% \Dpkg{titlesec} package. +% Un-fancifying the headings is acheived using +% the \Dpkg{titlesec} package. % % \begin{macrocode} \titleformat*{\section}{\normalsize\sc} @@ -446,20 +563,22 @@ % \end{macro} % \end{macro} % -% \TeX\ generally doesn't indent the first paragraph after a -% section header. -% Since this violates MLA style, we'll simply rely on the -% \Dpkg{indentfirst} package as loaded in -% section~\ref{sec:loading_packages}. +% Under default configuration, \TeX\ doesn't indent the +% first paragraph after a section heading, violating \ac{MLA} style. +% The solution \Dpkg{indentfirst} package was already loaded +% in section~\ref{sec:loading_packages}. % % \subsection{Block quotation} -% \label{sec:block_quotation} +% \label{sec:block_quoatation} % % \begin{environment}{blockquote} -% MLA dictates block quotes be set flush $0.5$in from the left margin. -% We'll re-define the \Denv{blockquote} environment for this purpose. -% The following looks like a complete hack\ldots because it is, honestly. +% The \citetitle{mlahb} dictates blockquotes be set flush a half-inch +% from the left margin with no extra space on the right. +% The existing \Denv{blockquote} environment is re-defined +% for this purpose. % +% \changes{v0.2}{2019/04/28}{Countered unexplained vertical space +% after environment} % \begin{macrocode} \renewenvironment{blockquote}{% \list{}{\leftmargin 0.5in} @@ -474,12 +593,15 @@ % \end{environment} % % \subsection{Paper sections} +% \label{sec:paper_sections} % % \subsubsection{Paper} +% \label{sec:paper_env} % % \begin{environment}{paper} % The main content; the body. -% Most everything you write will be in here. +% This environment produces the \ac{MLA} header at the top. +% % \begin{macrocode} \newenvironment{paper}{% \makemlaheader @@ -493,8 +615,13 @@ % \label{sec:endnotes} % % \begin{environment}{notes} -% If you have any endnotes, they can be put in the -% \Denv{notes} environment. +% Endnotes can be typeset manually or with the supported +% \Dpkg{enotez} package\footnote{Refer to the \Dpkg{enotez} +% documentation for instructions.}. +% +% \changes{v0.2}{2019/04/28}{Added environment} +% \changes{v0.2}{2019/04/28}{Countered unexplained vertical space +% after heading} % \begin{macrocode} \newenvironment{notes}{% \begin{noindent} @@ -508,10 +635,11 @@ % \end{macrocode} % \end{environment} % -% The MLA doesn't prescribe a strict set of rules for endnotes, -% so the following is just to clean it up and make it consistent. -% We're assuming the required \Dpkg{enotez} package is used; -% refer to its documetation for an explanation of the following. +% The following code is to format endnotes per +% common practice\footnote{According to the popular, oft-referenced +% \ac{OWL}: \citeurl{owlendnotes}.} +% when using the \Dpkg{enotez} package. +% % \begin{macrocode} \setenotez{list-name={}} \DeclareInstance{enotez-list}{mla}{list}{% @@ -525,8 +653,12 @@ % \label{sec:bibliography} % % \begin{environment}{workscited} -% This environment creates the bibliography, starting on -% the next counted page number. +% The bibliography can be typeset manually or with the supported +% \Dpkg{biblatex} package\footnote{Refer to the \Dpkg{biblatex} +% documentation for instructions.}. +% +% \changes{v0.2}{2019/04/28}{Countered unexplained vertical space +% after heading} % \begin{macrocode} \newenvironment{workscited}{% \begin{noindent} @@ -540,10 +672,11 @@ % \end{macrocode} % \end{environment} % -% MLA prescribes a half-inch hanging indent on all -% bibliography entries. -% This is acheived by setting the \cs{bibhang} macro -% defined in the \Dpkg{biblatex} package. +% The \citetitle{mlahb} prescribes a half-inch hanging indent +% on all bibliography entries. +% This is achieved by setting the \cs{bibhang} length +% defined by the \Dpkg{biblatex} package. +% % \begin{macrocode} \setlength{\bibhang}{\parindent} % \end{macrocode} @@ -552,16 +685,19 @@ % \section{Example usage} % \label{sec:example_usage} % -% Following is a basic \LaTeXe\ document using \Dfile{mla.cls} -% and its corresponding bibliography. +% Following is a basic \LaTeX\ document using the \Dcls{mla} class. +% The document is composed of a text file, \Dfile{mla-example.tex}, +% and a \Dpkg{biblatex} bibliography file, \Dfile{mla-example.bib}. % -% \subsection{\texttt{example.tex}} +% \subsection{\Dfile{mla-example.tex}} +% \label{sec:mla-example.tex} % -% \verbatiminput{example.tex} +% \verbatiminput{mla-example.tex} % -% \subsection{\texttt{example.bib}} +% \subsection{\Dfile{mla-example.bib}} +% \label{sec:mla-example.bib} % -% \verbatiminput{example.bib} +% \verbatiminput{mla-example.bib} % % \Finale \endinput diff --git a/Master/texmf-dist/source/latex/mlacls/mla.ins b/Master/texmf-dist/source/latex/mlacls/mla.ins index 8afb5099c34..192ad095f49 100644 --- a/Master/texmf-dist/source/latex/mlacls/mla.ins +++ b/Master/texmf-dist/source/latex/mlacls/mla.ins @@ -7,10 +7,10 @@ %% version 1.3 of this license or any later version. %% The latest version of this license is in: %% -%% http://www.latex-project.org/lppl.txt +%% https://www.latex-project.org/lppl/lppl-1-3c/ %% -%% and version 1.3 or later is part of all distributions -%% of LaTeX version 2005/12/01 or later. +%% and version 1.3c or later is part of all distributions +%% of LaTeX version 2008/05/04 or later. %% \input docstrip.tex @@ -28,10 +28,10 @@ conditions of the LaTeX Project Public License, either version 1.3 of this license or any later version. The latest version of this license is in: - http://www.latex-project.org/lppl.txt + https://www.latex-project.org/lppl/lppl-1-3c/ -and version 1.3 or later is part of all distributions -of LaTeX version 2005/12/01 or later. +and version 1.3c or later is part of all distributions +of LaTeX version 2008/05/04 or later. \endpreamble diff --git a/Master/texmf-dist/tex/latex/mlacls/mla.cls b/Master/texmf-dist/tex/latex/mlacls/mla.cls index 33b8ff02b90..d8162b7f259 100644 --- a/Master/texmf-dist/tex/latex/mlacls/mla.cls +++ b/Master/texmf-dist/tex/latex/mlacls/mla.cls @@ -15,15 +15,16 @@ %% version 1.3 of this license or any later version. %% The latest version of this license is in: %% -%% http://www.latex-project.org/lppl.txt +%% https://www.latex-project.org/lppl/lppl-1-3c/ %% -%% and version 1.3 or later is part of all distributions -%% of LaTeX version 2005/12/01 or later. +%% and version 1.3c or later is part of all distributions +%% of LaTeX version 2008/05/04 or later. %% \NeedsTeXFormat{LaTeX2e} \ProvidesClass{mla} - [2019/05/02 v0.2 MLA Paper Class] + [2019/05/07 v0.3 MLA Paper Class] + \LoadClass[letterpaper,12pt]{article} \newcommand{\mladate}{% \the\day\ @@ -42,11 +43,11 @@ \fi \the\year } -\DeclareOption{mla7}{% - \def\blopts{style=mla,noremoteinfo=false,showmedium=true} -} -\DeclareOption{mla8}{% - \def\blopts{style=mla-new,noremoteinfo=false,showmedium=false} +\DeclareOption{mla7}{\def\@optMlaSeven} +\DeclareOption{mla8}{\def\@optMlaEight} +\DeclareOption{mla8alt}{\def\@optMlaEightAlt} +\DeclareOption*{% + \ClassWarning{mla}{Unknown option `\CurrentOption'; ignoring} } \ExecuteOptions{mla8} \ProcessOptions\relax @@ -55,14 +56,25 @@ \RequirePackage{fullpage} \RequirePackage{indentfirst} \RequirePackage{ragged2e} -\RequirePackage{times} +\RequirePackage{newtxtext} \RequirePackage{titlesec} \RequirePackage{xstring} \RequirePackage[american]{babel} \RequirePackage{csquotes} \RequirePackage{hanging} \RequirePackage[hidelinks,pdfusetitle]{hyperref} -\RequirePackage[\blopts,backend=biber]{biblatex} +\ifdefined\@optMlaSeven + \RequirePackage[style=mla,noremoteinfo=false,showmedium=true, + backend=biber]{biblatex} +\else + \ifdefined\@optMlaEightAlt + \RequirePackage[style=mla,noremoteinfo=false, + showmedium=false,backend=biber]{biblatex} + \else\ifdefined\@optMlaEight + \RequirePackage[style=mla-new,noremoteinfo=false, + showmedium=false,backend=biber]{biblatex} + \fi\fi +\fi \linespread{1.99} \hyphenpenalty 10000 \pretolerance 10000 |