summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/spie/spie.cls
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2007-04-22 17:14:41 +0000
committerKarl Berry <karl@freefriends.org>2007-04-22 17:14:41 +0000
commit826ba3c6273e76edd321436990e03e12c7affdd1 (patch)
tree51e06869ae7ed754817ee7972df7178efd0f9efb /Master/texmf-dist/tex/latex/spie/spie.cls
parent3a0595042f7a56658ecc4a51fe68f2ab4312bc49 (diff)
spie update (19apr07)
git-svn-id: svn://tug.org/texlive/trunk@4171 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/spie/spie.cls')
-rw-r--r--Master/texmf-dist/tex/latex/spie/spie.cls236
1 files changed, 97 insertions, 139 deletions
diff --git a/Master/texmf-dist/tex/latex/spie/spie.cls b/Master/texmf-dist/tex/latex/spie/spie.cls
index 97bb7b95769..b6ecc079231 100644
--- a/Master/texmf-dist/tex/latex/spie/spie.cls
+++ b/Master/texmf-dist/tex/latex/spie/spie.cls
@@ -1,6 +1,8 @@
-%% spie.cls - Version 2.8
+%% spie.cls - Version 3.20
%% LaTeX2e class file to format manuscript for SPIE Proceedings
-
+% requires following LaTeX packages:
+% ifthen.sty
+% cite.sty % version 4.01 or later
% History
% Prepared by Rick Zaccone <zaccone@bucknell.edu> on 6/3/91.
% Modified by Adrian F Clark <alien@uk.ac.essex> 11-Jan-1992.
@@ -28,6 +30,17 @@
% Correct short figure caption format, replacing : with . Thanks Mats.
% 2.8 Modified by Ken Hanson <kmh2@lanl.gov> July 16, 2003
% Margins changed to match SPIE's new specs.
+% 2.9 Modified by Ken Hanson <kmh@lanl.gov> January 23, 2006
+% Fixed bug; CMR fonts used for title with times package. Moved text
+% slightly for A4 paper at suggestion of Markus Knauer.
+% 3.00 Modified by Ken Hanson <kmh@lanl.gov> March 5, 2006
+% Proper sized font for title and section headings for times package
+% and other fonts. Use latest cite.sty for citations instead of
+% imbedded code. Beware of incompatabilities with Babel and hyperref.
+% 3.10 Modified by Ken Hanson <kmh@lanl.gov> March 16, 2006
+% For title fonts, scale CMR fonts from 12pt, instead of 17pt
+% 3.20 Modified by Ken Hanson <kmh@lanl.gov> April 17, 2007
+% Small format revisions to match SPIE specifications
%
%%%%%%%%%%%%%%%%%%%%%%%%
% Usage:
@@ -46,30 +59,26 @@
% \supit{b}affiliation2\\
% \supit{c}affiliation3
% }
-%
%%% Note: \skiplinehalf and \supit{} are defined in this class
+% 4. Remember to reset footnote counter after nine footnotes with
+% \footnote[1]{Your footnote text goes here.}
+%
% ------------------------------------------------------------
%% based on standard LaTeX article class --
%% need to define font Size Option inside spie.cls
\NeedsTeXFormat{LaTeX2e}
-\ProvidesClass{spie}[2003/07/16 v2.80 SPIE Proceedings class]
+\ProvidesClass{spie}[2007/04/17 v3.20 SPIE Proceedings class]
\LoadClassWithOptions{article} % build on standard article class
\DeclareOption{a4paper}{%
\AtEndOfClass{%
- \oddsidemargin -0.61cm % for side margins of 2cm
- \evensidemargin -0.61cm % for side margins of 2cm
+% \oddsidemargin -0.61cm % for side margins of 1.93 cm
+% \evensidemargin -0.61cm % for side margins of 1.93 cm
\typeout{a4paper used}
}
}
-%\DeclareOption{a4}{% %% non-standard option
-% \AtEndOfClass{%
-% \oddsidemargin -0.61cm % for side margins of 2cm
-% \evensidemargin -0.61cm % for side margins of 2cm
-% \typeout{a4 used}
-% }
-% }
+
\ProcessOptions\relax % set margins for a4paper if specified
%% type out specified font size
@@ -77,6 +86,9 @@
\if1\@ptsize\typeout{eleven-point font}\fi
\if2\@ptsize\typeout{twelve-point font}\fi
+\RequirePackage{ifthen}
+\RequirePackage[superscript]{cite}[2003/11/04] % need vers. > 4.01
+
%% page format (see "Sample manuscript showing specifications and style")
%% following based on default top and left offset of 1 inch = 25.4mm
\topmargin 0.0in % for top margin of 1.00in
@@ -89,12 +101,13 @@
\textwidth 6.75in % approx 17.1 cm
\headheight 0in \headsep 0in % avoid extra space for header
\pagestyle{empty} % no page numbers is default
-\parskip 1ex plus 1ex minus 0.3ex % spacing between paragraphs
+\setlength{\parskip}{1ex plus 1ex minus 0.3ex} % spacing between paragraphs
\date{} % avoid date
%% space for floats - figures and tables
-\floatsep 0.9ex plus 0.3ex minus 0.6ex
-\textfloatsep 4ex plus 3ex minus 1.5ex
+\setlength{\abovecaptionskip}{0ex}
+\setlength{\floatsep}{0.9ex plus 0.3ex minus 0.6ex}
+\setlength{\textfloatsep}{4ex plus 3ex minus 1.5ex}
\renewcommand{\textfraction}{0.10}
\renewcommand{\floatpagefraction}{0.60}
\renewcommand{\topfraction}{0.90}
@@ -113,29 +126,59 @@
\def\supit#1{\raisebox{0.8ex}{\small\it #1}\hspace{0.05em}}
+%%%%%%%%%%%%%%%%%%%%
%%%% define \ample font size %%%%
%% 10% larger than \normalsize for 10 pt,
%% but smaller than \large
-\if0\@ptsize
- \def\ample{\@setsize\large{12pt}\xipt\@xipt}
-\else
- \def\ample{\large}
-\fi
+\def\ample{\large} % insurance
+
+\def\setamplefont{
+\if0\@ptsize % 10pt text; use 11pt bold fonts
+ \def\ample{\@setsize\large{12pt}\xipt\@xipt}
+\fi
+
+\if1\@ptsize % 10pt text; use 11pt bold fonts
+ \def\ample{\@setsize\large{12pt}\xiipt\@xiipt}
+\fi
+
+\if2\@ptsize % 12pt text; use 13.2pt bold fonts
+ \renewcommand{\ample}{\fontsize{13.2pt}{15.8pt}\selectfont\bfseries}
+ \ifcmr \font\ample = cmbx17 at 13.2truept \fi
+\fi }
+
%%%% define title aspects %%%%
\def\titlefont{\normalfont\LARGE\bfseries} %% insurance
-\if0\@ptsize
- \font\titlefont = cmbx12 at 16truept % 10pt
-\else
- \def\titlefont{\LARGE\bf} % other
+\def\title#1{\gdef\@title{\titlefont #1}}
+
+\def\settitlefont{
+%%% identify font used; cmr = Computer Modern Roman, ptm = Times Roman
+\typeout{\rmdefault -font_in_spiecls}
+\def\cmr{cmr} % variables for font tests
+\newif\ifcmr
+\def\ptm{ptm}
+\newif\ifptm
+\ifthenelse{\equal{\rmdefault}{\cmr}}{\cmrtrue}{\cmrfalse}
+\ifthenelse{\equal{\rmdefault}{\ptm}}{\ptmtrue}{\ptmfalse}
+%%% scale title according to default font and size
+\if0\@ptsize % 10pt text; use 16pt bold fonts
+ \renewcommand{\titlefont}{\fontsize{16pt}{19.2pt}\selectfont\bfseries}
+ \ifcmr \font\titlefont = cmbx12 at 16truept \fi
\fi
-
-\def\title#1{\gdef\@title{\titlefont #1}}
+% for 11pt text, title font should be 17pt = \LARGE for 11pt. No change needed
+\if2\@ptsize % 12pt text; use 19.2pt bold fonts
+ \renewcommand{\titlefont}{\fontsize{19.2pt}{23pt}\selectfont\bfseries}
+ \ifcmr \font\titlefont = cmbx12 at 19.2truept \fi
+\fi }
\def\authorinfo#1{\gdef\@authorinfo{#1}}
\authorinfo{} %% default is empty
+\let\@affiliation\@empty
+\def\affiliation#1{\gdef\@affiliation{#1}}
\def\maketitle{\par
+\settitlefont
+\setamplefont
\begingroup
\def\thefootnote{\fnsymbol{footnote}}%
\def\@makefnmark{\hbox
@@ -155,9 +198,9 @@
\renewcommand{\footnotesize}{\small} % enlarge footnote font to small
\renewcommand{\thefootnote}{\fnsymbol{footnote}}
\ifx\@authorinfo\empty \else\footnotetext[0]{\@authorinfo}\fi
-%% use zero to avoid footnote mark
-\renewcommand{\thefootnote}{\fnsymbol{footnote}}
+%% NB use zero to avoid footnote mark
%% use footnote symbols, not numbers
+\renewcommand{\thefootnote}{\fnsymbol{footnote}}
}
% redefine \and for author list because \tabular was removed
@@ -168,7 +211,14 @@
% move title to top of page
\if0\@ptsize\vspace{-10mm}\else\vspace{-12mm}\fi
\begin{center}%
- {\setlength{\baselineskip}{4.3ex} \@title \par}
+ \ifcmr
+ \if0\@ptsize {\typeout{10pt}\setlength{\baselineskip}{19.2pt} \@title \par} \fi
+ \if1\@ptsize {\typeout{11pt}\setlength{\baselineskip}{20.4pt} \@title \par} \fi
+ \if2\@ptsize {\typeout{12pt}\setlength{\baselineskip}{23pt} \@title \par} \fi
+ \else
+ {\@title \par}
+ \fi
+% {\setlength{\baselineskip}{4.3ex} \@title \par}
\vskip 3.5mm
{\large % author and organization font size
\@author \par} % remove tabular used in article.cls
@@ -199,21 +249,27 @@
%% \@sect{NAME}{LEVEL}{INDENT}{BEFORESKIP}{AFTERSKIP}
%% {STYLE}[ARG1]{ARG2}
\def\@sect#1#2#3#4#5#6[#7]#8{\ifnum #2>\c@secnumdepth
- \let\@svsec\@empty\else
- \refstepcounter{#1}\edef\@svsec{\csname the#1\endcsname.\hskip 0.3em plus 0.3em}\fi
+ \let\@svsec\@empty
+ \let\@svsecp\@empty
+ \let\@svsub\@empty
+ \else
+ \refstepcounter{#1}
+ \edef\@svsec{\csname the#1\endcsname\hskip 0.5em plus 0.3em}
+ \edef\@svsecp{\csname the#1\endcsname.\hskip 0.3em plus 0.3em}
+ \edef\@svsub{\csname the#1\endcsname\hskip 0.5em plus 0.3em}\fi
\@tempskipa #5\relax
\ifdim \@tempskipa>\z@
\begingroup #6\relax
\ifnum #2=1
%%(kmh) in appendix, add word appendix in front of section number
\ifnum \append=1 {\interlinepenalty \@M
- APPENDIX \@svsec\uppercase{#8}\par}
- \else {\interlinepenalty \@M \@svsec\uppercase{#8}\par}
+ APPENDIX \@svsecp\uppercase{#8}\par}
+ \else {\interlinepenalty \@M \@svsecp\uppercase{#8}\par}
\fi
\else\ifnum #2=2
- \noindent{\interlinepenalty \@M \@svsec #8\par}
+ \noindent{\interlinepenalty \@M \@svsub #8\par}
\else
- \noindent{\interlinepenalty \@M \@svsec #8\par}
+ \noindent{\interlinepenalty \@M \@svsub #8\par}
\fi
\fi
\endgroup
@@ -241,7 +297,7 @@
\def\acknowledgments{\section*{ACKNOWLEDGMENTS}}
\def\endacknowledgments{}
-% Old spelling - acceptable, but not preferred
+% include old spelling - which is acceptable, but not preferred
\def\acknowledgements{\section*{ACKNOWLEDGMENTS}}
\def\endacknowledgements{}
@@ -253,14 +309,13 @@
{\settowidth\labelwidth{[#1]}\leftmargin\labelwidth
\advance\leftmargin\labelsep \usecounter{enumi}}
\def\newblock{\hskip .11em plus .33em minus .07em}
- %% reduce vspace between items
+ %% reduce vspace between items
\parskip -0.7ex plus 0.5ex minus 0ex
\if0\@ptsize\else\small\fi %% smaller fonts
\sloppy\clubpenalty4000\widowpenalty4000
\sfcode`\.=1000\relax}
\let\endthebibliography=\endlist
-
%%%% Add theorem, lemma, and definition environments %%%%
% kmh - noindent
\def\@begintheorem#1#2{
@@ -279,9 +334,9 @@
%%%% Figure and table captions %%%
\long\def\@makecaption#1#2{% % from article.cls
\vskip\abovecaptionskip
- \sbox\@tempboxa{{\footnotesize\bf #1.\ }{\footnotesize #2}}%
- \ifdim \wd\@tempboxa >\hsize % bold with period
- {\footnotesize\bf #1.\ }{\footnotesize #2 \par}
+ \sbox\@tempboxa{{\footnotesize #1.\ }{\footnotesize #2}}%
+ \ifdim \wd\@tempboxa >\hsize % with period
+ {\footnotesize #1.\ }{\footnotesize #2 \par}
\else
\global \@minipagefalse
\hb@xt@\hsize{\hfil\box\@tempboxa\hfil}%
@@ -302,101 +357,4 @@
\Alph{section}.\arabic{subsection}.\arabic{subsubsection}}
}
-
-%%%% Citations are superscripts (from aip.sty) %%%%
-\def\@cite#1#2{\unskip\nobreak\relax
- \def\@tempa{$\m@th^{\hbox{\the\scriptfont0 #1}}$}%
- \futurelet\@tempc\@citexx}
-\def\@citexx{\ifx.\@tempc\let\@tempd=\@citepunct\else
- \ifx,\@tempc\let\@tempd=\@citepunct\else
- \let\@tempd=\@tempa\fi\fi\@tempd}
-\def\@citepunct{\@tempc\edef\@sf{
- \spacefactor=\the\spacefactor\relax}\@tempa
- \@sf\@gobble}
-
-% \citenum emits the plain citation number without ornament
-% \citea puts its argument into the ornamentation for citations
-% thus \cite{foo} is equivalent to \citea{\citenum{foo}}
-\def\citenum#1{{\def\@cite##1##2{##1}\cite{#1}}}
-\def\citea#1{\@cite{#1}{}}
-
-% Collapse citation numbers to ranges. Non-numeric and undefined labels
-% are handled. No sorting is done. E.g., 1,3,2,3,4,5,foo,1,2,3,?,4,5
-% gives 1,3,2-5,foo,1-3,?,4,5
-\newcount\@tempcntc
-\def\@citexzzz[#1]#2{\if@filesw\immediate\write\@auxout{\string\citation{#2}}\fi
- \@tempcnta\z@\@tempcntb\m@ne\def\@citea{}\@cite{\@for\@citeb:=#2\do
- {\@ifundefined
- {b@\@citeb}{\@citeo\@tempcntb\m@ne\@citea\def\@citea{,}{\bf ?}\@warning
- {Citation `\@citeb' on page \thepage \space undefined}}%
- {\setbox\z@\hbox{\global\@tempcntc0\csname b@\@citeb\endcsname\relax}%
- \ifnum\@tempcntc=\z@ \@citeo\@tempcntb\m@ne
- \@citea\def\@citea{,}\hbox{\csname b@\@citeb\endcsname}%
- \else
- \advance\@tempcntb\@ne
- \ifnum\@tempcntb=\@tempcntc
- \else\advance\@tempcntb\m@ne\@citeo
- \@tempcnta\@tempcntc\@tempcntb\@tempcntc\fi\fi}}\@citeo}{#1}}
-\def\@citeozzz{\ifnum\@tempcnta>\@tempcntb\else\@citea\def\@citea{,}%
- \ifnum\@tempcnta=\@tempcntb\the\@tempcnta\else
- {\advance\@tempcnta\@ne\ifnum\@tempcnta=\@tempcntb \else \def\@citea{--}\fi
- \advance\@tempcnta\m@ne\the\@tempcnta\@citea\the\@tempcntb}\fi\fi}
-
-
-% begin citesort.sty
-% A replacement for \@citex which sorts citation numbers as well as
-% compressing and allowing breaks. Based on cite.sty by Donald
-% Arseneau.
-%
-% for use in LaTeX say, \documentstyle[...,citesort,...]{...}
-%
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% Allow, but strongly discourage, line breaks within a long
-% series of citations. Compress lists of successive numbers
-% to one number range, e.g., 5,6,7,8,9 --> 5--9. Compatible
-% with versions of \@cite that use exponents.
-% -- Donald Arseneau 1989
-%
-% Modified to sort the numbers so they come out in increasing order,
-% regardless of the way they appear in the source. O(N^2) sort!
-% Ian Green, CUED, 10-Dec-1991. Improvements to img@eng.cam.ac.uk
-% please. Version 1
-
-\newcount\@minsofar
-\newcount\@min
-\newcount\@cite@temp
-\def\@citex[#1]#2{%
-\if@filesw \immediate \write \@auxout {\string \citation {#2}}\fi
-\@tempcntb\m@ne \let\@h@ld\relax \def\@citea{}%
-\@min\m@ne%
-\@cite{%
- \@for \@citeb:=#2\do {\@ifundefined {b@\@citeb}%
- {\@h@ld\@citea\@tempcntb\m@ne{\bf ?}%
- \@warning {Citation `\@citeb ' on page \thepage \space undefined}}%
-{\@minsofar\z@ \@for \@scan@cites:=#2\do {%
- \@ifundefined{b@\@scan@cites}%
- {\@cite@temp\m@ne}
- {\@cite@temp\number\csname b@\@scan@cites \endcsname \relax}%
-\ifnum\@cite@temp > \@min% select the next one to list
- \ifnum\@minsofar = \z@
- \@minsofar\number\@cite@temp
- \edef\@scan@copy{\@scan@cites}\else
- \ifnum\@cite@temp < \@minsofar
- \@minsofar\number\@cite@temp
- \edef\@scan@copy{\@scan@cites}\fi\fi\fi}\@tempcnta\@min
- \ifnum\@minsofar > \z@ % some more
- \advance\@tempcnta\@ne
- \@min\@minsofar
- \ifnum\@tempcnta=\@minsofar % Number follows previous--hold on to it
- \ifx\@h@ld\relax
- \edef \@h@ld{\@citea\csname b@\@scan@copy\endcsname}%
- \else \edef\@h@ld{\ifmmode{-}\else--\fi\csname b@\@scan@copy\endcsname}%
- \fi
- \else \@h@ld\@citea\csname b@\@scan@copy\endcsname
- \let\@h@ld\relax
- \fi % no more
-\fi}%
-\def\@citea{,\penalty\@highpenalty\,}}\@h@ld}{#1}}
-% end of citesort.sty
-
%% end of spie.cls \ No newline at end of file