1 %%%% Class file for Le Matematiche
2 %%% Author: Giuseppe Bilotta
3 %%% Email (work): bilotta@dmi.unict.it
4 %%% Email (home): giuseppe.bilotta@gmail.com
6 \NeedsTeXFormat{LaTeX2e}
7 \ProvidesClass{lematema}[2007/01/01 v0.1
8 Class for articles in ``Le Matematiche'']
11 \DeclareOption{english}{\PassOptionsToPackage{\CurrentOption}{babel}}
12 \DeclareOption{french}{\PassOptionsToPackage{\CurrentOption}{babel}}
13 \DeclareOption{italian}{\PassOptionsToPackage{\CurrentOption}{babel}}
16 \DeclareOption{draft}{\PassOptionsToClass{\CurrentOption}{article}}
17 \DeclareOption{final}{\PassOptionsToClass{\CurrentOption}{article}}
21 %%% Class based on the standard article class
22 \LoadClass[10pt,twoside]{article}
23 %%% Package `babel' for language management
24 \RequirePackage[italian]{babel}
25 %%% Package `url' for urls and emails
27 %% Define an \email{...} command
28 \DeclareUrlCommand\email{\urlstyle{tt}}
30 %%% AMS math environments and symbols
31 \RequirePackage{amsmath}
32 \RequirePackage{amssymb}
33 \RequirePackage{amsthm}
35 % %\magnification\magstephalf
36 %%% Page geometry, using the `geometry' package
37 \RequirePackage[paperwidth=17cm,%
46 bottom=2.5cm]{geometry}
48 %%% Our default head/foot style
50 \renewcommand{\ps@plain}{%
51 \renewcommand{\@oddhead}{\hfill\@htitle\hfill\thepage}%
52 \renewcommand{\@evenhead}{\thepage\hfill\@hauthor\hfill}%
53 \renewcommand{\@oddfoot}{}%
54 \renewcommand{\@evenfoot}{}%
58 % TODO these will be redefined in the article itself
59 \def\@htitle{some title}
60 \def\@hauthor{some author}
63 \renewcommand\footnoterule{%
64 \hrule\@width.4\columnwidth
68 \def\@seccntformat#1{\csname the#1\endcsname.\quad}
69 \renewcommand\section{\@startsection {section}{1}{\z@}%
70 {-24pt \@plus -6pt \@minus -3pt}%
72 {\normalfont\bfseries}}
74 %%% Theorem environments
75 \addto\captionsitalian{%
76 \def\theoremname{Teorema}%
77 \def\corollaryname{Corollario}%
78 \def\lemmaname{Lemma}%
79 \def\propositionname{Proposizione}%
80 \def\definitionname{Definizione}%
81 \def\examplename{Esempio}%
82 \def\remarkname{Osservazione}%
85 \addto\captionsenglish{%
86 \def\theoremname{Theorem}%
87 \def\corollaryname{Corollary}%
88 \def\lemmaname{Lemma}%
89 \def\propositionname{Proposition}%
90 \def\definitionname{Definition}%
91 \def\examplename{Example}%
92 \def\remarkname{Remark}%
95 \addto\captionsfrench{%
96 \def\theoremname{Th\'eor\`eme}%
97 \def\corollaryname{Corollaire}%
98 \def\lemmaname{Lemma}%
99 \def\propositionname{Proposition}%
100 \def\definitionname{D\'efinition}%
101 \def\examplename{Exemple}%
102 \def\remarkname{Remarque}%
107 \newtheorem{thm}{\theoremname}[section]
108 \newtheorem{cor}{\corollaryname}[section]
109 \newtheorem{lemma}{\lemmaname}[section]
110 \newtheorem{prop}{\propositionname}[section]
112 \theoremstyle{definition}
113 \newtheorem{dfn}{\definitionname}[section]
114 \newtheorem{exa}{\examplename}[section]
115 \newtheorem{rem}{\remarkname}[section]
116 \newtheorem{note}{\notename}[section]
123 %%% Commands that define the article information
127 %% Mathematics Subject Classification
128 \def\MSC#1{\gdef\@MSC{#1}}
131 \def\keywords#1{\gdef\@keywords{#1}}
134 %% Year/Volume/Number/First Page/Last Page
141 %% Redefine \date to parse a string yyyy/mm/dd, which will be used
142 %% as submission date
144 \newcounter{LM@month}
146 \def\date#1{\LM@parsedate#1\LM@enddate}
147 \def\LM@parsedate#1/#2/#3\LM@enddate{%
148 \setcounter{LM@year}{#1}%
149 \setcounter{LM@month}{#2}%
150 \setcounter{LM@day}{#3}%
153 %% turn a number/counter into an italian month
154 \def\@itmonth#1{\ifcase#1\or gennaio\or febbraio\or marzo\or aprile\or
155 maggio\or giugno\or luglio\or agosto\or settembre\or ottobre\or novembre\or
156 dicembre\else\textbf{??}\fi}
157 \def\itmonth#1{\expandafter\@itmonth\csname c@#1\endcsname}
159 \renewcommand{\maketitle}{%
161 \renewcommand\thefootnote{}%
163 \long\def\@makefntext##1{\parindent 1em\noindent##1}%
165 \global\@topnum\z@ % Prevents figures from going at top of page.
167 \thispagestyle{empty}\@thanks
169 \setcounter{footnote}{0}%
170 \global\let\thanks\relax
171 \global\let\maketitle\relax
172 \global\let\@maketitle\relax
173 \global\let\@thanks\@empty
174 \global\let\@author\@empty
175 \global\let\@date\@empty
176 \global\let\@title\@empty
177 \global\let\title\relax
178 \global\let\author\relax
179 \global\let\date\relax
180 \global\let\and\relax
181 \global\let\MSC\relax
182 \global\let\@MSC\relax
183 \global\let\keywords\relax
184 \global\let\@keywords\relax
187 %% insert the article information in the top right corner
189 \noindent\footnotesize LE MATEMATICHE\\
190 Vol.~\LM@Vol~(\LM@Year)~--~Fasc.~\LM@Num,~pp.~\LM@FirstPg--\LM@LastPg
193 %% Make the title page
197 %% Submission date (at the bottom)
199 \hskip0.8cm Entrato in redazione \arabic{LM@day} \itmonth{LM@month} \arabic{LM@year}\\}%
201 \ifx\@MSC\empty\else\thanks{%
202 \textit{Subject Classification:} \@MSC
204 %% Keywords, if present
205 \ifx\@keywords\empty\else\thanks{%
206 \textit{Keywords:} \@keywords
210 \let \footnote \thanks
211 {\Large\bfseries \@title \par}%
214 \begin{tabular}[t]{c}%
221 \renewenvironment{abstract}{%
227 % In case the author forgets it:
228 \AtBeginDocument{\maketitle}