summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex/etoc/etocsnippet-03.tex
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/doc/latex/etoc/etocsnippet-03.tex')
-rw-r--r--Master/texmf-dist/doc/latex/etoc/etocsnippet-03.tex46
1 files changed, 17 insertions, 29 deletions
diff --git a/Master/texmf-dist/doc/latex/etoc/etocsnippet-03.tex b/Master/texmf-dist/doc/latex/etoc/etocsnippet-03.tex
index e0d0e8ca795..01d153eacb5 100644
--- a/Master/texmf-dist/doc/latex/etoc/etocsnippet-03.tex
+++ b/Master/texmf-dist/doc/latex/etoc/etocsnippet-03.tex
@@ -1,32 +1,20 @@
%% LaTeX2e file `etocsnippet-03.tex'
%% generated by the `filecontentsdef' environment
-%% from source `etoc' on 2023/01/21.
+%% from source `etoc' on 2023/03/02.
%%
-\begingroup % we start a group to keep the style changes local
-\newlength{\tocleftmargin} \setlength{\tocleftmargin}{5cm}
-\newlength{\tocrightmargin} \setlength{\tocrightmargin}{1cm}
-
-\etocsetstyle{section} % will pretend to be a Chapter
-{\addvspace{1ex}\parfillskip0pt
- \leftskip\tocleftmargin % (already done in title)
- \rightskip\the\tocrightmargin plus 1fil
- \parindent0pt\color{cyan}} % (already done)
-{\bfseries\LARGE\upshape\addvspace{1ex}\leavevmode}
-{\llap{Chapter\hspace{.5em}{\etocnumber}\hspace{.75cm}}\etocname
- \hfill\makebox[-\tocrightmargin][l]{\makebox[0pt]{\etocpage}}\par}
-{}
-
-\etocsetstyle{subsection} % will pretend to be a Section
-{}
-{\mdseries\large\addvspace{.5ex}\leavevmode}
-{\llap{\etocnumber\hspace{.75cm}}\textit{\etocname}%
- \hfill\makebox[-\tocrightmargin][l]{\makebox[0pt]{\etocpage}}\par}
-{}
-
-\def\tmptitle{My Beautiful Thesis}
-\etocsettocstyle{\color{cyan}\parindent0pt \leftskip\tocleftmargin
- \leavevmode\leaders\hrule height 1pt\hfill\
- \huge\textit{\tmptitle}\par}{\bigskip}
-
-\tableofcontents \ref{toc:overview}
-\endgroup
+\begin{figure}[ht!]
+ \centering
+ \begingroup
+ % this is a KOMA-script specific customization
+ \DeclareTOCStyleEntry[numwidth=2em,indent=0pt]{tocline}{section}
+ \DeclareTOCStyleEntry[numwidth=3.2em,indent=2em]{tocline}{subsection}
+ \etocstandardlines % <-- use the defaults from the document class
+ \renewcommand{\etocbkgcolorcmd}{\color{green!5}}
+ \renewcommand{\etocbelowtocskip}{0pt\relax}
+ \fboxsep1ex
+ \etocframedstyle [1]{\fbox{\makebox[.5\linewidth]{\etocfontminusone
+ I am from \hyperref[toc:part:styling]{far away}}}}
+ \etocsetnexttocdepth{subsection}
+ \tableofcontents \label{toc:d} \ref{toc:part:styling}
+ \endgroup
+\end{figure}