summaryrefslogtreecommitdiff
path: root/sphinx/texinputs
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2014-01-19 10:29:06 +0100
committerGeorg Brandl <georg@python.org>2014-01-19 10:29:06 +0100
commita0f2548e011d7bca14ed0b8f148c47040d620227 (patch)
tree70d58cae8abf53985f642412855c2d5404c3bf85 /sphinx/texinputs
parent0715decc62404efeb34c4fa12b9098b247b316d9 (diff)
parent59b355edaa4f17aff910bf2371526d5ce46fb648 (diff)
downloadsphinx-a0f2548e011d7bca14ed0b8f148c47040d620227.tar.gz
Merged in tomprince/sphinx (pull request #187)
Make latex commands customizable.
Diffstat (limited to 'sphinx/texinputs')
-rw-r--r--sphinx/texinputs/sphinx.sty20
-rw-r--r--sphinx/texinputs/sphinxmanual.cls3
-rw-r--r--sphinx/texinputs/tabulary.sty9
3 files changed, 16 insertions, 16 deletions
diff --git a/sphinx/texinputs/sphinx.sty b/sphinx/texinputs/sphinx.sty
index 9b083cc6..554845f8 100644
--- a/sphinx/texinputs/sphinx.sty
+++ b/sphinx/texinputs/sphinx.sty
@@ -30,6 +30,8 @@
\RequirePackage{wrapfig}
% Separate paragraphs by space by default.
\RequirePackage{parskip}
+% For parsed-literal blocks.
+\RequirePackage{alltt}
% Redefine these colors to your liking in the preamble.
\definecolor{TitleColor}{rgb}{0.126,0.263,0.361}
@@ -238,9 +240,11 @@
\def\productioncont##1{\\& &\code{##1}}
\parindent=2em
\indent
- \begin{tabular}{lcl}
+ \setlength{\LTpre}{0pt}
+ \setlength{\LTpost}{0pt}
+ \begin{longtable}[l]{lcl}
}{%
- \end{tabular}
+ \end{longtable}
}
% Notices / Admonitions
@@ -508,13 +512,11 @@
}
\fi
-% do not use \@chappos in Appendix in pTeX
+% disable \@chappos in Appendix in pTeX
\ifx\kanjiskip\undefined\else
- \renewcommand{\appendix}{\par
- \setcounter{chapter}{0}
- \setcounter{section}{0}
- \gdef\@chapapp{\appendixname}
- \gdef\@chappos{}
- \gdef\thechapter{\@Alph\c@chapter}
+ \let\py@OldAppendix=\appendix
+ \renewcommand{\appendix}{
+ \py@OldAppendix
+ \gdef\@chappos{}
}
\fi
diff --git a/sphinx/texinputs/sphinxmanual.cls b/sphinx/texinputs/sphinxmanual.cls
index 26df488e..a6b9b392 100644
--- a/sphinx/texinputs/sphinxmanual.cls
+++ b/sphinx/texinputs/sphinxmanual.cls
@@ -97,6 +97,7 @@
%
\let\py@OldTableofcontents=\tableofcontents
\renewcommand{\tableofcontents}{%
+ \pagenumbering{roman}%
\setcounter{page}{1}%
\pagebreak%
\pagestyle{plain}%
@@ -114,7 +115,7 @@
\pagenumbering{arabic}%
\@ifundefined{fancyhf}{}{\pagestyle{normal}}%
}
-\pagenumbering{roman}
+\pagenumbering{alph}
% This is needed to get the width of the section # area wide enough in the
% library reference. Doing it here keeps it the same for all the manuals.
diff --git a/sphinx/texinputs/tabulary.sty b/sphinx/texinputs/tabulary.sty
index ba83c0af..7ea572c1 100644
--- a/sphinx/texinputs/tabulary.sty
+++ b/sphinx/texinputs/tabulary.sty
@@ -8,13 +8,13 @@
%% DRAFT VERSION
%%
%% File `tabulary.dtx'.
-%% Copyright (C) 1995 1996 2003 David Carlisle
+%% Copyright (C) 1995 1996 2003 2008 David Carlisle
%% This file may be distributed under the terms of the LPPL.
%% See 00readme.txt for details.
%%
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{tabulary}
- [2007/10/02 v0.9 tabulary package (DPC)]
+ [2008/12/01 v0.9 tabulary package (DPC)]
\RequirePackage{array}
\catcode`\Z=14
\DeclareOption{debugshow}{\catcode`\Z=9\relax}
@@ -109,8 +109,6 @@ Z \string\tymax: \the\tymax^^J}%
\global\advance\TY@linewidth-#1\relax}
\def\endtabulary{%
\gdef\@halignto{}%
- \let\TY@footnote\footnote%
- \def\footnote{}% prevent footnotes from doing anything
\expandafter\TY@tab\the\toks@
\crcr\omit
{\xdef\TY@save@row{}%
@@ -174,7 +172,6 @@ Z \message{> tymin}%
\TY@checkmin
\TY@count\z@
\let\TY@box\TY@box@v
- \let\footnote\TY@footnote % restore footnotes
{\expandafter\TY@final\the\toks@\endTY@final}%
\count@\z@
\@tempswatrue
@@ -195,7 +192,7 @@ Z \message{> tymin}%
\let\TY@checkmin\relax
\ifdim\TY@tablewidth>\z@
\Gscale@div\TY@ratio\TY@linewidth\TY@tablewidth
- \ifdim\TY@tablewidth <\linewidth
+ \ifdim\TY@tablewidth <\TY@linewidth
\def\TY@ratio{1}%
\fi
\else