Browse Source

* NOTICE: This update adjusts the line spacing and font sizes, so any sidenote

position tweaks and other vertical spacing tweaks you've applied may need to
  be recalculated.  
* tufte-book: default to only showing the chapter titles in the TOC
* sample-handout: fixed some post-\LaTeX spaces
* sample-handout: removed some debug cruft
* tufte-handout: abstract environment now pairs with quotation environment
* tufte-common: modified default font sizes to more closely align with 
  Tufte's books
* tufte-common: adjusted page margins to more closely align with Tufte's books
* tufte-common: added verse, quotation, and quote environments
* tufte-common: fixed sidenotes so that they can contain multiple paragraphs
* tufte-common: reduced size of Helvetica typeface so that it better matches
  the x-height of Palatino


git-svn-id: https://tufte-latex.googlecode.com/svn/trunk@80 516e2f36-ce3a-0410-bea4-1d4a03f5df72
master
Kevin M. Godby 17 years ago
parent
commit
a04ecc5762
6 changed files with 115 additions and 36 deletions
  1. BIN
      sample-book.pdf
  2. BIN
      sample-handout.pdf
  3. +6
    -9
      sample-handout.tex
  4. +3
    -0
      tufte-book.cls
  5. +103
    -18
      tufte-common.sty
  6. +3
    -9
      tufte-handout.cls

BIN
sample-book.pdf View File


BIN
sample-handout.pdf View File


+ 6
- 9
sample-handout.tex View File

@@ -1,5 +1,7 @@
\documentclass{tufte-handout}

%\geometry{showframe}% for debugging purposes -- displays the margins

\usepackage{amsmath}

% Set up the images/graphics package
@@ -7,8 +9,6 @@
\setkeys{Gin}{width=\linewidth,totalheight=\textheight,keepaspectratio}
\graphicspath{{graphics/}}

\usepackage{mcaption} % FIXME move to .cls file

\title{An Example of the Usage of the Tufte-Handout Style\thanks{Inspired by Edward~R. Tufte!}}
\author[The Tufte-LaTeX Developers]{The Tufte-\LaTeX\ Developers}
\date{24 January 2009} % if the \date{} command is left out, the current date will be used
@@ -56,7 +56,7 @@ The Tufte-\LaTeX\ document classes define a style similar to the
style Edward Tufte uses in his books and handouts. Tufte's style is known
for its extensive use of sidenotes, tight integration of graphics with
text, and well-set typography. This document aims to be at once a
demonstration of the features of the Tufte-\LaTeX document classes
demonstration of the features of the Tufte-\LaTeX\ document classes
and a style guide to their use.

