% \iffalse meta-comment % % Copyright (C) 2009-2012 by Ivan Valbusa % % ------------------------------------------------------- % % This work may be distributed and/or modified under the % conditions of the LaTeX Project Public License, either version 1.3 % of this license or (at your option) any later version. % The latest version of this license is in % http://www.latex-project.org/lppl.txt % and version 1.3 or later is part of all distributions of LaTeX % version 2005/12/01 or later. % % This work consists of all files listed in README % % \fi % % \iffalse %<*driver> \ProvidesFile{suftesi.dtx} % %\NeedsTeXFormat{LaTeX2e}[2005/12/01] %\ProvidesClass{suftesi} %<*class> [2012/04/22 v0.9 A class for typesetting theses, books and articles] % %<*driver> \PassOptionsToClass{a4paper}{article} % we need a4paper \documentclass{ltxdoc} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage[polutonikogreek,english]{babel} \let\cs\relax \let\cmd\relax \usepackage{ltxdockit} \usepackage{fourier} \usepackage{xcolor} \usepackage{graphicx} \usepackage{array,booktabs,multirow} \usepackage{microtype} \usepackage{siunitx} \usepackage{metalogo} \usepackage[suftesi]{frontespizio} \usepackage[style=philosophy-classic]{biblatex} \addbibresource{suftesi.bib} \usepackage{hyperref} \hypersetup{% pdftitle={User's Guide to \sty{suftesi}}, pdfsubject={A document class for typesetting theses, books and articles}, pdfauthor={Ivan Valbusa}, pdfkeywords={thesis, humanities, books}, citecolor=spot} \newcommand{\ttchar}[1]{{\normalfont\ttfamily\char`#1}} \newcommand{\frontoption}[1]{\subsection*{\texttt{#1}}} \newcommand{\includeex}[1]{\par\vfill\begin{center} \setlength{\fboxsep}{0pt}\fbox{\includegraphics[scale=.3]{#1}} \end{center}} \DeclareRobustCommand*{\ar}[1]{\texttt{\char`\{#1\char`\}}} \DeclareRobustCommand*{\oar}[1]{\texttt{[#1]}} \DeclareRobustCommand*{\meta}[1]{% $\langle${\normalfont\itshape#1\kern0.12em }$\rangle$} \DeclareRobustCommand*{\arm}[1]{\ar{\meta{#1}}} \DeclareRobustCommand*{\oarm}[1]{\oar{\meta{#1}}} \newcommand{\quoteskip}{.5\baselineskip plus .1\baselineskip minus .1\baselineskip} \newlength{\normalparindent} \setlength{\normalparindent}{\parindent} \newenvironment{genquote}[1][] {\par\nobreak \addvspace{\quoteskip} \parindent0pt \hangafter0 \hangindent2\normalparindent #1} {\par\addvspace{\quoteskip}\noindent\ignorespacesafterend} \newenvironment{ttquote} {\genquote[\ttfamily\microtypesetup{activate=false}]} {\endgenquote} \EnableCrossrefs \CodelineIndex \RecordChanges \begin{document} \DocInput{suftesi.dtx} \end{document} % % \fi % % \CheckSum{1747} % % \CharacterTable % {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z % Lower-case \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z % Digits \0\1\2\3\4\5\6\7\8\9 % Exclamation \! Double quote \" Hash (number) \# % Dollar \$ Percent \% Ampersand \& % Acute accent \' Left paren \( Right paren \) % Asterisk \* Plus \+ Comma \, % Minus \- Point \. Solidus \/ % Colon \: Semicolon \; Less than \< % Equals \= Greater than \> Question mark \? % Commercial at \@ Left bracket \[ Backslash \\ % Right bracket \] Circumflex \^ Underscore \_ % Grave accent \` Left brace \{ Vertical bar \| % Right brace \} Tilde \~} % % \changes{v0.9a}{2012/05/05}{Changed code for toc, lot and lof elements} % \changes{v0.9}{2012/04/22}{Added \opt{dottedtoc} and \opt{raggedtoc} options. Improved compatibility with \sty{mathspec}} % \changes{v0.8}{2012/03/19}{Added macro for using \sty{frontespizio} package with \opt{compact} and \opt{supercompact} options. Added option \opt{periodical}. Renewed \cmd{title} command} % \changes{v0.7}{2011/02/05}{Maintenance release, no changes. Provided a thesis template} % \changes{v0.6c}{2011/11/16}{Maintenance release, no changes} % \changes{v0.6b}{2011/11/07}{Improved full compatibility with \XeLaTeX. % \sty{varioref} and \sty{footmisc} packages are no longer loaded} % \changes{v0.6a}{2011/10/24}{Maintenance release, no changes} % \changes{v0.6}{2011/10/21}{Added commands \cmd{bookcolophon}, \cmd{artcolophon}. Added option \opt{authortitle}. Renamed options \opt{plain} and \opt{fullplain} to \opt{centerheadings} and \opt{sufplain}. New english documentation.} % \changes{v0.5}{2011/10/21}{First public release. The frontispiece of \sty{suftesi}{} is now % included in the package \sty{frontespizio}. New command \cmd{chapnumfont}. % Added options \opt{article}, \opt{fullplain}, \opt{elements}, \opt{sufelements}, % \opt{supercompact}, \opt{compact}, \opt{nocrop}, \opt{nomarginpar}. % Changed option \opt{sctitles}.} % \GetFileInfo{suftesi.dtx} % % \DoNotIndex{\newcommand,\newenvironment,\def,\begin,\vskip,\ } % \DoNotIndex{\DeclareOption,\ExecuteOptions,\RequirePackage} % \DoNotIndex{\@@end,\@empty,\@ifclassloaded,\@nameuse,\@nil} % \DoNotIndex{\@undefined,\\,\`,\addtocounter,\advance,\bfseries} % \DoNotIndex{\centering,\closeout,\define@key,\documentclass} % \DoNotIndex{\edef,\else,\end,\endinput,\endtitlepage,\expandafter} % \DoNotIndex{\extracolsep,\fi,\fill,\fontsize,\g@addto@macro,\toks} % \DoNotIndex{\hrule,\hspace,\if,\if@twoside,\ifcase,\ifdefined} % \DoNotIndex{\iffalse,\IfFileExists,\ifnum,\ifx,\immediate,\setcounter} % \DoNotIndex{\jobname,\let,\long,\MakeUppercase,\MessageBreak} % \DoNotIndex{\newcount,\newif,\newpage,\newtoks,\newwrite,\next} % \DoNotIndex{\noexpand,\nofiles,\normalfont,\normalsize,\null} % \DoNotIndex{\openout,\or,\styage,\styageError,\styageWarning} % \DoNotIndex{\styageWarningNoLine,\paperheight,\paperwidth,\par} % \DoNotIndex{\parbox,\parindent,\relax,\scshape,\selectfont,\setkeys} % \DoNotIndex{\sffamily,\space,\stretch,\string,\textheight,\textwidth} % \DoNotIndex{\the,\thispagestyle,\unexpanded,\unless,\unskip,\upshape} % \DoNotIndex{\usepackage,\vbox,\vfill,\vspace,\write,\z@} % \DoNotIndex{\CurrentOption,\AtEndDocument,\@ne,\c@page,\m@ne} % \DoNotIndex{\@firstofone,\@gobble,\@makeother,\begingroup,\endgroup} % \DoNotIndex{\eTeXversion,\hbox,\hsize,\includegraphics,\newlinechar} % \DoNotIndex{\titlepage,\vss,\vtop,\xdef,\@gobbletwo,\color,\dimexpr} % \DoNotIndex{\huge,\large,\makebox,\ProcessOptions,\renewcommand} % % \title{\bfseries User's Guide to \textsf{suftesi}\thanks{This % document corresponds to \textsf{suftesi}~\fileversion{} dated \filedate}\\ % \large A document class for typesetting theses, books and articles} % \author{Ivan Valbusa \\ % \texttt{ivan dot valbusa at univr dot it}} % \date{\filedate} % \maketitle % \begin{abstract} % The \sty{suftesi} % class % provides a set of page layouts, title styles and heading styles for % typesetting theses, books and articles. It is based on the standard % \sty{book} class and inspired by the works of % \textcite{Bringhurst:1996}, \textcite{Tschichold:1975} and % \textcite{Morison:1111}. See the template file \file{tesi.tex} in the \file{example} folder. % \end{abstract} % % \tableofcontents % % \section*{Note on copyright} % % Copyright \copyright\ 2009-2010 Ivan Valbusa. This package is % author-maintained. Permission is granted to copy, distribute and/or % modify this software under the terms of the LaTeX Project Public % License, version % 1.3c.\footnote{\url{http://www.ctan.org/tex-archive/macros/latex/base/lppl.txt}.} % % In addition to the terms of this license the author requires an % attribution notice like the following one: % \begin{center} % \emph{This work has been typeset with \LaTeX{}, using the % \textsf{suftesi} class by Ivan Valbusa.}\footnote{You can use the \cmd{colophon}, \cmd{bookcolophon} or % \cmd{artcolophon} commands explained in section \ref{sec:commands}.} % \end{center} % % The most important feature of this class is the set of styles it % provides. For this reason: % % \begin{center} % \textbf{\textsc{do not modify the styles of this class\\ % if you do not like these styles, use another class.}} % \end{center} % % If you use \sty{suftesi}{} in a document typeset with another class % (for example \sty{book}), remember to clean up the preamble from all % the layout redefinitions. % % % \subsection*{Loaded packages} % % % The class loads the following packages: \sty{beramono}, \sty{calc}, % \sty{caption}, \sty{color}, \sty{enumitem}, \sty{emptypage}, % \sty{epigraph}, \sty{fancyhdr}, \sty{fontenc}, \sty{geometry}, % \sty{ifluatex}, \sty{ifxetex}, \sty{iwona}, \sty{mathpazo}, \sty{microtype}, % \sty{mparhack}, \sty{multicol}, % \sty{textcase}, \sty{titlesec}, \sty{titletoc}. % % \section{Class features} % % \subsection{Layout} % % The standard document classes allow you to typeset beautiful % documents but their layout is quite far from the stylistic requests % of some humanists (especially italian). The styles provided by % \sty{suftesi} are very simple and sober, and also have the aim of % finding in the formal simplicity an aesthetic harmony. They are % largely inspired by some beautiful readings, particularly % \textcite{Bringhurst:1996}, \textcite{Tschichold:1975} and % \textcite{Morison:1111}. Table~\ref{tab:gabbia} summarizes the main % features of the styles provided by \sty{suftesi}. % \begin{table}[h] % \small\centering % \caption[The layout]{The layouts of \sty{suftesi}} % \label{tab:gabbia} % \begin{tabular}{p{2cm}cccccc} % \toprule % & \multicolumn{5}{c}{Option (pt)}\\\cmidrule{2-7} % & (default) & \opt{11pt} & \opt{compact} & \opt{supercompact} & \opt{elements} & \opt{periodical} \\\cmidrule(lr){1-1}\cmidrule(lr){2-7} % Text width & $312$ & $324$ & $312$ & $284$ & $251$ & $312$\\ % Text height & $624$ & $648$ & $470$ & $430$ & $502$& $470$\\ % Marginal notes width & $82$ & $82$ & $65$ & $50$ & $60$& $70$\\[4ex] % Margins &\multicolumn{6}{c}{Proportions}\\\cmidrule(lr){1-1}\cmidrule{2-7} % \multirow{2}*{{\parbox{2cm}{top/bottom\\inner/outer}}} % & $1/2$ & $1/2$ & $2/3$ & $2/3$& $2/5$& $2/3$ \\ % &$1/2$&$1/2$ & $2/3$ & $2/3$ & $1/2$& $2/3$\\\cmidrule(lr){1-1} % Text block & $1/2$& $1/2$ & $2/3$ & $2/3$ & $1/2$& $2/3$\\ % Page & $1/\sqrt{2}$& $1/\sqrt{2}$ & $2/3$ & $2/3$ & $1/\sqrt{3}$& $1/\sqrt{2}$\\ % \bottomrule % \end{tabular} % \end{table} % % \subsection{Font} % % The default font for body text is % Palatino designed by Hermann Zapf\index{Zapf, Hermann}.\footnote{Using \XeLaTeX{} % the \LaTeX{} default font is loaded and the font options are turned off.} % The sans serif font is Iwona designed by Janusz M.~Nowacki\index{Nowacki, Janusz M.}. % This choice is inspired by \emph{L'arte di scrivere con \LaTeX{}} \parencite{Pantieri:2011}. % % \subsubsection{Using different fonts} % % If you prefer to use other fonts (such as those provided by \sty{fourier}, % \sty{lmodern} or \sty{libertine} packages), remember to load the class option \opt{defaultfont}, % which turns off the \sty{suftesi}{} font settings. Moreover pay particular attention % in choosing the greek font. % % \subsubsection{Greek alphabet} % % The default font for the greek text is Artemisia by the Greek Font Society, % which is very suitable for Palatino: % \begin{quotation} % Alla Natura che ogni cosa dona e ogni cosa riprende \dots % \begin{otherlanguage*}{polutonikogreek}% % \fontfamily{artemisia}\selectfont % Pr`epei na skeftoume mia % sunarthsh ths opoias % gnwrizoume oti uparqei % to oloklhrwma. % \end{otherlanguage*} % \end{quotation} % With the \opt{porson} option you can use the Porson font by the Greek Font Society: % \begin{quotation} % Alla Natura che ogni cosa dona e ogni cosa riprende \dots % \begin{otherlanguage*}{greek}% % \fontfamily{porson}\selectfont % Prepei na skeftoume mia % sunarthsh ths opoias % gnwrizoume oti uparqei % to oloklhrwma. % \end{otherlanguage*} % \end{quotation} % The \opt{defaultgreek} option allows you to use the standard CB Greek % font:\footnote{This option is also activated by the \opt{defaultfont} option % (see section \ref{sec:options}).} % \begin{quotation} % Alla Natura che ogni cosa dona e ogni cosa riprende \dots{} % \begin{otherlanguage*}{greek}% % \fontfamily{lmr}\selectfont % Prepei na skeftoume mia % sunarthsh ths opoias % gnwrizoume oti uparqei % to oloklhrwma. % \end{otherlanguage*} % \end{quotation} % % \subsection{Frontispiece} % % The class has a original frontispiece now directly available loading the % \sty{frontespizio} package \parencite{Gregorio:frontespizio}\footnote{Version 1.4 or later.} % with the \opt{suftesi} option (see the template file \file{tesi.tex} in the \file{example} folder): % \begin{ttquote} % \cmd{usepackage}[suftesi]\ar{frontespizio} % \end{ttquote} % %\section{Options}\label{sec:options} % %In addition to the options defined by the \sty{book} document class, \sty{suftesi} accepts the following new options. % %\subsection{Page layout} % % \begin{ltxsyntax} % \optitem{dottedtoc} Prints a standard table of contents with dotted lines. % \optitem{raggedtoc} Aligns the table of contents on the left as \textcite{Bringhurst:1996} suggests. % \optitem{compact} % Prints a typeblock of $16 \si{cm} \times 24 \si{cm}$ on a A4 paper, % showing the crop marks (see table \ref{tab:gabbia} for details). % The \cmd{crop[off]} command turns off the crop marks. % \optitem{supercompact} The same as \opt{compact} but with a typeblock % of $14 \si{cm} \times 21 \si{cm}$ (see table \ref{tab:gabbia} for details). % \optitem{periodical} % The same as \opt{compact} but with a typeblock of $17 \si{cm} \times 24 \si{cm}$ (see table \ref{tab:gabbia} for details). This style is expecially thought for theses. % \optitem{elements} % Reproduces the layout of \citetitle{Bringhurst:1996} by Robert \citeauthor{Bringhurst:1996} % (see table \ref{tab:gabbia} for details). % \optitem{nocrop} % Prints a \textsc{pdf} with page dimensions according to the \opt{compact}, % \opt{supercompact} and \opt{elements} options. % \optitem{nomarginpar} Disables the \cmd{marginpar} command. % This option is useful for the three ``compact'' layouts. % \optitem{11pt} % Sets the font size at $11\si{pt}$ and resizes the text block dimensions. % \end{ltxsyntax} % %\subsection{Titles and headings} % % \begin{ltxsyntax} % \optitem{sctitles} % Prints the headings and the chapter (section) titles in small caps. % \optitem{centertitle} % Centers the chapter title and number, with the chapter title below the number. % \optitem{sufelements} % Loads the \opt{sctitles} class option and prints the chapter numbers according to % the \opt{elements} option. % \optitem{centerheadings} % Prints the page number in the center of the footer, the string ``Chapter $n$'' % in the header of even pages and the chapter title in the header of odd pages. % \optitem{sufplain} % Prints no headers and puts the page number in the center of the footer. % \optitem{authortitle} % Changes the content of the headings. It prints the author's name on the even % numbered pages and the title on the odd ones. This option can be combined % with the other options seen above. In order to use this option the \cmd{title} and % \cmd{author} commands are required. % \optitem{article} % This option is aimed to typeset articles or short theses (that is to say without chapter divisions) % in a two side document. % \optitem{bozza} % Prints the following note in the footer: % \begin{quote} % Version of \meta{date} % \end{quote} % \optitem{plain} % An older name of the \opt{centerheadings} option. Disabled since version 0.6. % \optitem{fullplain} An older name of the \opt{sufplain} option. Disabled since version 0.6. % \end{ltxsyntax} % %\subsection{Fonts} % % \begin{ltxsyntax} % \optitem{artemisia} Loads the Artemisia font (default). % \optitem{porson} Loads the Porson font. % \optitem{defaultgreek} Loads the standard CB~Greek font. % \optitem{defaultfont} Loads the \LaTeX{} standard font and set the \cmd{baselineskip} to the standard default. % \optitem{disablefront} % Disabled since version 0.5. % \end{ltxsyntax} % % \section{Commands}\label{sec:commands} % % The class defines the following new commands. % % \begin{ltxsyntax} % % \cmditem{title}[short title for headings]{complete title for titlepage} % % This command is for use with option \opt{authortitle} if the title is too long % or has some breaks. % % % \cmditem{colophon}[OS]{name and surname}{additional info} % % This command is provided only for italian documents. It prints a page with % a copyright notice and the colophon in the bottom. For different languages % use the \cmd{bookcolophon} instead (see below). % % If you don't like the copyright notice leave the second argument of % the command empty: % \begin{ttquote} % \cmd{colophon\oarm{OS}\{\}\arm{additional info}} % \end{ttquote} % % With the \opt{article} option, you can use the \cmd{artcolophon} command % (see below) % or the \cmd{thanks} command: % \begin{ttquote} % \cmd{author}\{\meta{Name Surname}\cmd{thanks}\{This work has been typeset with \LaTeX{},\\ % using the \cmd{textsf}\{suftesi\} cass by Ivan Valbusa\}.\} % \end{ttquote} % % \cmditem{bookcolophon}{copyright notice}{attribution notice and % other informations} % % This command is similar to \cmd{colophon} but it is completely customizable. % The first argument prints its content (usually the copyright notice) in the center of the page. % The second argument prints its content at the bottom. For example: % % \begin{verbatim} % \bookcolophon{Copyright © 2007 by Ivan Valbusa}{This work has been % typeset with \LaTeX, using the \sty{suftesi} class by Ivan % Valbusa\index{Valbusa, Ivan}. The normal font is Palatino by Hermann % Zapf. The sans serif font is Iwona by Janusz M.~Nowacki.} % \end{verbatim} % % \cmditem{artcolophon}{copyright notice, attribution and other informations} % % This command has only one argument. It simply prints its content at the % bottom of the page. Here is an example: % % \begin{verbatim} % \artcolophon{This work is licensed under the Creative Commons % Attribution-NonCommercial-NoDerivs 3.0 Unported License. To view % a copy of this license, visit % \begin{center} % \texttt{http://creativecommons.org/licenses/by-nc-nd/3.0/} % \end{center} % or send a letter to Creative Commons, 444 Castro Street, Suite 900, % Mountain View, California, 94041, USA.\\[1ex] % % Typeset with \LaTeX, using the \sty{suftesi} class by Ivan Valbusa.} % \end{verbatim} % % \cmditem{finalcolophon}{colophon content} % % The same as \cmd{artcolophon}, but centering its content at the % top of the page. It is aimed to typeset a classical \emph{colophon} % at the end of the work. % % \cmditem{chapterintro} % % Prints an unnumbered introduction at the beginning of the chapters, % with the correct hyperlink. In order to use this command the \sty{hyperref} package must be loaded. % % \cmditem{chapterintroname}{name}\hfill(default=\texttt{Introduzione}) % % Changes in \meta{name} the title printed by the \cmd{chapterintro} command. % % \cmditem{appendicesname}{name}\hfill(default=\texttt{Appendici}) % % Changes in \meta{name} the title printed by the \cmd{appendix} command. % % \cmditem{headbreak} % % A manual break which is active for the table of contents but not in the text or in the headings % % \cmditem{xheadbreak} % % A manual break which is active in the text and in the headings but not in the table of contents. % % \cmditem{chapnumfont}{name} % % Sets the font for the chapter number with the \opt{sufelements} option. % The default is ``\texttt{pplj}'' (\LaTeX) or ``Palatino'' (\XeLaTeX). % \end{ltxsyntax} % % \defbibnote{note}{\sffamily This bibliography has been typeset with % the \sty{biblatex-philosophy} styles, created by the same author of this class.} % \addcontentsline{toc}{section}{\refname} % \printbibliography[prenote=note] % % \StopEventually{\PrintChanges\PrintIndex} % % \section{The Code} %<*class> % \begin{macrocode} \newif\ifsuftesi@centertitle \newif\ifsuftesi@sctitles \newif\ifsuftesi@artemisia \newif\ifsuftesi@porson \newif\ifsuftesi@defaultfont \newif\ifsuftesi@defaultgreek \newif\ifsuftesi@centerheadings \newif\ifsuftesi@sufplain \newif\ifsuftesi@bozza \newif\ifsuftesi@article \newif\ifsuftesi@authortitle \newif\ifsuftesi@nofront \newif\ifsuftesi@periodical \newif\ifsuftesi@compact \newif\ifsuftesi@supercompact \newif\ifsuftesi@elements \newif\ifsuftesi@sufelements \newif\ifsuftesi@nocrop \newif\ifsuftesi@nomarginpar \newif\ifsuftesi@dottedtoc \newif\ifsuftesi@raggedtoc \DeclareOption{centertitle}{\suftesi@centertitletrue} \DeclareOption{sctitles}{\suftesi@sctitlestrue} \DeclareOption{disablefront}{\suftesi@nofronttrue} \DeclareOption{defaultfont}{\suftesi@defaultfonttrue\suftesi@defaultgreektrue} \DeclareOption{artemisia}{\suftesi@artemisiatrue\suftesi@porsonfalse \suftesi@defaultgreekfalse} \DeclareOption{porson}{\suftesi@porsontrue\suftesi@artemisiafalse \suftesi@defaultgreekfalse} \DeclareOption{defaultgreek}{\suftesi@defaultgreektrue \suftesi@artemisiafalse\suftesi@porsonfalse} \DeclareOption{centerheadings}{\suftesi@centerheadingstrue} \DeclareOption{sufplain}{\suftesi@sufplaintrue} \DeclareOption{bozza}{\suftesi@bozzatrue} \DeclareOption{periodical}{\suftesi@periodicaltrue\suftesi@compacttrue} \DeclareOption{compact}{\suftesi@compacttrue} \DeclareOption{supercompact}{\suftesi@supercompacttrue} \DeclareOption{elements}{\suftesi@elementstrue\suftesi@sufelementstrue \suftesi@supercompactfalse\suftesi@compactfalse} \DeclareOption{sufelements}{\suftesi@sufelementstrue\suftesi@sctitlestrue} \DeclareOption{nocrop}{\suftesi@nocroptrue} \DeclareOption{nomarginpar}{\suftesi@nomarginpartrue} \DeclareOption{article}{\suftesi@articletrue} \DeclareOption{authortitle}{\suftesi@authortitletrue} \DeclareOption{dottedtoc}{\suftesi@dottedtoctrue} \DeclareOption{raggedtoc}{\suftesi@raggedtoctrue} \DeclareOption*{\PassOptionsToClass{\CurrentOption}{book}} \ExecuteOptions{artemisia} \ProcessOptions \relax \LoadClass[a4paper]{book} % \end{macrocode} % \subsubsection{Basic packages} % \begin{macrocode} \RequirePackage{color} \definecolor{sufred}{rgb}{0.5,0,0} \definecolor{sufgray}{rgb}{0.5,0.5,0.5} \RequirePackage{ifxetex,ifluatex} \ifxetex\relax \else \RequirePackage{microtype} \fi \RequirePackage{textcase} \RequirePackage{multicol} \RequirePackage{emptypage} \RequirePackage{mparhack} % \end{macrocode} % \subsection{The greek font} % Thanks to Enrico Gregorio for these macros: % \begin{macrocode} \ifxetex \relax \else \RequirePackage[LGR,T1]{fontenc} \AtBeginDocument{\fontencoding{T1}\selectfont} \ifsuftesi@defaultfont \relax \else \RequirePackage[osf,sc]{mathpazo} \RequirePackage[scaled=0.8]{beramono} \linespread{1.05} \renewcommand{\sfdefault}{iwona} \fi \ifsuftesi@artemisia \def\suftesi@greekfamily{artemisiaeuler} \fi \ifsuftesi@defaultgreek \def\suftesi@greekfamily{cmr} \fi \ifsuftesi@porson \sbox\z@{\fontsize{10}{10}\normalfont A} \sbox\tw@{\font\temp=gporsonrg6a at 10pt \temp A} \dimen@= \dimexpr(0.001\dimexpr\numexpr(\dimexpr(1000\ht\z@)/\ht\tw@)\p@) \edef\art@scale{\strip@pt\dimen@} \DeclareFontFamily{LGR}{porson}{} \DeclareFontShape{LGR}{porson}{m}{n}{<-> s * [\art@scale] gporsonrg6a}{} \DeclareFontShape{LGR}{porson}{m}{it}{<-> ssub * porson/m/n}{} \DeclareFontShape{LGR}{porson}{b}{n}{<-> ssub * porson/m/n}{} \DeclareFontShape{LGR}{porson}{b}{it}{<-> ssub * porson/m/n}{} \DeclareFontShape{LGR}{porson}{m}{sl}{<-> ssub * porson/m/n}{} \DeclareFontShape{LGR}{porson}{b}{sl}{<-> ssub * porson/m/n}{} \DeclareFontShape{LGR}{porson}{m}{sc}{<-> ssub * porson/m/n}{} \DeclareFontShape{LGR}{porson}{bx}{n}{<-> ssub * porson/m/n}{} \DeclareFontShape{LGR}{porson}{bx}{it}{<-> ssub * porson/m/n}{} \DeclareFontShape{LGR}{porson}{bx}{sl}{<-> ssub * porson/m/n}{} \def\suftesi@greekfamily{porson} \fi \AtBeginDocument{ \DeclareRobustCommand{\greektext}{% \fontencoding{LGR}\fontfamily{\suftesi@greekfamily}\selectfont \def\encodingdefault{LGR}}} \fi % \end{macrocode} % \subsection{Page layout} % \begin{macrocode} \RequirePackage{geometry} \parindent1em \ifcase\@ptsize\relax \geometry{% textwidth=312pt, textheight=624pt}\or \geometry{% textwidth=324pt, textheight=648pt}\or \geometry{% textwidth=324pt, textheight=648pt} \fi \geometry{% marginparsep=12pt, includehead, hmarginratio=1:2, vmarginratio=1:2, heightrounded, marginparwidth=82pt} \ifsuftesi@nocrop \relax \else \RequirePackage[a4,cam,center]{crop} \fi % \end{macrocode} %\subsubsection{\opt{periodical}} % \begin{macrocode} \ifsuftesi@periodical \geometry{ textheight=16.5cm, textwidth=11cm, paperwidth=17cm, paperheight=24cm, hmarginratio=2:3, vmarginratio=2:3, includefoot, includehead, heightrounded, marginparwidth=70pt, marginparsep=10pt} \else % \end{macrocode} %\subsubsection{\opt{compact}} % \begin{macrocode} \ifsuftesi@compact \geometry{ textheight=16.5cm, textwidth=11cm, paperwidth=16cm, paperheight=24cm, hmarginratio=2:3, vmarginratio=2:3, includefoot, includehead, heightrounded, marginparwidth=65pt, marginparsep=10pt} \else % \end{macrocode} %\subsubsection{\opt{supercompact}} % \begin{macrocode} \ifsuftesi@supercompact \geometry{ textheight=15cm, textwidth=10cm, paperwidth=14cm, paperheight=21cm, hmarginratio=2:3, vmarginratio=2:3, includefoot, includehead, heightrounded, marginparwidth=50pt, marginparsep=9pt} \else % \end{macrocode} %\subsubsection{\opt{elements}} % \begin{macrocode} \ifsuftesi@elements \geometry{% textwidth=251pt, textheight=502pt, marginparwidth=60pt, marginparsep=18pt, paperwidth=378pt, paperheight=654pt, heightrounded, outer=91.2pt, top=64pt} \else \fi \fi \fi \fi % \end{macrocode} % And now a macro to produce oneside documents: % \begin{macrocode} \if@twoside \relax \else \geometry{hmarginratio=1:1} \fi % \end{macrocode} % \subsection{Section titles} % \begin{macrocode} \RequirePackage{titlesec} \newlength{\sectionsep} \setlength{\sectionsep}{\dimexpr(\baselineskip) plus 1pt minus 1pt} \ifsuftesi@supercompact \DeclareRobustCommand{\sufchaptersize}{\large} \else \ifsuftesi@compact \DeclareRobustCommand{\sufchaptersize}{\Large} \else \DeclareRobustCommand{\sufchaptersize}{\Large} \fi \fi \ifxetex \DeclareRobustCommand{\suftesi@titlesmallcaps}[1]{% \addfontfeature{LetterSpace=6}\scshape\MakeTextLowercase{#1}} \DeclareRobustCommand{\suftesi@headingsmallcaps}[1]{% \addfontfeature{LetterSpace=6}\scshape\MakeTextLowercase{#1}} \newcommand{\chapnumfont}[1]{% \def\@chapnumfont{\fontspec{#1}}} \chapnumfont{Palatino} \else \DeclareRobustCommand{\suftesi@titlesmallcaps}[1]{% \scshape\MakeTextLowercase{\textls[110]{#1}}}% \DeclareRobustCommand{\suftesi@headingsmallcaps}[1]{% \scshape\MakeTextLowercase{\textls[110]{#1}}}% \newcommand{\chapnumfont}[1]{% \def\@chapnumfont{\fontfamily{#1}}} \chapnumfont{pplj} \fi % \end{macrocode} % \subsubsection{Part} % \begin{macrocode} \ifsuftesi@article \titleclass{\part}{straight} \titleformat{\part}[hang] {\large} {\ifsuftesi@sctitles\scshape\else\fi\partname~\thepart} {.5em} {\ifsuftesi@sctitles\expandafter\suftesi@titlesmallcaps\else\fi} \titlespacing*{\part}{0ex}{2\sectionsep}{2\sectionsep}[0ex] \else \titleformat{\part}[display] {\LARGE\filcenter} {\sufchaptersize\ifsuftesi@sctitles\scshape\else\fi\partname~\thepart} {3ex} {\sufchaptersize\ifsuftesi@sctitles\expandafter\suftesi@titlesmallcaps\else\fi} \fi % \end{macrocode} % \subsubsection{Chapter} % \paragraph{The \opt{elements} styles} % \begin{macrocode} \ifsuftesi@sufelements \titleformat{\chapter}[block] {}% {\begin{picture}(0,0) \setlength{\unitlength}{1pt} \@chapnumfont% \ifsuftesi@elements \fontsize{64}{64}\selectfont% \put(0,-73){% \hskip\dimexpr(\textwidth+\marginparsep)\textcolor{sufgray}{\thechapter}}% \else \fontsize{95}{95}\selectfont% \put(0,-83){\hskip\dimexpr(\textwidth+\marginparsep)% \textcolor{sufgray}{\thechapter}}% \fi \end{picture}}% {0pt} {\suftesi@titlesmallcaps} [\rule{\textwidth}{.1pt}] \else % \end{macrocode} % \paragraph{The default styles} % \begin{macrocode} \ifsuftesi@centertitle \titleformat{\chapter}[display] {\filcenter} {\sufchaptersize\thechapter} {3ex} {\sufchaptersize\ifsuftesi@sctitles\expandafter\suftesi@titlesmallcaps\else\fi} \else \titleformat{\chapter}[hang] {\filright} {\sufchaptersize\thechapter.} {3ex} {\sufchaptersize\ifsuftesi@sctitles\expandafter\suftesi@titlesmallcaps\else\fi} \fi \fi \ifsuftesi@compact \titlespacing*{\chapter}{0em}{0ex}{18ex} \else \ifsuftesi@supercompact \titlespacing*{\chapter}{0em}{0ex}{18ex} \else \ifsuftesi@elements \titlespacing*{\chapter}{0em}{-45pt}{10pt}[0em] \else \ifsuftesi@sufelements \titlespacing*{\chapter}{0em}{6ex}{10pt}[0em] \else \titlespacing*{\chapter}{0em}{6ex}{18ex} \fi \fi \fi \fi % \end{macrocode} % \subsubsection{Section, subsection, subsubsection, \dots} % \paragraph{\opt{elements}} % \begin{macrocode} \ifsuftesi@elements \titleformat{\section}[hang] {\raggedright} {\textnormal\thesection} {1em} {\small\suftesi@titlesmallcaps} \titlespacing*{\section}{0em}{\baselineskip}{\baselineskip}[0em] \titleformat{\subsection}[block] {\filright\normalsize\itshape} {\textnormal\thesubsection} {1em} {} \titlespacing*{\subsection}{0em}{\baselineskip}{\baselineskip}[0em] \titleformat{\subsubsection}[block] {\filright\normalsize\itshape} {\textnormal\thesubsubsection} {1em} {} \titlespacing*{\subsubsection}{0em}{\baselineskip}{\baselineskip}[0em] \else % \end{macrocode} % \paragraph{\opt{default}} % \begin{macrocode} \ifsuftesi@article \renewcommand\thesection {\@arabic\c@section} \renewcommand\thesubsection {\thesection.\@arabic\c@subsection} \renewcommand\thesubsubsection{\thesubsection.\@arabic\c@subsubsection} \renewcommand\theparagraph {\thesubsubsection.\@arabic\c@paragraph} \renewcommand\thesubparagraph {\theparagraph.\@arabic\c@subparagraph} \else \fi \titleformat{\section}[hang] {\filright} {\thesection} {.5em} {\unskip\ifsuftesi@sctitles\expandafter\suftesi@titlesmallcaps\else\itshape\fi} \titlespacing*{\section}{0ex}{\sectionsep}{\sectionsep}[0ex] \titleformat{\subsection}[hang] {} {\textnormal\thesubsection} {.5em} {\itshape} \titlespacing*{\subsection}{\parindent}{\sectionsep}{\sectionsep}[0ex] \titleformat{\subsubsection}[hang] {} {\textnormal\thesubsubsection} {.5em} {\itshape} \titlespacing*{\subsubsection}{\parindent}{\baselineskip}{\baselineskip}[0ex] \fi \titleformat{\paragraph}[runin] {} {\theparagraph} {.5em} {\itshape} [{.}\hspace*{1em}] \titlespacing*{\paragraph}{\parindent}{.5\sectionsep}{.5\sectionsep} \titleformat{\subparagraph}[runin] {} {\thesubparagraph} {.5em} {} [{.}\hspace*{1em}] \titlespacing*{\subparagraph}{\parindent}{.5\sectionsep}{.5\sectionsep} % \end{macrocode} % \paragraph{\sty{biblatex} settings} % \begin{macrocode} \ifsuftesi@article %ARTICLE \AtBeginDocument{% \@ifpackageloaded{biblatex}{% \defbibheading{bibliography}[\refname]{% \section*{#1}% \markboth{#1}{#1}} \defbibheading{shorthands}[\losname]{% \section*{#1}% \markboth{#1}{#1}} \defbibheading{bibintoc}[\refname]{% \section*{#1}% \addcontentsline{toc}{section}{#1}% \markboth{#1}{#1}} \defbibheading{losintoc}[\losname]{% \section*{#1}% \addcontentsline{toc}{section}{#1}% \markboth{#1}{#1}} \defbibheading{bibnumbered}[\refname]{% \section{#1}% \if@twoside\markright{#1}\fi} \defbibheading{losnumbered}[\losname]{% \section{#1}% \if@twoside\markright{#1}\fi} \defbibheading{subbibliography}[\refname]{% \subsection*{#1}} \defbibheading{subbibintoc}[\refname]{% \subsection*{#1}% \addcontentsline{toc}{subsection}{#1}} \defbibheading{subbibnumbered}[\refname]{% \subsection{#1}}}% {\relax}% }% \else %BOOK \AtBeginDocument{% \@ifpackageloaded{biblatex}{% \defbibheading{bibliography}[\bibname]{% \chapter*{#1}% \markboth{#1}{#1}} \defbibheading{shorthands}[\losname]{% \chapter*{#1}% \markboth{#1}{#1}} \defbibheading{bibintoc}[\bibname]{% \chapter*{#1}% \addcontentsline{toc}{chapter}{#1}% \markboth{#1}{#1}} \defbibheading{losintoc}[\losname]{% \chapter*{#1}% \addcontentsline{toc}{chapter}{#1}% \markboth{#1}{#1}} \defbibheading{bibnumbered}[\bibname]{% \chapter{#1}% \if@twoside\markright{#1}\fi} \defbibheading{losnumbered}[\losname]{% \chapter{#1}% \if@twoside\markright{#1}\fi} \defbibheading{subbibliography}[\refname]{% \section*{#1}% \if@twoside\markright{#1}\fi} \defbibheading{subbibintoc}[\refname]{% \section*{#1}% \addcontentsline{toc}{section}{#1}% \if@twoside\markright{#1}\fi} \defbibheading{subbibnumbered}[\refname]{% \section{#1}}} {\relax}% }% \fi % \end{macrocode} % \subsubsection{TOC, LOF, LOT} % \begin{macrocode} \RequirePackage{titletoc} % \end{macrocode} % Settings for \opt{dottedtoc} and \opt{raggedtoc} options: % \begin{macrocode} \ifsuftesi@dottedtoc \newcommand{\suftesi@titlerule}{\titlerule*{\footnotesize .\ }} \newcommand{\suftesi@chaptitlerule}{\titlerule*{}} \else \ifsuftesi@raggedtoc \newcommand{\suftesi@titlerule}{\hspace{1.5em}} \newcommand{\suftesi@chaptitlerule}{\hspace{1.5em}} \else \newcommand{\suftesi@titlerule}{\titlerule*{}} \newcommand{\suftesi@chaptitlerule}{\titlerule*{}} \fi \fi % \end{macrocode} % \opt{article} mode: % \begin{macrocode} \ifsuftesi@article \renewcommand\tableofcontents{% \thispagestyle{empty} \section*{\contentsname \@mkboth{\contentsname}{\contentsname}}% \@starttoc{toc}% \vspace{2ex}% } \renewcommand\listoffigures{% \section*{\listfigurename}% \@mkboth{\listfigurename}% {\listfigurename}% \@starttoc{lof}% \vspace{2ex}% } \renewcommand\listoftables{% \section*{\listtablename}% \@mkboth{% \listtablename}% {\listtablename}% \@starttoc{lot}% \vspace{2ex}% } \else % \end{macrocode} % \opt{book} mode: % \begin{macrocode} \renewcommand\tableofcontents{% \if@twocolumn \@restonecoltrue\onecolumn \else \@restonecolfalse \fi \chapter*{\contentsname \@mkboth{\contentsname}{\contentsname}}% \@starttoc{toc}% \if@restonecol\twocolumn\fi } \fi \titlecontents{part} [0em] {\addvspace{3ex}\partname~} {\thecontentslabel\hspace*{1em}} {} {} [\addvspace{1ex}] \titlecontents{chapter} [0em] {\addvspace{2ex}} {\thecontentslabel\hspace*{1em}} {} {\suftesi@chaptitlerule\contentspage} [\addvspace{1ex}] \titlecontents{section} [1.5em] {} {\thecontentslabel\hspace*{1em}} {} {\ifsuftesi@article\suftesi@chaptitlerule% \else\suftesi@titlerule\fi\contentspage} \titlecontents{subsection} [3em] {} {\thecontentslabel\hspace*{1em}} {} {\suftesi@titlerule\contentspage} \titlecontents{subsubsection} [4.5em] {} {\thecontentslabel\hspace*{1em}} {} {\suftesi@titlerule\contentspage} \titlecontents{paragraph} [6em] {} {\thecontentslabel\hspace*{1em}} {} {\suftesi@titlerule\contentspage} \titlecontents{subparagraph} [7.5em] {} {\thecontentslabel\hspace*{1em}} {} {\suftesi@titlerule\contentspage} \titlecontents{figure} [0em] {} {\thecontentslabel\hspace*{1em}} {} {\suftesi@titlerule\contentspage} \titlecontents{table} [0em] {} {\thecontentslabel\hspace*{1em}} {} {\suftesi@titlerule\contentspage} \ifsuftesi@article \setcounter{tocdepth}{3} \setcounter{secnumdepth}{3} \else \fi % \end{macrocode} % \subsubsection{Title page} % \DescribeMacro{\title} % New \cmd{title} command with an optional argument for headings. % \begin{macrocode} \renewcommand*{\title}[2][]{\gdef\@headtitle{#1}\gdef\@title{#2}} \edef\title{\noexpand\@dblarg \expandafter\noexpand\csname\string\title\endcsname} \def\@headtitle{--missing title--% \protect\ClassWarningNoLine{suftesi}{% No \string\title\space given \MessageBreak% See the class documentation for explanation}} \def\@title{--missing title--% \protect\ClassWarningNoLine{suftesi}{% No \string\title\space given\MessageBreak% See the class documentation for explanation}} \def\@author{--missing author--% \protect\ClassWarningNoLine{suftesi}{% No \string\author\space given\MessageBreak% See the class documentation for explanation}} % \end{macrocode} % \DescribeMacro{\standardtitle} Reproduces the standard |\maketitle| style: % \begin{macrocode} \let\standardtitle\maketitle % \end{macrocode} % \DescribeMacro{\maketitle} % For |titlepage| (default) option: % \begin{macrocode} \if@titlepage% titlepage \renewcommand\maketitle{\begin{titlepage}% \let\footnotesize\small \let\footnoterule\relax \let \footnote \thanks \renewcommand\thefootnote{\@fnsymbol\c@footnote}% \null\vfil \vskip 60\p@ \begin{center}% {\sufchaptersize\color{sufred}\sffamily\ifsuftesi@sctitles% \suftesi@titlesmallcaps{\@title}\else\@title\fi \par}% \vskip 3em% {\small\lineskip .75em% \begin{tabular}[t]{c}% \@author \end{tabular}\par}% \vskip 1.5em% {\small\@date\par}% \end{center}\par \@thanks \vfil\null \end{titlepage}% \setcounter{footnote}{0}% \global\let\thanks\relax \global\let\maketitle\relax \global\let\@thanks\@empty \global\let\@date\@empty \global\let\date\relax \global\let\and\relax } \else \renewcommand\maketitle{\par \begingroup \renewcommand\thefootnote{\@fnsymbol\c@footnote}% \def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% \long\def\@makefntext##1{\parindent 1em\noindent \hb@xt@1.8em{% \hss\@textsuperscript{\normalfont\@thefnmark}}##1}% \if@twocolumn \ifnum \col@number=\@ne \@maketitle \else \twocolumn[\@maketitle]% \fi \else \newpage \global\@topnum\z@ % Prevents figures from going at top of page. \@maketitle \fi \thispagestyle{plain}\@thanks \endgroup \setcounter{footnote}{0}% \global\let\thanks\relax \global\let\maketitle\relax \global\let\@maketitle\relax \global\let\@thanks\@empty \global\let\@date\@empty \global\let\date\relax \global\let\and\relax} \def\@maketitle{% \newpage \null \vskip 2em% \begin{center}% \let \footnote \thanks {\sufchaptersize\color{sufred}\sffamily\ifsuftesi@sctitles% \suftesi@titlesmallcaps{\@title}\else\@title\fi\par}% \vskip 1.5em% {\small\lineskip .5em% \begin{tabular}[t]{c}% \@author\par \end{tabular}\par}% \vskip 1em% {\small\@date\par}% \end{center}% \par \vskip 1.5em} \fi % \end{macrocode} % \subsubsection{The frontispiece} % \begin{macrocode} \AtBeginDocument{% \@ifpackageloaded{frontespizio}{% \ifsuftesi@periodical \Margini{1cm}{7cm}{5cm}{1cm}% \Rientro{1cm}% \else \ifsuftesi@compact \Margini{1cm}{7cm}{6cm}{1cm}% \Rientro{1cm}% \else \ifsuftesi@supercompact \Margini{1cm}{10cm}{8cm}{1cm}% \Rientro{1cm}% \else \fi \fi \fi }% {\relax}} % \end{macrocode} % \begin{environment}{theindex} % \begin{macrocode} \renewenvironment{theindex} {\setlength\columnseprule{0pt} \setlength\columnsep{35pt}% \cleardoublepage \@makeschapterhead{\indexname}% \begin{multicols}{2} \markboth{\indexname}{\indexname}% \raggedright\small \setlength\parindent{0pt}% \setlength\parskip{0pt plus 0.3pt}% \thispagestyle{plain}\let\item\@idxitem} {\end{multicols}} \renewcommand\@idxitem{\par\hangindent 15\p@} % \end{macrocode} % \end{environment} % \subsubsection{Appendix} % \begin{macro}{\appendicesname} % \begin{macro}{\appendixpage} % \begin{macrocode} \newcommand{\appendicesname}[1]{\def\suff@appendices{#1}} \appendicesname{Appendici} \newcommand{\appendixpage}{\@appendixpage} % \end{macrocode} % \end{macro} % \end{macro} % \begin{macrocode} \def\@appendixpage{% \@mainmattertrue \titlecontents{part} [0em] {\addvspace{3ex}} {} {} {} [\addvspace{1ex}] \let\contentspage\relax \cleardoublepage \thispagestyle{empty} \addcontentsline{toc}{part}{\suff@appendices} \begingroup \centering \null\vfil {\LARGE\suff@appendices\par} \vfil \endgroup \cleardoublepage \titlecontents{part} [0em] {\addvspace{3ex}\partname~} {\thecontentslabel\hspace*{1em}} {} {} [\addvspace{1ex}] } % \end{macrocode} % \DescribeMacro{\appendix} % \begin{macrocode} \ifsuftesi@sufelements \renewcommand\appendix{\par \setcounter{chapter}{0}% \setcounter{section}{0}% \gdef\@chapapp{\appendixname}% \gdef\thechapter{\@Alph\c@chapter} \titleformat{\chapter}[block] {\vskip-22pt}% {\small\suftesi@titlesmallcaps{\appendixname}~\Alph{chapter}:\hskip.5em} {0pt} {\small\suftesi@titlesmallcaps} [\rule{\textwidth}{.4pt}] \titlespacing*{\chapter}{0em}{10pt}{10pt}[0em] \titlecontents{chapter}[1em] {\filright\hskip.5em} {\suftesi@titlesmallcaps{\appendixname~\thecontentslabel:}\hskip1em} {} {\contentspage\vspace{5pt}}} \else \ifsuftesi@article \renewcommand\appendix{\par \setcounter{section}{0}% \setcounter{subsection}{0}% \gdef\thesection{\@Alph\c@section}} \else \renewcommand\appendix{\par \setcounter{chapter}{0}% \setcounter{section}{0}% \gdef\@chapapp{\appendixname}% \gdef\thechapter{\@Alph\c@chapter}} \fi \fi % \end{macrocode} % \subsection{Headings} % \begin{macrocode} \RequirePackage{fancyhdr} \pagestyle{fancy} \renewcommand{\headrulewidth}{0pt} \renewcommand{\footnoterule}{} % \end{macrocode} % \paragraph{The \opt{elements} headings} % \begin{macrocode} \ifsuftesi@elements% \renewcommand{\chaptermark}[1]{\markboth{#1}{#1}} \renewcommand{\sectionmark}[1]{\markright{#1}} \fancypagestyle{elements}{% \fancyhf{} \fancyfoot[LE,RO]{\thepage} \fancyhead[RO]{% \begin{picture}(0,0) \setlength{\unitlength}{1pt} \put(0,-104){% \hskip\marginparsep \parbox[t]{\marginparwidth}{\itshape\raggedright\leftmark}}% \end{picture}} \fancyhead[LE]{% \begin{picture}(0,0) \setlength{\unitlength}{1pt} \put(0,-104){% \hskip-\dimexpr(\marginparwidth+\marginparsep) \parbox[t]{\marginparwidth}{\itshape\raggedleft\rightmark}}% \end{picture}}% }% \else % \end{macrocode} % \paragraph{The \opt{default} headings} % \begin{macrocode} \renewcommand{\chaptermark}[1]{\markboth{\chaptertitlename\ \thechapter}{#1}} \renewcommand{\sectionmark}[1]{} \fi % \end{macrocode} % \subparagraph{The \opt{plain} style} % \begin{macrocode} \fancypagestyle{plain}{% \fancyhf{} \fancyfoot[C]{} \renewcommand{\headrulewidth}{0pt} \renewcommand{\footrulewidth}{0pt}} % \end{macrocode} % \subparagraph{The \opt{sufplain} style} % \begin{macrocode} \fancypagestyle{sufplain}{% \fancyhf{}% \fancyfoot[RE,LO]{\ifsuftesi@bozza \footnotesize Version of \today\else\fi} \fancyfoot[C]{\footnotesize\sufthepage}} % \end{macrocode} % \subparagraph{The \opt{centerheadings} style} % \begin{macrocode} \fancypagestyle{centerheadings}{% \fancyhf{}% \fancyfoot[RE,LO]{\ifsuftesi@bozza \footnotesize Version of \today\else\fi} \fancyhead[CO]{\footnotesize\xheadbreakfalse\suf@rightmark} \fancyhead[CE]{\footnotesize\xheadbreakfalse% \ifsuftesi@article \ifsuftesi@authortitle \suf@leftmark \else \suf@rightmark \fi \else \suf@leftmark \fi} \fancyfoot[C]{\footnotesize\sufthepage}% }% % \end{macrocode} % \subparagraph{The \opt{sufdefault} style} % \begin{macrocode} \fancypagestyle{sufdefault}{% \fancyhf{}% \fancyfoot[RE,LO]{\ifsuftesi@bozza \footnotesize Version of \today\else\fi} \fancyhead[LE,RO]{\footnotesize\sufthepage} \fancyhead[LO]{\footnotesize\xheadbreakfalse\suf@rightmark} \fancyhead[RE]{\footnotesize\xheadbreakfalse% \ifsuftesi@article \ifsuftesi@authortitle \suf@leftmark \else \suf@rightmark \fi \else \suf@leftmark \fi} }% % \end{macrocode} % \subparagraph{The \opt{article} and \opt{sctitles} styles} % \begin{macrocode} \ifsuftesi@article \renewcommand{\sectionmark}[1]{\markright{\thesection.\ #1}} \else \fi \ifsuftesi@sctitles \ifsuftesi@authortitle \def\suf@rightmark{\suftesi@headingsmallcaps{\@headtitle}} \else \def\suf@rightmark{\suftesi@headingsmallcaps{\rightmark}} \fi \else \ifsuftesi@authortitle \def\suf@rightmark{\nouppercase{\@headtitle}} \else \def\suf@rightmark{\nouppercase{\rightmark}} \fi \fi \ifsuftesi@sctitles \ifsuftesi@authortitle \def\suf@leftmark{\suftesi@headingsmallcaps{\@author}} \else \def\suf@leftmark{\suftesi@headingsmallcaps{\suf@leftrightmark}} \fi \else \ifsuftesi@authortitle \def\suf@leftmark{\nouppercase{\@author}} \else \def\suf@leftmark{\nouppercase{\suf@leftrightmark}} \fi \fi \ifsuftesi@sctitles \def\sufthepage{\suftesi@headingsmallcaps{\thepage}} \else \def\sufthepage{\thepage} \fi \def\suf@leftrightmark{% \if@mainmatter\leftmark\else\rightmark\fi} % \end{macrocode} % Setting the default page style: % \begin{macrocode} \pagestyle{sufdefault} \ifsuftesi@centerheadings\pagestyle{centerheadings}\else\fi \ifsuftesi@sufplain\pagestyle{sufplain}\else\fi \ifsuftesi@elements\pagestyle{elements}\else\fi % \end{macrocode} % \subsection{Text elements} % \subsubsection{Captions} % \begin{macrocode} \RequirePackage{caption} \ifsuftesi@elements \captionsetup{labelsep=period,font={small,sf},singlelinecheck=false} \else \captionsetup{labelsep=period,font=small,singlelinecheck=false} \fi % \end{macrocode} % \subsubsection{Epigraphs} % \begin{macrocode} \RequirePackage{epigraph} \ifsuftesi@elements \relax \else \ifsuftesi@sufelements \relax \else \setlength{\beforeepigraphskip}{-3\baselineskip} \setlength{\afterepigraphskip}{2\baselineskip} \setlength{\epigraphrule}{0pt} \renewcommand{\textflush}{flushepinormal} \renewcommand{\sourceflush}{flushepinormal} \renewcommand{\epigraphsize}{\footnotesize} \fi \fi % \end{macrocode} % \subsubsection{Lists} % \begin{macrocode} \RequirePackage{enumitem} \setlist{labelsep=0.6em,noitemsep,font=\normalfont} \setdescription{font=\normalfont\itshape,noitemsep} \ifsuftesi@compact \setenumerate[1]{leftmargin=1em,label=\arabic*} \setenumerate[2]{leftmargin= 1.5em,label=\arabic*} \setenumerate[3]{leftmargin= 1.5em,label=\arabic*} \setitemize[1]{leftmargin=1em} \setitemize[2]{leftmargin=1.5em} \setitemize[3]{leftmargin=1.5em} \else \ifsuftesi@supercompact \setenumerate[1]{leftmargin=1em,label=\arabic*} \setenumerate[2]{leftmargin= 1.5em,label=\arabic*} \setenumerate[3]{leftmargin= 1.5em,label=\arabic*} \setitemize[1]{leftmargin=1em} \setitemize[2]{leftmargin=1.5em} \setitemize[3]{leftmargin=1.5em} \else \setenumerate[1]{leftmargin=0pt,label=\arabic*} \setenumerate[2]{leftmargin= 1.3em,label=\arabic*} \setenumerate[3]{leftmargin= 1.3em,label=\arabic*} \setitemize[1]{leftmargin=0pt} \setitemize[2]{leftmargin=1.3em} \setitemize[3]{leftmargin=1.3em} \fi \fi \renewcommand\labelitemii{\normalfont \textendash} % \end{macrocode} % \subsubsection{Block Quotations} % \begin{environment}{quotation} % \begin{environment}{quote} % New \env{quotation} and \env{quote} environments according to a popular italian style. The font size is the same of the footnotes and the margins are set to \cmd{parindent}. % \begin{macrocode} \renewenvironment{quotation} {\list{}{\listparindent\parindent% \itemindent \listparindent \rightmargin \parindent \leftmargin \parindent \parsep \z@ \@plus\p@}% \item\relax\footnotesize\noindent\ignorespaces} {\endlist} \renewenvironment{quote} {\list{}{\rightmargin \parindent \leftmargin \parindent}% \item\relax\footnotesize} {\endlist} % \end{macrocode} % \end{environment} % \end{environment} % \begin{environment}{verse} % \begin{macrocode} \renewenvironment{verse} {\let\\\@centercr \list{}{\footnotesize% \itemsep \z@ \itemindent -1.5em% \listparindent\itemindent \rightmargin \leftmargin \advance\leftmargin 1.5em}% \item\relax} {\endlist} % \end{macrocode} % \end{environment} % \subsubsection{Notes} % \begin{macro}{\@makefntext} % Renew the |\@makefntext| command according to the look \emph{The Elements of Typographic Styles} by R. Bringhurst: % \begin{macrocode} \renewcommand\@makefntext{% \hskip-2.5em\makebox[2em][r]{\@thefnmark}\hskip.5em} % \end{macrocode} %\end{macro} % \begin{macro}{\marginpar} % Renew the |\marginpar| command according to the look of \emph{Classic Thesis} by André \textcite{Miede:2011}: % \begin{macrocode} \def\sufmpsetup@setup{%thanks to Lorenzo Pantieri and Enrico Gregorio \itshape\footnotesize% \parindent=0pt \lineskip=0pt \lineskiplimit=0pt % \tolerance=2000 \hyphenpenalty=300 \exhyphenpenalty=300% \doublehyphendemerits=100000% \finalhyphendemerits=\doublehyphendemerits} \long\def\@xmpar[#1]#2{% \@savemarbox\@marbox{\sufmpsetup@setup\raggedleft\hspace{0pt}#1}% \@savemarbox\@currbox{\sufmpsetup@setup\raggedright\hspace{0pt}#2}% \@xympar} \long\def\@ympar#1{% \@savemarbox\@marbox{\sufmpsetup@setup\raggedleft\hspace{0pt}#1}% \global\setbox\@currbox\copy\@marbox \@xympar} \ifsuftesi@nomarginpar \renewcommand\marginpar[2][]{} \else \fi % \end{macrocode} % \end{macro} % \subsubsection{Abstract} % This is the macro that defines the \env{abstract} environment in \sty{article} class. In \sty{suftesi} it simply prints the abstract name in normal font: % \begin{macrocode} \if@titlepage \newenvironment{abstract}{% \titlepage \null\vfil \@beginparpenalty\@lowpenalty \begin{center}% \abstractname \@endparpenalty\@M \end{center}}% {\par\vfil\null\endtitlepage} \else \newenvironment{abstract}{% \if@twocolumn \section*{\abstractname}% \else \small \begin{center}% {\abstractname\vspace{-.5em}\vspace{\z@}}% \end{center}% \quotation \fi} {\if@twocolumn\else\endquotation\fi} \fi \newcommand\abstractname{Abstract} % \end{macrocode} % \subsubsection{Colophon} % Some useful commands to print a colophon or a coyright notice. % \begin{macrocode} \edef\sufengine{% \ifxetex \noexpand\XeLaTeX \else \ifluatex Lua\noexpand\LaTeX \else \noexpand\LaTeX \fi \fi} % \end{macrocode} % \begin{macro}{\colophon} % \begin{macrocode} \newcommand{\colophon}[3][]{% \thispagestyle{empty} \null \vfill \def\next{#2} \ifx\next\@empty\else \noindent Copyright \copyright{} \the\year~#2\\[1ex] All rights reserved \fi \vfill {\small\noindent This work has been typeset with \sufengine{}% \def\next{#1} \ifx\next\@empty\else on #1 \fi using the \textsf{suftesi} class by Ivan Valbusa\index{Valbusa, Ivan}. #3\par} \cleardoublepage} % \end{macrocode} % \end{macro} % \begin{macro}{\bookcolophon} % \begin{macrocode} \newcommand{\bookcolophon}[2]{% \thispagestyle{empty} \null \vfill \noindent #1 \vfill {\small\noindent #2\par} \cleardoublepage} % \end{macrocode} % \end{macro} % \begin{macro}{\artcolophon} % \begin{macrocode} \newcommand{\artcolophon}[1]{% \thispagestyle{empty} \null \vfill {\small\noindent #1\par}} % \end{macrocode} % \end{macro} % \begin{macro}{\finalcolophon} % \begin{macrocode} \newcommand{\finalcolophon}[1]{% \thispagestyle{empty} \null\vspace*{\stretch{1}} \begin{center} \begin{minipage}{.5\textwidth} \centering\small #1 \end{minipage} \end{center} \vspace*{\stretch{6}} } % \end{macrocode} % \end{macro} % \subsection{Commands} % \begin{macro}{\chapterintro} % A command to typeset an unnumbered section: % \begin{macrocode} \def\chapterintro{ \@ifstar{\@tempswafalse\@chapterintro}{\@tempswatrue\@chapterintro}} \def\@chapterintro{\phantomsection \if@tempswa\section*{\suffchapterintroname}\fi \addcontentsline{toc}{section}{\suffchapterintroname}} \newcommand{\chapterintroname}[1]{\def\suffchapterintroname{#1}} \chapterintroname{Introduzione} % \end{macrocode} % \end{macro} % \begin{macro}{\headbreak} %Active in the table of contents but not in the text or in the headings % \begin{macrocode} \newif\ifheadbreak\headbreakfalse \DeclareRobustCommand{\headbreak} {\ifheadbreak\\\else\fi} % \end{macrocode} % \end{macro} % \begin{macro}{\xheadbreak} % Active in the text and in the headings but not in the table of contents. % \begin{macrocode} \newif\ifxheadbreak\xheadbreaktrue \DeclareRobustCommand{\xheadbreak} {\ifxheadbreak\\\else\fi} % \end{macrocode} % \end{macro} % \begin{macro}{\tableofcontents} % \begin{macrocode} \let\origtableofcontents\tableofcontents \renewcommand{\tableofcontents}{% \begingroup\headbreaktrue\xheadbreakfalse% \origtableofcontents\endgroup} % \end{macrocode} % \end{macro} % Renew |\frontmatter| to have arabic page numbering: % \begin{macrocode} \renewcommand\frontmatter{\cleardoublepage\@mainmatterfalse} \renewcommand\mainmatter{\cleardoublepage\@mainmattertrue} % \end{macrocode} % \subsection{Backward compatibility} % \begin{environment}{bibliografia} % An environment to manually typeset the bibliography. (Use \sty{biblatex} instead!) % \begin{macrocode} \newenvironment{bibliografia}{% \ifsuftesi@article \section*{\refname} \addcontentsline{toc}{section}{\refname} \else \chapter{\bibname}% \fi \normalfont \list{}{% \setlength{\itemindent}{-\parindent} \setlength{\leftmargin}{\parindent} \setlength{\labelwidth}{\leftmargin} \setlength{\parsep}{\parskip} \let\makelabel}} {\endlist} % \end{macrocode} % \end{environment} % \begin{environment}{sigle} % An environment to manually typeset the list of shorthands. (Use \sty{biblatex} instead!) % \begin{macrocode} \newcommand{\losname}{Sigle} \newcommand{\itlabel}[1]{\itshape\hbox to 6em{#1}} \newenvironment{sigle}{% \chapter{\losname} \normalfont \list{}{% \setlength{\labelsep}{0.5em} \setlength{\itemindent}{0pt} \setlength{\leftmargin}{6em} \setlength{\labelwidth}{\leftmargin} \setlength{\listparindent}{\parindent} \setlength{\parsep}{\parskip} \let\makelabel\itlabel}} {\endlist} % \end{macrocode} % \end{environment} % \begin{macrocode} \let\hemph\emph % \end{macrocode} % \paragraph{Final settings} % Just one touch of french typography: % \begin{macrocode} \frenchspacing % % \end{macrocode} % % \subsection{The bibliography file} % %<*bib> % \begin{verbatim} @book{Morison:1111, Author = {Stanley Morison}, Booktitle = {First Principles of Typography}, Date = {1936}, Location = {Cambridge}, Origdate = {2008}, Origlocation = {Pisa-Roma}, Origpublisher = {Fabrizio Serra editore}, Origtitle = {I principi fondamentali della tipografia}, Publisher = {Cambridge University Press}, Title = {First Principles of Typography}} @book{Eco:1980, Author = {Umberto Eco}, Booktitle = {Il nome della rosa}, Location = {Milano}, Publisher = {Bompiani}, Title = {Il nome della rosa}, Year = {1980}} @online{Gregorio:frontespizio, Author = {Enrico Gregorio}, Note = {version 1.1}, Title = {Il pacchetto \textsf{frontespizio}}, Url = {http://www.guit.sssup.it/phpbb/index.php}, Year = {2009}} @article{Valbusa:2010, Author = {Ivan Valbusa}, Journal = {ArsTeXnica}, Month = {10}, Number = {9}, Title = {Creare stili bibliografici con \textsf{biblatex}: l'esperienza del pacchetto {biblatex-philosophy}}, Year = {2010}} @book{Bringhurst:1996, Author = {Robert Bringhurst}, Booktitle = {The Elements of Typographic Style}, Date = {1996}, Edition = {2}, Location = {Vancouver}, Publisher = {Hurtley \& Marks Publisher}, Title = {The Elements of Typographyc Style}, Annote = {In questa voce sono state date le indicazioni complete dell'edizione originale, ed è stato indicato solo il luogo e la data della traduzione italiana}} @book{Tschichold:1975, Author = {Jan Tschichold}, Booktitle = {Ausgewählte Aufsätze über Fragen der Gestalt des Buches und der Typographie}, Location = {Basel}, Origdate = {2003}, Origlocation = {Milano}, Origpublisher = {Sylvestre Bonnard}, Origtitle = {La forma del libro}, Publisher = {Birkhäuser Verlag}, Title = {Ausgewählte Aufsätze über Fragen der Gestalt des Buches und der Typographie}, Year = {1975}} @online{Lehman:2010, Author = {Philipp Lehman}, Note = {Versione 0.9a}, Title = {The \textsf{biblatex} package}, Url = {http://www.ctan.org/tex-archive/macros/latex/exptl/biblatex/}, Year = {2010}} @online{Miede:2011, Author = {André Miede}, Title = {A Classic Thesis style}, Url = {http://www.ctan.org/tex- archive/macros/ latex/contrib/classicthesis/ClassicThesis. pdf}, Date = {2011}} @book{Pantieri:2011, Author = {Lorenzo Pantieri and Tommaso Gordini}, Booktitle = {L'arte di scrivere con LATEX}, Date = {2011}, Edition = {new edition}, Foreword = {Enrico Gregorio}, Hyphenation = {italian}, Subtitle = {Un'in\-troduzione a \LaTeXe}, Title = {L'arte di scrivere con \LaTeX}, Url = {http://www.lorenzopantieri.net/LaTeX_files/ArteLaTeX.pdf}, Annote = {Questa guida è diventata il punto di riferimento degli utenti italiani di \LaTeX\ ed è apprezzata per la chiarezza espositiva e la completezza dei contenuti}} @article{Pantieri:2009, Author = {Lorenzo Pantieri}, Title = {L'arte di gestire la bibliografia con \pack{biblatex}}, Url = {http://www.lorenzopantieri.net/LaTeX_files/Bibliografia.pdf}, Year = {2009}} @article{Mori:2008, Author = {Lapo F. Mori}, Journal = {ArsTeXnica}, Month = {10}, Pages = {37-51}, Title = {Gestire la bibliografia con {\LaTeX}}, Volume = {6}, Year = {2008}} % \end{verbatim} % % % \Finale