diff options
Diffstat (limited to 'Master/texmf-dist/tex/latex/suftesi/suftesi.cls')
-rw-r--r-- | Master/texmf-dist/tex/latex/suftesi/suftesi.cls | 140 |
1 files changed, 107 insertions, 33 deletions
diff --git a/Master/texmf-dist/tex/latex/suftesi/suftesi.cls b/Master/texmf-dist/tex/latex/suftesi/suftesi.cls index 3c64676c990..b24f49e2c60 100644 --- a/Master/texmf-dist/tex/latex/suftesi/suftesi.cls +++ b/Master/texmf-dist/tex/latex/suftesi/suftesi.cls @@ -19,7 +19,7 @@ %% \NeedsTeXFormat{LaTeX2e}[2005/12/01] \ProvidesClass{suftesi} - [2013/03/05 v1.3 A class for typesetting theses, books and articles] + [2013/03/22 v1.5 A class for typesetting theses, books and articles] @@ -54,6 +54,7 @@ \newif\ifsuftesi@fewfootnotes \newif\ifsuftesi@partpage \newif\ifsuftesi@FSPL +\newif\ifsuftesi@periodicalaureo \DeclareOption{a5paper}{% \ClassError{suftesi}{Option 'a5paper' not available}} \DeclareOption{b5paper}{% @@ -78,7 +79,7 @@ \RequirePackage{geometry} \geometry{heightrounded} \define@choicekey{}{pagelayout}[\val\nr] - {standard,periodical,compact,supercompact,elements}[standard]{% + {standard,periodical,compact,supercompact,elements,periodicalaureo}[standard]{% \ifcase\nr\relax \DeclareRobustCommand{\SUF@chaptersize}{\Large} \geometry{% @@ -137,6 +138,18 @@ marginparwidth= 60pt, marginparsep= 18pt, outer= 90pt} +\or +\suftesi@periodicalaureotrue + \DeclareRobustCommand{\SUF@chaptersize}{\large} + \geometry{% + includeheadfoot=true, + textwidth= 120mm, + textheight= 194mm, + paperwidth= 17cm, + paperheight= 24cm, + marginratio= 1:2, + marginparwidth= 62pt, + marginparsep= 10pt} \fi} \define@choicekey{}{partstyle}[\val\nr]{% left,center,right,parleft,parcenter,parright}[left]{% @@ -585,35 +598,57 @@ dotarabic,dotroman,dotRoman}[arabic]{% \disable@keys{} {headerstyle,chapstyle,secfont,subsecfont} \or - \suftesi@FSPLtrue +\suftesi@periodicalaureotrue +\suftesi@FSPLtrue \setkeys{}{% - pagelayout=periodical, - style=roman1, - footnotestyle=superscript, + pagelayout=periodicalaureo, + style=roman5, + chapnumstyle=roman, + headerstyle=inner, + footnotestyle=hung, liststyle=indented, - tocstyle=ragged} -\or - \suftesi@FSPLtrue + tocstyle=leftpage} +\disable@keys{} +{documentstructure,pagelayout,partfont,chapfont,secfont,% +subsecfont,subsubsecfont,partstyle,chapstyle,secstyle,% +subsecstyle,subsubsecstyle,partnumstyle,chapnumstyle,% +secnumstyle,tocstyle,headerstyle,headerfont,quotestyle,% +quotesize,footnotestyle,liststyle,captionstyle,parindent} +\or +\suftesi@periodicalaureotrue +\suftesi@FSPLtrue \setkeys{}{% - pagelayout=periodical, + pagelayout=periodicalaureo, style=italic5, - headerstyle=center, chapnumstyle=roman, - secstyle=center, - quotestyle=right, + headerstyle=inner, footnotestyle=hung, liststyle=indented, - tocstyle=dotted} -\or - \suftesi@FSPLtrue + tocstyle=leftpage} +\disable@keys{} +{documentstructure,pagelayout,partfont,chapfont,secfont,% +subsecfont,subsubsecfont,partstyle,chapstyle,secstyle,% +subsecstyle,subsubsecstyle,partnumstyle,chapnumstyle,% +secnumstyle,tocstyle,headerstyle,headerfont,quotestyle,% +quotesize,footnotestyle,liststyle,captionstyle,parindent} +\or +\suftesi@periodicalaureotrue +\suftesi@FSPLtrue \setkeys{}{% - pagelayout=periodical, + pagelayout=periodicalaureo, style=smallcaps5, + chapnumstyle=roman, + headerstyle=inner, secfont=smallcaps, - headerstyle=center, - footnotestyle=dotted, + footnotestyle=hung, liststyle=indented, tocstyle=leftpage} +\disable@keys{} +{documentstructure,pagelayout,partfont,chapfont,secfont,% +subsecfont,subsubsecfont,partstyle,chapstyle,secstyle,% +subsecstyle,subsubsecstyle,partnumstyle,chapnumstyle,% +secnumstyle,tocstyle,headerstyle,headerfont,quotestyle,% +quotesize,footnotestyle,liststyle,captionstyle,parindent} \fi} \ExecuteOptionsX<>{ captionstyle=standard, @@ -652,6 +687,12 @@ dotarabic,dotroman,dotRoman}[arabic]{% \XKV@useoption{a5paper} \XKV@useoption{b5paper} \XKV@useoption{legalpaper}\XKV@useoption{executivepaper} \XKV@useoption{landscape} +\RequirePackage{expl3,l3regex} +\ExplSyntaxOn +\AtEndOfClass{ +\regex_replace_all:nnN { style \s* = [^,]*? , } { , } \XKV@classoptionslist +} +\ExplSyntaxOff \RequirePackage{color} \definecolor{sufred}{rgb}{0.5,0,0} \definecolor{sufgray}{rgb}{0.5,0.5,0.5} @@ -659,6 +700,7 @@ dotarabic,dotroman,dotRoman}[arabic]{% \RequirePackage{emptypage} \RequirePackage{textcase} \RequirePackage{ifxetex} +\RequirePackage{microtype} \ifsuftesi@FSPL \RequirePackage{cclicenses} \else @@ -666,7 +708,6 @@ dotarabic,dotroman,dotRoman}[arabic]{% \ifxetex \relax \else -\RequirePackage{microtype} \RequirePackage[LGR,T1]{fontenc} \AtBeginDocument{\fontencoding{T1}\selectfont} \ifsuftesi@standardfont @@ -773,6 +814,7 @@ dotarabic,dotroman,dotRoman}[arabic]{% {} \titlespacing*{\subsubsection}{0em}{\baselineskip}{\baselineskip}[0em] } +\newlength\SUF@ADJnumparchap \def\SUF@default@CHAPTER{ \ifsuftesi@numparchap \titleformat{\chapter}[display] @@ -788,9 +830,9 @@ dotarabic,dotroman,dotRoman}[arabic]{% {\SUF@CHAP@StyleSwitch} \fi \ifsuftesi@numparchap - \def\SUF@ADJnumparchap{-2.5\baselineskip} + \setlength{\SUF@ADJnumparchap}{-2.5\baselineskip} \else - \def\SUF@ADJnumparchap{0pt} + \setlength{\SUF@ADJnumparchap}{0pt} \fi} \def\SUF@default@SECTIONS{ \ifsuftesi@numparsec @@ -845,6 +887,10 @@ dotarabic,dotroman,dotRoman}[arabic]{% \RequirePackage{extramarks} \SUF@elements@CHAPTER \SUF@elements@SECTIONS +\ifsuftesi@periodicalaureo + \titlespacing*{\chapter}{0em}{-\baselineskip}{10pt}[0pt] + \setkeys[SUF]{elements}{chapsize=80,chapposition=-83} +\else \ifsuftesi@periodical \titlespacing*{\chapter}{0em}{-\baselineskip}{10pt}[0pt] \setkeys[SUF]{elements}{chapsize=80,chapposition=-83} @@ -863,6 +909,7 @@ dotarabic,dotroman,dotRoman}[arabic]{% \else \titlespacing*{\chapter}{0em}{-\baselineskip}{10pt}[0pt] \setkeys[SUF]{elements}{chapsize=90,chapposition=-83} + \fi \fi \fi \fi @@ -870,6 +917,10 @@ dotarabic,dotroman,dotRoman}[arabic]{% \else \SUF@default@CHAPTER \SUF@default@SECTIONS +\ifsuftesi@periodicalaureo + \titlespacing*{\chapter}{0em}{0\SUF@ADJnumparchap}{18ex} + \titlespacing*{name=\chapter,numberless}{0em}{0pt}{18ex} +\else \ifsuftesi@periodical \titlespacing*{\chapter}{0em}{\SUF@ADJnumparchap}{18ex} \titlespacing*{name=\chapter,numberless}{0em}{0pt}{18ex} @@ -885,10 +936,11 @@ dotarabic,dotroman,dotRoman}[arabic]{% \titlespacing*{\chapter}{0em}{% \dimexpr(6ex+\SUF@ADJnumparchap)}{18ex} \titlespacing*{name=\chapter,numberless}{0em}{6ex}{18ex} + \fi + \fi \fi \fi \fi -\fi \ifsuftesi@article \def\chapter#1{\ClassError{suftesi} {\noexpand\chapter level is undefined @@ -1417,7 +1469,6 @@ dotarabic,dotroman,dotRoman}[arabic]{% \item\relax \SUF@quotation@size} {\endlist} -\let\oldfootnote\footnote \ifsuftesi@fewfootnotes \AtBeginDocument{ \def\@fnsymbol#1{\ensuremath{\ifcase#1\or*\or{*}{*}\or{*}{*}{*}\or% @@ -1429,11 +1480,9 @@ dotarabic,dotroman,dotRoman}[arabic]{% \else\@ctrerr\fi}}} \def\thefootnote{\@fnsymbol\c@footnote}% \else\fi -\newcommand{\xfootnote}[2]{% - \begingroup - \addtocounter{footnote}{-1}% - \def\thefootnote{#1}\oldfootnote{#2}% - \endgroup} +\newcommand*\xfootnote[1][*]{% + \xdef\@thefnmark{#1}% + \@footnotemark\@footnotetext} \def\SUF@mpsetup{% \ifsuftesi@elementsheader\relax \else\itshape\fi @@ -1442,10 +1491,26 @@ dotarabic,dotroman,dotRoman}[arabic]{% \tolerance=2000 \hyphenpenalty=300 \exhyphenpenalty=300% \doublehyphendemerits=100000% \finalhyphendemerits=\doublehyphendemerits} -\let\oldmarginpar\marginpar -\renewcommand{\marginpar}[1]{\oldmarginpar% - [\SUF@mpsetup\raggedleft\hspace{0pt}{#1}]% - {\SUF@mpsetup\raggedright\hspace{0pt}{#1}}} + \let\oldmarginpar\marginpar + \renewcommand{\marginpar}[1]{\oldmarginpar% + [\SUF@mpsetup\raggedleft\hspace{0pt}{#1}]% + {\SUF@mpsetup\raggedright\hspace{0pt}{#1}}} +\AtBeginDocument{ +\@ifpackageloaded{todonotes}{% +\renewcommand{\@todonotes@drawMarginNoteWithLine}{% +\begin{tikzpicture}[remember picture, overlay, baseline=-0.75ex]% + \node [coordinate] (inText) {};% +\end{tikzpicture}% +\oldmarginpar[{% Draw note in left margin + \@todonotes@drawMarginNote% + \@todonotes@drawLineToLeftMargin% +}]{% Draw note in right margin + \@todonotes@drawMarginNote% + \@todonotes@drawLineToRightMargin% +}% +}% +} +{\relax}} \if@titlepage \newenvironment{abstract}{% \titlepage @@ -1508,6 +1573,7 @@ dotarabic,dotroman,dotRoman}[arabic]{% \end{minipage} \end{center} \vspace*{\stretch{6}}} +\ifsuftesi@FSPL \newcommand{\FSPLcolophon}[1][\the\year]{% \begingroup \thispagestyle{empty} @@ -1539,6 +1605,14 @@ Non si pu\`o alterare o trasformare quest'opera, n\'e usarla per crearne un'altr \end{description} \endgroup \clearpage} +\else +\def\FSPLcolophon{% + \ClassError{suftesi} + {\noexpand\FSPLcolophon is defined\MessageBreak + only for the FSPL styles} + {\noexpand\FSPLcolophon is defined\MessageBreak + only for the FSPL styles}} +\fi \RequirePackage{titletoc} \newlength\SUF@label@chapter \setlength\SUF@label@chapter{.5em} |