Changed the handling of the "sans" and "roman" class options, to be reflected at the beginning of the document and override style font choices

This commit is contained in:
Xavier Danaux
2012-07-29 14:25:16 +02:00
parent a2fc3c3623
commit 5872ae6b68
10 changed files with 3 additions and 3 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -51,15 +51,15 @@
\DeclareOption{12pt}{\renewcommand\@ptsize{2}} \DeclareOption{12pt}{\renewcommand\@ptsize{2}}
% font type options % font type options
\DeclareOption{sans}{\renewcommand{\familydefault}{\sfdefault}} \DeclareOption{sans}{\AtBeginDocument{\renewcommand{\familydefault}{\sfdefault}}}
\DeclareOption{roman}{\renewcommand{\familydefault}{\rmdefault}} \DeclareOption{roman}{\AtBeginDocument{\renewcommand{\familydefault}{\rmdefault}}}
% draft/final option % draft/final option
\DeclareOption{draft}{\setlength\overfullrule{5pt}} \DeclareOption{draft}{\setlength\overfullrule{5pt}}
\DeclareOption{final}{\setlength\overfullrule{0pt}} \DeclareOption{final}{\setlength\overfullrule{0pt}}
% execute default options % execute default options
\ExecuteOptions{a4paper,11pt,sans,final} \ExecuteOptions{a4paper,11pt,final}
% process given options % process given options
\ProcessOptions\relax \ProcessOptions\relax