### mparticle and mpreport

The mparticle and mpreport LaTeX document classes are attempts at a more modern layout for articles and reports. See my dissertation or my master's thesis for examples of documents formatted with mpreport.

The latest changes:

• Avoid incrementing the footnote counter in captions. This means that you can now use \footnotemark in captions with the same behavior as in the standard classes. (mparticle 1.19, mpreport 1.23)

• Let the footnote mark in the text inherit the font and style of the text. In the standard classes, the footnote mark is always in the serif font. (mparticle 1.19, mpreport 1.23)

• Corrected the calculation of \textwidth and \mp@margwd, so that for A4 paper, you should get exactly the same layout as with mparticle 1.16. (mparticle 1.18)

• Corrected the calculation of \textwidth and \mp@margwd, so that for A4 paper, you should get exactly the same layout as with mpreport 1.20. (mpreport 1.22)

• mparticle now works with other page sizes. You can specify something like a5paper or letterpaper or use the geometry package for custom page sizes (including landscape). (mparticle 1.17)

• mparticle is now compatible with nameref. (mparticle 1.17)

• mpreport now works with other page sizes. You can specify something like a5paper or letterpaper or use the geometry package for custom page sizes (including landscape). (mpreport 1.21)

• mpreport is now compatible with nameref. (mpreport 1.21)

• mpreport now also redefines \and to be useful with the redefined \maketitle (as in mparticle since 1.16). (mpreport 1.21)

• If a chapter ends on a right page, there will be an empty page before the following chapter; don't number this page. (mpreport 1.20)

• Experimental for footnotes with hanging indent (use \mp@setfnhangindent{2em} to use this style). (mpreport 1.20)

• Put date below the author name(s). (mparticle 1.16)

• Redefine \and to be useful with the redefined \maketitle. (mparticle 1.16)

• Section titles should not be separated from the following text. (mpreport 1.19 and mparticle 1.15)

• Footnote separator character is now defined in \mp@fnsep, so that it can be redefined. (mpreport 1.19 and mparticle 1.15)

• Chapter definition fixed: The optional argument (short title) didn't work. (mpreport 1.19)

• The space after the footnote number was missing. (mparticle 1.14 and mpreport 1.18)

• It seems that we've finally managed to fix the problem that, depending on the font, there could be a gap between the two rules (the long one and the short one) above chapters. (mpreport 1.17)

• The definition of \@chapter was missing the call to \chaptermark, which broke headers. Now that headers are working, also added definitions for all standard page styles. (mpreport 1.16)

• Finally, footnotes are indicated with full figures, not superscript figures. (mparticle 1.13 and mpreport 1.16)

• Reduce the use of slanted text.

• Put marginnotes always in the left margin and make their style match that of captions.

• Set \parskip in the definition of chapters and sections to ensure that the rules are drawn correctly and to allow users to set \parskip for their document. (Before, when a user said, e.g., \parskip2.5ex, there would be a gap between the long thin rule and the short thick rule above the chapter title, and the distance between the rule above the section title and the section title itself would become too large.)

• In the definition of \section, moved \addcontentsline after \sectionmark. If the section happened to start on a new page, the table of contents would list the number of the previous page.

#### Using longtable with mpreport

There are apparently a number of people who are using the longtable package with mpreport and who would like to have the longtable captions look like the other captions. My current suggestion is to put the following in the preamble of your document:

\makeatletter
\setlength\LTleft{0pt}
\setlength\LTright{0pt}

\renewcommand{\LT@makecaption}[3]{%
\LT@mcol\LT@cols l{%
\settoheight{\mp@capht}%
{\parbox[b]{.9\mp@margwd}{\raggedleft\sffamily\slshape\small#1{#2}: #3}}%
\hspace{-\mp@margwd}%
\vspace{-\mp@capht}%
\parbox[t]{.9\mp@margwd}{\raggedleft\sffamily\slshape\small#1{#2}: #3}%
}
}
\makeatother


This worked fine in my tests, but I haven't tried it with “real” tables. If you're using this definition, successfully or not, I'd appreciate feedback.

#### Using listings with mpreport

If you want the captions of listings created with the listings package to appear in the margin, try this definition in the preample of your document:

\makeatletter
\renewcommand{\lst@MakeCaption}[1]{
\lst@ifdisplaystyle
\ifx #1t%
\ifx\lst@@caption\@empty\expandafter\lst@HRefStepCounter \else
\expandafter\refstepcounter
\fi {lstlisting}%
\ifx\lst@label\@empty\else \label{\lst@label}\fi
\let\lst@arg\lst@intname \lst@ReplaceIn\lst@arg\lst@filenamerpl
\global\let\lst@name\lst@arg \global\let\lstname\lst@name
\lst@ifnolol\else
\ifx\lst@@caption\@empty
\ifx\lst@caption\@empty
\ifx\lst@intname\@empty \else \def\lst@temp{ }%
\ifx\lst@intname\lst@temp \else
\fi\fi
\fi
\else
{\protect\numberline{\thelstlisting}\lst@@caption}%
\fi
\fi
\fi
\ifx\lst@caption\@empty\else
\lst@IfSubstring #1\lst@captionpos
{\begingroup \let\@@vskip\vskip
\def\vskip{\afterassignment\lst@vskip \@tempskipa}%
\def\lst@vskip{\nobreak\@@vskip\@tempskipa\nobreak}%
\par\@parboxrestore\normalsize\normalfont % \noindent (AS)
\ifx #1t\allowbreak \fi
\ifx\lst@title\@empty
\settoheight{\mp@capht}%
{\parbox[b]{.9\mp@margwd}{\raggedleft\sffamily\slshape\small%
\lst@makecaption\fnum@lstlisting\lst@caption}}%

\hspace{-\mp@margwd}%
\vspace{-\mp@capht}%
\parbox[t]{.9\mp@margwd}{\raggedleft\sffamily\slshape\small%
\lst@makecaption\fnum@lstlisting\lst@caption}%

% \lst@makecaption\fnum@lstlisting\lst@caption % (AS)
\else
\lst@maketitle\lst@title % (AS)
\fi
\ifx #1b\allowbreak \fi
\endgroup}{}%
\fi
\fi
}
\makeatother


### mapcodes

mapcodes is a LaTeX package that allows to use various 8-bit codesets in LaTeX documents (similar to inputenc, but it works better in some situations, IMHO):