summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex/epslatex-fr/g_toc_entry.sty
blob: 417490c1eab7e9103eaeb1d4b31af49f9c83c6a2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
%
% $Id: g_toc_entry.sty,v 3.26 1992/03/25 04:53:29 woo Exp woo $
%
% G_TOC_ENTRY.STY of 13 Dec 90
% written by Stefan Timphus
% adapted by Jean-Pierre Drucbert 19 Nov 1993
% TOC_ENTRY.STY -> G_TOC_ENTRY.STY
%
% Will produce the right space for sectionnumbers
% in the tableofcontents
% Necessary for entries where the number for each kind of section
% is greater 10 (e.g. "12.14.18 Sectionname")
% When using the original definition the first letter
% of the sectionname overwrites the last number
% of the sectionnumber
%
% call adjustments with command \adjustSTYLENAME
%

\typeout{`g_toc_entry.sty' 1.1 of 19 Nov 93}

%
% HERE ARE THE ORIGINAL DEFINITIONS
%

% article.sty
%
%\def\l@subsection{\@dottedtocline{2}{1.5em}{2.3em}}
%\def\l@subsubsection{\@dottedtocline{3}{3.8em}{3.2em}}
%\def\l@paragraph{\@dottedtocline{4}{7.0em}{4.1em}}
%\def\l@subparagraph{\@dottedtocline{5}{10em}{5em}}

% report.sty and book.sty
%
%\def\l@section{\@dottedtocline{1}{1.5em}{2.3em}}
%\def\l@subsection{\@dottedtocline{2}{3.8em}{3.2em}}
%\def\l@subsubsection{\@dottedtocline{3}{7.0em}{4.1em}}
%\def\l@paragraph{\@dottedtocline{4}{10em}{5em}}
%\def\l@subparagraph{\@dottedtocline{5}{12em}{6em}}
%\def\l@figure{\l@dottedtocline{1}{1.5em}{2.3em}}
%\def\l@table{\l@dottedtocline{1}{1.5em}{2.3em}}

%
% MODIFICATIONS:
%

\def\@pnumwidth{4.5ex}  % 4-digits page numbers
\def\@tocrmarg {2.55em} % unchanged
\def\@dotsep{4.5}       % unchanged

% article:
% 99 sections, 999 subsections, 99 subsubsections,
% 99 paragraphs, 99 subparagraphs

\newlength{\twonum} \settowidth{\twonum}{99.999.}
% -W for sub-figures/tables
\newlength{\twonuma} \settowidth{\twonuma}{99.999.-W}
\newlength{\threenum} \settowidth{\threenum}{99.999.99.}
\newlength{\fournum} \settowidth{\fournum}{99.999.99.99.}
\newlength{\fivenum} \settowidth{\fivenum}{99.999.99.99.99.}
\newlength{\sixnum} \settowidth{\sixnum}{99.999.99.99.99.99.}

\newcommand{\adjustarticle}
{\def\l@subsection{\@dottedtocline{2}{0.5em}{\twonum}}
\def\l@subsubsection{\@dottedtocline{3}{1.5em}{\threenum}}
\def\l@paragraph{\@dottedtocline{4}{1.5em}{\fournum}}
\def\l@subparagraph{\@dottedtocline{5}{1.5em}{\fivenum}}
\def\l@figure{\@dottedtocline{1}{1.em}{\twonuma}}
\def\l@table{\@dottedtocline{1}{1.em}{\twonuma}}}

% report, book:
% 99 chapters, 999 sections, 99 subsections,
% 99 subsubsections, 99 paragraphs, 99 subparagraphs

\newcommand{\adjustreport}
{\def\l@section{\@dottedtocline{1}{0.5em}{\twonum}}
\def\l@subsection{\@dottedtocline{2}{1.5em}{\threenum}}
\def\l@subsubsection{\@dottedtocline{3}{1.5em}{\fournum}}
\def\l@paragraph{\@dottedtocline{4}{1.5em}{\fivenum}}
\def\l@subparagraph{\@dottedtocline{5}{1.5em}{\sixnum}}
\def\l@figure{\@dottedtocline{1}{1.em}{\twonuma}}
\def\l@table{\@dottedtocline{1}{1.em}{\twonuma}}}

\newcommand{\adjustbook}{\adjustreport}


% end of G_TOC_ENTRY.STY