summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/fithesis/fithesis3.cls
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2015-11-19 22:40:04 +0000
committerKarl Berry <karl@freefriends.org>2015-11-19 22:40:04 +0000
commitc97eafc789593a5348cff6033c58c3bfb0beab19 (patch)
tree82eff5de594cf23b8184ae8791391bb1bfb861c1 /Master/texmf-dist/tex/latex/fithesis/fithesis3.cls
parent52b5b5df295683036612072db256172356408bf9 (diff)
fithesis (19nov15)
git-svn-id: svn://tug.org/texlive/trunk@38893 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/fithesis/fithesis3.cls')
-rw-r--r--Master/texmf-dist/tex/latex/fithesis/fithesis3.cls57
1 files changed, 34 insertions, 23 deletions
diff --git a/Master/texmf-dist/tex/latex/fithesis/fithesis3.cls b/Master/texmf-dist/tex/latex/fithesis/fithesis3.cls
index 438517bbb6e..57189e68349 100644
--- a/Master/texmf-dist/tex/latex/fithesis/fithesis3.cls
+++ b/Master/texmf-dist/tex/latex/fithesis/fithesis3.cls
@@ -50,13 +50,16 @@
%% The names of the source files used are shown above.
%%
\NeedsTeXFormat{LaTeX2e}
-\def\thesis@version{2015/10/14 v0.3.23 fithesis3 MU thesis class}
+\def\thesis@version{2015/11/17 v0.3.24 fithesis3 MU thesis class}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\ProvidesClass{fithesis3}[\thesis@version]
-\LoadClass[a4paper]{rapport3}
+\ifx\thesis@backend\undefined
+ \def\thesis@backend{[a4paper]{rapport3}}
+\fi\expandafter\LoadClass\thesis@backend
\RequirePackage{keyval}
\RequirePackage{etoolbox}
+\RequirePackage{ltxcmds}
\RequirePackage{ifxetex}
\RequirePackage{ifluatex}
\ifxetex\else\ifluatex\else
@@ -228,24 +231,28 @@
\endgroup\thesis@locale@inheritancefalse
\fi}
\def\thesis@parseDate#1/#2/#3|{{
- % Basic info
+ % Set the basic macros
\gdef\thesis@date{#1/#2/#3}%
\gdef\thesis@year{#1}%
\gdef\thesis@month{#2}%
\gdef\thesis@day{#3}%
- % Season and academic year
- \newcount\@year \expandafter\@year \thesis@year \relax%
- \newcount\@month\expandafter\@month\thesis@month\relax%
- \ifnum\@month<7%
- \gdef\thesis@season{winter}%
- \advance\@year-1\edef\@yearA{\the\@year}%
- \advance\@year 1\edef\@yearB{\the\@year}%
- \else%
- \gdef\thesis@season{summer}%
+ % Set the season
+ \newcount\@month\expandafter\@month\thesis@month\relax
+ \ifnum\@month>8\gdef\thesis@season{fall}
+ \else\ifnum\@month<3\gdef\thesis@season{fall}
+ \else \gdef\thesis@season{spring}
+ \fi\fi
+
+ % Set the academic year
+ \newcount\@year\expandafter\@year\thesis@year\relax
+ \ifnum\@month>8%
\edef\@yearA{\the\@year}%
\advance\@year 1\edef\@yearB{\the\@year}%
- \fi%
+ \else
+ \advance\@year-1\edef\@yearA{\the\@year}%
+ \advance\@year 1\edef\@yearB{\the\@year}%
+ \fi
\global\edef\thesis@academicYear{\@yearA/\@yearB}}}
\edef\thesis@date{\the\year/\the\month/\the\day}%
@@ -313,6 +320,7 @@
\thesis@loadedtrue
\makeatletter%
\ifx\thesis@locale\empty\else
+ \thesis@requireLocale{\thesis@locale}
\thesis@selectLocale{\thesis@locale}
\fi
\ifx\thesis@style\empty\else
@@ -355,14 +363,14 @@
% Ignore redundant requests
\expandafter\ifx\csname thesis@#1@required\endcsname\relax%
\expandafter\def\csname thesis@#1@required\endcsname{}%
- {\makeatletter % Enable requiring from within the document
- \thesis@input{\thesis@localepath fithesis-#1.def}%
- \ifthesis@locale@inheritance%
- \thesis@input{\thesis@localepath\thesis@university/%
- fithesis-#1.def}%
- \thesis@input{\thesis@localepath\thesis@university/%
- \thesis@faculty/fithesis-#1.def}%
- \fi}
+ \@ifpackageloaded{polyglossia}{\setotherlanguage{#1}}{}
+ \thesis@input{\thesis@localepath fithesis-#1.def}%
+ \ifthesis@locale@inheritance%
+ \thesis@input{\thesis@localepath\thesis@university/%
+ fithesis-#1.def}%
+ \thesis@input{\thesis@localepath\thesis@university/%
+ \thesis@faculty/fithesis-#1.def}%
+ \fi
\fi}
\def\thesis@#1{\csname thesis@#1\endcsname}
\def\thesis@@#1{\thesis@{\thesis@locale @#1}}
@@ -396,8 +404,11 @@
\ifx\thesis@pages\undefined\def\thesis@pages{??}\fi
\def\thesis@selectLocale#1{%
\edef\thesis@locale{#1}%
- \thesis@requireLocale{\thesis@locale}%
- \expandafter\language\csname l@\thesis@locale\endcsname}
+ \ltx@ifpackageloaded{polyglossia}{%
+ \selectlanguage{\thesis@locale}
+ }{%
+ \language\csname l@\thesis@locale\endcsname
+ }}
\endinput
%%
%% End of file `fithesis3.cls'.