\section{Page Layout}\label{sec:page-layout}
@@ -174,7 +174,7 @@ Full page--width figures and tables may be placed in \docenv{figure*} or
use the \docenv{marginfigure} or \docenv{margintable} environments as follows
(see figure~\ref{fig:marginfig}):
\begin{marginfigure}
\includegraphics[width=\marginparwidth]{helix}
\includegraphics[width=\linewidth]{helix}
\caption{This is a margin figure. The helix is defined by
$x = \cos(2\pi z)$, $y = \sin(2\pi z)$, and $z = [0, 2.7]$. The figure was
drawn using Asymptote (\url{http://asymptote.sf.net/}).}
@@ -321,7 +321,7 @@ the \docpkg{titlesec} package.


\section{Installation}\label{sec:installation}
To install the Tufte-\LaTeX classes, simply drop the
To install the Tufte-\LaTeX\ classes, simply drop the
following files into the same directory as your \texttt{.tex}
file:
\begin{quote}
@@ -377,9 +377,6 @@ links to our \smallcaps{svn} repository, mailing lists, bug tracker, and documen
\bibliography{sample-handout}
\bibliographystyle{plainnat}

%\section{Float Positions---DEBUG}
%Full figure: $x=\zposx{pos:fullfig}$, $y=\zposy{pos:fullfig}$
%Text figure: $x=\zposx{pos:textfig}$, $y=\zposy{pos:textfig}$
%Normal table: $x=\zposx{pos:normaltab}$, $y=\zposy{pos:normaltab}$


\end{document}

+ 3
- 0
tufte-book.cls View File

@@ -70,6 +70,9 @@
\@mainmatterfalse
}

%%
% Only show the chapter titles in the table of contents
\setcounter{tocdepth}{0}

%%
% If there is a `tufte-book-local.sty' file, load it.


+ 103
- 18
tufte-common.sty View File

@@ -157,13 +157,69 @@
pdfborder = {0 0 0},
}

%%
% Set the font sizes and baselines to match Tufte's books
\renewcommand\normalsize{%
\@setfontsize\normalsize\@xpt{14}%
\abovedisplayskip 10\p@ \@plus2\p@ \@minus5\p@
\abovedisplayshortskip \z@ \@plus3\p@
\belowdisplayshortskip 6\p@ \@plus3\p@ \@minus3\p@
\belowdisplayskip \abovedisplayskip
\let\@listi\@listI}
\normalbaselineskip=14pt
\normalsize
\renewcommand\small{%
\@setfontsize\small\@ixpt{12}%
\abovedisplayskip 8.5\p@ \@plus3\p@ \@minus4\p@
\abovedisplayshortskip \z@ \@plus2\p@
\belowdisplayshortskip 4\p@ \@plus2\p@ \@minus2\p@
\def\@listi{\leftmargin\leftmargini
\topsep 4\p@ \@plus2\p@ \@minus2\p@
\parsep 2\p@ \@plus\p@ \@minus\p@
\itemsep \parsep}%
\belowdisplayskip \abovedisplayskip
}
\renewcommand\footnotesize{%
\@setfontsize\footnotesize\@viiipt{10}%
\abovedisplayskip 6\p@ \@plus2\p@ \@minus4\p@
\abovedisplayshortskip \z@ \@plus\p@
\belowdisplayshortskip 3\p@ \@plus\p@ \@minus2\p@
\def\@listi{\leftmargin\leftmargini
\topsep 3\p@ \@plus\p@ \@minus\p@
\parsep 2\p@ \@plus\p@ \@minus\p@
\itemsep \parsep}%
\belowdisplayskip \abovedisplayskip
}
\renewcommand\scriptsize{\@setfontsize\scriptsize\@viipt\@viiipt}
\renewcommand\tiny{\@setfontsize\tiny\@vpt\@vipt}
\renewcommand\large{\@setfontsize\large\@xiipt{14}}
\renewcommand\Large{\@setfontsize\Large\@xivpt{18}}
\renewcommand\LARGE{\@setfontsize\LARGE\@xviipt{22}}
\renewcommand\huge{\@setfontsize\huge\@xxpt{25}}
\renewcommand\Huge{\@setfontsize\Huge\@xxvpt{30}}

\setlength\leftmargini {1pc}
\setlength\leftmarginii {1pc}
\setlength\leftmarginiii {1pc}
\setlength\leftmarginiv {1pc}
\setlength\leftmarginv {1pc}
\setlength\leftmarginvi {1pc}
\setlength\labelsep {.5pc}
\setlength\labelwidth {\leftmargini}
\addtolength\labelwidth{-\labelsep}

\setlength{\parindent}{1pc}
\setlength{\parskip}{0pt}


%%
% Set page layout geometry

\RequirePackage[letterpaper,includemp,width=6.5in,marginparsep=0.375in,marginparwidth=2in]{geometry}
\RequirePackage[letterpaper,left=1in,top=1in,headsep=2\baselineskip,textwidth=26pc,marginparsep=2pc,marginparwidth=12pc,textheight=44\baselineskip,headheight=\baselineskip]{geometry}

% FIXME adjust A4 geometry to match letter paper geometry (except for outside margins)
\ifthenelse{\boolean{@tufte@afourpaper}}
{\geometry{a4paper,includemp,width=170mm,marginparsep=10mm,marginparwidth=50mm}}
{\geometry{a4paper,includemp,width=170mm,marginparsep=10mm,marginparwidth=50mm,headheight=\baselineskip}}
{}

\ifthenelse{\boolean{@tufte@symmetric}}
@@ -174,14 +230,14 @@
%%
% Separation marginpars by a line's worth of space.

\setlength\marginparpush{\baselineskip}
\setlength\marginparpush{10pt}

%%
% Font for margin items

\ifthenelse{\boolean{@tufte@sfsidenotes}}
{\newcommand{\@tufte@marginfont}{\normalfont\scriptsize\sffamily}}
{\newcommand{\@tufte@marginfont}{\normalfont\scriptsize}}
{\newcommand{\@tufte@marginfont}{\normalfont\footnotesize\sffamily}}
{\newcommand{\@tufte@marginfont}{\normalfont\footnotesize}}

%%
% \RaggedRight allows hyphenation
@@ -409,6 +465,34 @@
\noindent\textsc{#1}%
}

%%
% Redefine the display environments (quote, quotation, etc.)

\renewenvironment{verse}
{\let\\\@centercr
\list{}{\itemsep \z@
\itemindent -1pc%
\listparindent\itemindent
\rightmargin \leftmargin
\advance\leftmargin 1pc}%
\small%
\item\relax}
{\endlist}
\renewenvironment{quotation}
{\list{}{\listparindent 1pc%
\itemindent \listparindent
\rightmargin \leftmargin
\parsep \z@ \@plus\p@}%
\small%
\item\relax\noindent\ignorespaces}
{\endlist}
\renewenvironment{quote}
{\list{}{\rightmargin\leftmargin}%
\small%
\item\relax}
{\endlist}


%%
% Used for doublespacing, and other linespacing

@@ -508,7 +592,7 @@
\long\def\@makefntext#1{\@textsuperscript{\@tufte@marginfont\tiny\@thefnmark}\,\footnotelayout#1}

% Set the in-text footnote mark in the same typeface as the body text itself.
\def\@makefnmark{\hbox{\@textsuperscript{\normalfont\scriptsize\@thefnmark}}}
\def\@makefnmark{\hbox{\@textsuperscript{\normalfont\footnotesize\@thefnmark}}}

\providecommand*{\multiplefootnotemarker}{3sp}
\providecommand*{\multfootsep}{,}
@@ -557,7 +641,7 @@
\newcommand{\@tufte@sidenote@vertical@offset}{0pt}

% #1 = footnote num, #2 = vertical offset, #3 = footnote text
\def\@tufte@sidenote[#1][#2]#3{%
\long\def\@tufte@sidenote[#1][#2]#3{%
\let\cite\@tufte@infootnote@cite% use the in-sidenote \cite command
\gdef\@tufte@citations{}% clear out any old citations
\ifthenelse{\NOT\isempty{#2}}{\renewcommand{\@tufte@sidenote@vertical@offset}{#2}}{}%
@@ -596,9 +680,6 @@
}


% TODO: Combine sequences of citations so that 2,3,4,6 becomes 2--4,6
% but be careful of hyperref interaction

%%
% The placeins package provides the \FloatBarrier command. This forces
% LaTeX to place all of the floats before proceeding. We'll use this to
@@ -651,7 +732,8 @@
\ifthenelse{\boolean{@tufte@symmetric}}
{\ifthenelse{\boolean{@tufte@changepage}}{\begin{adjustwidth*}{}{-\@tufte@overhang}}{\begin{adjustwidth}[]{}{-\@tufte@overhang}}}
{\begin{adjustwidth}{}{-\@tufte@overhang}}
\begin{minipage}{\linewidth}}%
\begin{minipage}{\linewidth}%
}%
{\end{minipage}%
\end{adjustwidth}%
\end@float}
@@ -665,7 +747,8 @@
\ifthenelse{\boolean{@tufte@symmetric}}
{\ifthenelse{\boolean{@tufte@changepage}}{\begin{adjustwidth*}{}{-\@tufte@overhang}}{\begin{adjustwidth}[]{}{-\@tufte@overhang}}}
{\begin{adjustwidth}{}{-\@tufte@overhang}}
\begin{minipage}{\linewidth}}%
\begin{minipage}{\linewidth}%
}%
{\end{minipage}%
\end{adjustwidth}%
\end@float}
@@ -683,12 +766,12 @@
%%
% Format the captions in a style similar to the sidenotes

\RequirePackage[format=default,font={rm,scriptsize},justification=raggedright,singlelinecheck=false]{caption}
\RequirePackage[format=default,font={rm,footnotesize},justification=raggedright,singlelinecheck=false]{caption}

% if the `sfsidenotes' option is specified, set the captions in sf, too.
\ifthenelse{\boolean{@tufte@sfsidenotes}}
{\captionsetup{font={sf,scriptsize}}}
{\captionsetup{font={rm,scriptsize}}}
{\captionsetup{font={sf,footnotesize}}}
{\captionsetup{font={rm,footnotesize}}}

% if the `justified' option is specified, set the captions in flush left
% and flush right
@@ -703,7 +786,7 @@

\ifthenelse{\boolean{@tufte@loadfonts}\AND\NOT\boolean{@tufte@xetex}}{%
\IfFileExists{mathpazo.sty}{\RequirePackage[osf,sc]{mathpazo}}{}
\IfFileExists{helvet.sty}{\RequirePackage[scaled=0.95]{helvet}}{}
\IfFileExists{helvet.sty}{\RequirePackage[scaled=0.90]{helvet}}{}
\IfFileExists{beramono.sty}{\RequirePackage[scaled=0.85]{beramono}}{}
\RequirePackage[T1]{fontenc}
\RequirePackage{textcomp}
@@ -726,7 +809,7 @@
\let\@tufte@orig@cr\\% save the original meaning of \\
\def\\{\@tufte@newlinetospace}% turn \\ and \\* into \space
\let\newline\\% turn \newline into \space
#1
#1%
\let\\\@tufte@orig@cr% revert to original meaning of \\
}

@@ -781,7 +864,7 @@
%%
% Set raggedright and paragraph indentation for document

\AtBeginDocument{\@tufte@justification\setlength\parindent{1em}}
\AtBeginDocument{\@tufte@justification}


%%
@@ -874,6 +957,8 @@
\endgroup}
\par
\endgroup
\setlength{\parindent}{1pc}
\setlength{\parskip}{0pt}
\thispagestyle{plain}% suppress the running head
}



+ 3
- 9
tufte-handout.cls View File

@@ -32,15 +32,9 @@

% TODO The abstract should be printed on its own page of the `titlepage'
% option was specified.
\renewenvironment{abstract}{%
\begin{quotation}
\if@tufte@sfsidenotes\begin{sffamily}\fi
\begin{small}
}{%
\end{small}
\if@tufte@sfsidenotes\end{sffamily}\fi
\end{quotation}
}
\renewenvironment{abstract}
{\begin{quotation}\if@tufte@sfsidenotes\begin{sffamily}\fi}
{\if@tufte@sfsidenotes\end{sffamily}\fi\end{quotation}}


%%


Loading…
Cancel
Save