summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/fancyhdr/fancyhdr.sty
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2016-08-28 22:16:40 +0000
committerKarl Berry <karl@freefriends.org>2016-08-28 22:16:40 +0000
commitdec9524f80a61822aa1c7d7e69152592d2ee928e (patch)
treecd1602a586b8137890e55a78502cac990bcdfbca /Master/texmf-dist/tex/latex/fancyhdr/fancyhdr.sty
parentc9b7f7b7795573aaf969d827eb0cb9befcb7b201 (diff)
fancyhdr (28aug16)
git-svn-id: svn://tug.org/texlive/trunk@41944 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/fancyhdr/fancyhdr.sty')
-rw-r--r--Master/texmf-dist/tex/latex/fancyhdr/fancyhdr.sty56
1 files changed, 42 insertions, 14 deletions
diff --git a/Master/texmf-dist/tex/latex/fancyhdr/fancyhdr.sty b/Master/texmf-dist/tex/latex/fancyhdr/fancyhdr.sty
index 77ed4e3012d..11b894e713d 100644
--- a/Master/texmf-dist/tex/latex/fancyhdr/fancyhdr.sty
+++ b/Master/texmf-dist/tex/latex/fancyhdr/fancyhdr.sty
@@ -1,9 +1,9 @@
-% fancyhdr.sty version 3.2
+% fancyhdr.sty version 3.6
% Fancy headers and footers for LaTeX.
% Piet van Oostrum,
-% Dept of Computer and Information Sciences, University of Utrecht,
-% Padualaan 14, P.O. Box 80.089, 3508 TB Utrecht, The Netherlands
-% Telephone: +31 30 2532180. Email: piet@cs.uu.nl
+% [Formerly] Dept of Computer and Information Sciences, University of Utrecht,
+% Email: piet@vanoostrum.org
+% WWW: http://www.pietvanoostrum.com
% ========================================================================
% LICENCE:
% This file may be distributed under the terms of the LaTeX Project Public
@@ -145,6 +145,29 @@
% reset \everypar (the real one) in \fancy@reset because spanish.ldf does
% strange things with \everypar between << and >>.
+% Aug 20, 2016
+% version 3.3
+% Replace `\@ifundefined{chapter}' with `\ifx\chapter\@undefined'
+% because the former subtly make \chapter equal to \relax, which may be
+% undesirable in some cases.
+
+% Aug 21, 2016
+% version 3.4
+% Replace \rm by \normalfont\rmfamily
+% and \sl by \normalfont\slshape
+
+% Aug 21, 2016
+% version 3.5
+% Don't define \footruleskip if it is already defined
+
+% Aug. 27, 2016
+% version 3.6
+% Added a \ProvidesPackage line.
+% Updated contact information.
+
+\NeedsTeXFormat{LaTeX2e}[1995/06/01]%
+\ProvidesPackage{fancyhdr}[2016/08/27 3.6 Extensive control of page headers and footers]%
+
\def\ifancy@mpty#1{\def\temp@a{#1}\ifx\temp@a\@empty}
\def\fancy@def#1#2{\ifancy@mpty{#2}\fancy@gbl\def#1{\leavevmode}\else
@@ -299,7 +322,9 @@
\newlength{\f@ncyO@orf}
\newcommand{\headrulewidth}{0.4pt}
\newcommand{\footrulewidth}{0pt}
-\newcommand{\footruleskip}{.3\normalbaselineskip}
+%% Memoir also define \footruleskip.
+%% Don't define \footruleskip if it is already defined
+\@ifundefined{footruleskip}{\newcommand{\footruleskip}{.3\normalbaselineskip}}{}
% Fancyplain stuff shouldn't be used anymore (rather
% \fancypagestyle{plain} should be used), but it must be present for
@@ -337,13 +362,13 @@
% lefthead empty on ``plain'' pages, \rightmark on even, \leftmark on odd pages
% evenhead empty on ``plain'' pages, \leftmark on even, \rightmark on odd pages
\if@twoside
- \fancyhead[el,or]{\fancyplain{}{\sl\rightmark}}
- \fancyhead[er,ol]{\fancyplain{}{\sl\leftmark}}
+ \fancyhead[el,or]{\fancyplain{}{\normalfont\slshape\rightmark}}
+ \fancyhead[er,ol]{\fancyplain{}{\normalfont\slshape\leftmark}}
\else
- \fancyhead[l]{\fancyplain{}{\sl\rightmark}}
- \fancyhead[r]{\fancyplain{}{\sl\leftmark}}
+ \fancyhead[l]{\fancyplain{}{\normalfont\slshape\rightmark}}
+ \fancyhead[r]{\fancyplain{}{\normalfont\slshape\leftmark}}
\fi
-\fancyfoot[c]{\rm\thepage} % page number
+\fancyfoot[c]{\normalfont\rmfamily\thepage} % page number
% Use box 0 as a temp box and dimen 0 as temp dimen.
% This can be done, because this code will always
@@ -396,15 +421,18 @@
% the version 1 documentation) will still work.
%
\@ifundefined{MakeUppercase}{\def\MakeUppercase{\uppercase}}{}%
-\@ifundefined{chapter}{\def\sectionmark##1{\markboth
+\ifx\chapter\@undefined
+\def\sectionmark##1{\markboth
{\MakeUppercase{\ifnum \c@secnumdepth>\z@
\thesection\hskip 1em\relax \fi ##1}}{}}%
\def\subsectionmark##1{\markright {\ifnum \c@secnumdepth >\@ne
- \thesubsection\hskip 1em\relax \fi ##1}}}%
-{\def\chaptermark##1{\markboth {\MakeUppercase{\ifnum \c@secnumdepth>\m@ne
+ \thesubsection\hskip 1em\relax \fi ##1}}%
+\else
+\def\chaptermark##1{\markboth {\MakeUppercase{\ifnum \c@secnumdepth>\m@ne
\@chapapp\ \thechapter. \ \fi ##1}}{}}%
\def\sectionmark##1{\markright{\MakeUppercase{\ifnum \c@secnumdepth >\z@
- \thesection. \ \fi ##1}}}}%
+ \thesection. \ \fi ##1}}}%
+\fi
%\csname ps@headings\endcsname % use \ps@headings defaults if they exist
\ps@@fancy
\gdef\ps@fancy{\@fancyplainfalse\ps@@fancy}%