summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2013-07-15 22:46:30 +0000
committerKarl Berry <karl@freefriends.org>2013-07-15 22:46:30 +0000
commitb927b3c4405faf2fc0c1a8b34e07cc7c5dd5b5e8 (patch)
tree3f0b50cbbf4621a283f566948a7f04fe91237876 /Master/texmf-dist/doc/latex
parentbaf92cd2b6a50c9aaf590f0c88a71532f72667dd (diff)
tcolorbox (15jul13)
git-svn-id: svn://tug.org/texlive/trunk@31204 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex')
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/CHANGES32
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/README2
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox-example.pdfbin274531 -> 274565 bytes
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox-example.tex10
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.abstract.tex2
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.bib8
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.coremacros.tex28
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.coreoptions.tex197
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.documentation.tex69
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.fitting.tex9
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.initoptions.tex207
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.intro.tex3
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.listings.tex136
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.theorems.tex119
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.pdfbin2647515 -> 2821113 bytes
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.tex129
16 files changed, 818 insertions, 133 deletions
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/CHANGES b/Master/texmf-dist/doc/latex/tcolorbox/CHANGES
index 0fac352a7fc..c05aa0ba06d 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/CHANGES
+++ b/Master/texmf-dist/doc/latex/tcolorbox/CHANGES
@@ -1,4 +1,4 @@
-%% The LaTeX package tcolorbox - version 2.33 (2013/07/04)
+%% The LaTeX package tcolorbox - version 2.40 (2013/07/15)
%%
%% -------------------------------------------------------------------------------------------
%% Copyright (c) 2006-2013 by Prof. Dr. Dr. Thomas F. Sturm <thomas dot sturm at unibw dot de>
@@ -257,3 +257,33 @@ version 2.33 (2013/07/04)
- parameter added to option 'oversize'
- option 'toggle enlargement' has a default value 'evenpage' now
+version 2.40 (2013/07/15)
+- bug fix: wrong footnote text width for breakable boxes
+- bug fix: watermarks were influenced by baseline settings
+- package etoolbox is now loaded by default
+- 'phantom' changed to be stackable (!)
+- introducing the new initialization option type for easy
+ numbering and list generation. New options:
+ 'use counter', 'auto counter', 'use counter from',
+ 'no counter', 'number within', 'number format', 'number freestyle',
+ 'list inside', 'list type'
+- '\newtcolorbox' and 'newtcbox' take initialization options now
+- new macros '\tcblistof', '\tcbsetmanagedlayers'
+- introducing the layered box concept for boxes in boxes improvement:
+ * boxes inside boxes are automatically reset to default values
+ * new option 'every box', 'every box on layer x', 'every box on higher layers'
+ * support for footnotes for boxes in boxes (default: up to layer 4)
+- new options 'step', 'label', 'list entry', 'add to list'
+- library 'listings':
+ * '\newtcblisting' takes initialization options now
+ * new macro '\newtcbinputlisting'
+- library 'theorems':
+ * '\tcbmaketheorem' takes initialization options now
+ * new macro '\newtcbtheorem'
+- library 'fitting':
+ * 'newtcboxfit' takes initialization options now
+- library 'documentation':
+ * the \ref... macros suppress the page numbers now if on the same page
+ * new macros '\refCom*', '\refEnv*', '\refKey*'
+ * docCommand and docEnvironment take options now
+
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/README b/Master/texmf-dist/doc/latex/tcolorbox/README
index f38eca9f9f1..822c82956fe 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/README
+++ b/Master/texmf-dist/doc/latex/tcolorbox/README
@@ -1,4 +1,4 @@
-%% The LaTeX package tcolorbox - version 2.33 (2013/07/04)
+%% The LaTeX package tcolorbox - version 2.40 (2013/07/15)
%%
%% -------------------------------------------------------------------------------------------
%% Copyright (c) 2006-2013 by Prof. Dr. Dr. Thomas F. Sturm <thomas dot sturm at unibw dot de>
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox-example.pdf b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox-example.pdf
index 4c866dc2eff..cb6a19c21c3 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox-example.pdf
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox-example.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox-example.tex b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox-example.tex
index 90b5a446a39..31e236008de 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox-example.tex
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox-example.tex
@@ -1,4 +1,4 @@
-%% The LaTeX package tcolorbox - version 2.33 (2013/07/04)
+%% The LaTeX package tcolorbox - version 2.40 (2013/07/15)
%% tcolorbox-example.tex: an example for tcolorbox
%%
%% -------------------------------------------------------------------------------------------
@@ -88,11 +88,9 @@ This is a \LaTeX\ example:
%----------------------------------------------------------
\section{Theorems}
-\newcounter{mytheorem}[section]
-\def\themytheorem{\thesection.\arabic{mytheorem}}
-
-\tcbmaketheorem{theo}{Theorem}{fonttitle=\bfseries\upshape, fontupper=\slshape,
- arc=0mm, colback=blue!5!white,colframe=blue!75!black}{mytheorem}{theorem}
+\newtcbtheorem[auto counter,number within=section]{theo}%
+ {Theorem}{fonttitle=\bfseries\upshape, fontupper=\slshape,
+ arc=0mm, colback=blue!5!white,colframe=blue!75!black}{theorem}
\begin{theo}{Summation of Numbers}{summation}
For all natural number $n$ it holds:
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.abstract.tex b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.abstract.tex
index eaedb8f7bff..c38a0d266b9 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.abstract.tex
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.abstract.tex
@@ -24,7 +24,7 @@
colback=yellow!10!white,colframe=red!50!black,before=\par\bigskip\noindent,
watermark color=yellow!75!red!25!white,pad at break=3mm,
watermark text={\bfseries\Large Contents},
- enlargepage=2\baselineskip,
+ %enlargepage=2\baselineskip,
drop fuzzy shadow]
\makeatletter
\@starttoc{toc}
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.bib b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.bib
index 54b2c68e534..d222847b8ad 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.bib
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.bib
@@ -122,3 +122,11 @@
date = {2013-04-01},
}
+
+@manual{lehmann:2011a,
+ author = {Philipp Lehman},
+ title = {The etoolbox Package},
+ url = {http://mirror.ctan.org/macros/latex/contrib/etoolbox/etoolbox.pdf},
+ date = {2011-01-03},
+}
+
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.coremacros.tex b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.coremacros.tex
index b2a06f43b6c..95c117a5059 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.coremacros.tex
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.coremacros.tex
@@ -65,6 +65,8 @@ Here, you see the lower part of the box.
\clearpage
\begin{docCommand}{tcbset}{\marg{options}}
Sets options for every following \refEnv{tcolorbox} inside the current \TeX\ group.
+ By default, this does not apply to nested boxes, see
+ Section \ref{subsec:everybox} from page \pageref{subsec:everybox}.\par
For example, the colors of the boxes may be defined for the whole document by this:
\begin{dispListing}
\tcbset{colback=red!5!white,colframe=red!75!black}
@@ -101,7 +103,7 @@ Text \tcbox[tcbox raise base]{Hello World}\hfill
\end{docCommand}
\clearpage
-\begin{docCommand}{newtcolorbox}{\marg{name}\oarg{number}\oarg{default}\marg{options}}
+\begin{docCommand}{newtcolorbox}{\oarg{init options}\marg{name}\oarg{number}\oarg{default}\marg{options}}
Creates a new environment \meta{name} based on \refEnv{tcolorbox}.
Basically, |\newtcolorbox| operates like |\newenvironment|. This means,
the new environment \meta{name} optionally takes \meta{number} arguments, where
@@ -109,6 +111,8 @@ Text \tcbox[tcbox raise base]{Hello World}\hfill
The \meta{options} are given to the underlying |tcolorbox|.
Note that \refKey{/tcb/savedelimiter} is set to the given \meta{name}
automatically.
+ The \meta{init options} allow to set up automatic numbering,
+ see Section \ref{sec:initkeys} from page \pageref{sec:initkeys}.
\begin{dispExample*}{sbs,lefthand ratio=0.6}
\newtcolorbox{mybox}{colback=red!5!white,
colframe=red!75!black}
@@ -138,15 +142,27 @@ This is my own box with a mandatory title
and options.
\end{mybox}
\end{dispExample*}
+
+\inputpreamblelisting{A}
+
+\begin{dispExample*}{sbs,lefthand ratio=0.6}
+\begin{pabox}[colback=yellow]{Hello there}
+This is my own box with a mandatory
+numbered title and options.
+\end{pabox}
+\end{dispExample*}
\end{docCommand}
-\begin{docCommand}{newtcbox}{\marg{\texttt{\textbackslash}name}\oarg{number}\oarg{default}\marg{options}}
+\clearpage
+\begin{docCommand}{newtcbox}{\oarg{init options}\marg{\texttt{\textbackslash}name}\oarg{number}\oarg{default}\marg{options}}
Creates a new macro \meta{\texttt{\textbackslash}name} based on \refCom{tcbox}.
Basically, |\newtcbox| operates like |\newcommand|.
The new macro \meta{\texttt{\textbackslash}name} optionally takes \meta{number}$+1$ arguments, where
\meta{default} is the default value for the optional first argument.
The \meta{options} are given to the underlying |tcbox|.
+ The \meta{init options} allow to set up automatic numbering,
+ see Section \ref{sec:initkeys} from page \pageref{sec:initkeys}.
\begin{dispExample*}{sbs,lefthand ratio=0.6}
\newtcbox{\mybox}{colback=red!5!white,
colframe=red!75!black}
@@ -170,6 +186,14 @@ and options.
\mybox[colback=yellow]{Hello there}%
{This is my own box.}
\end{dispExample*}
+
+\inputpreamblelisting{B}
+
+\begin{dispExample*}{sbs,lefthand ratio=0.6}
+\pbbox[colback=yellow]{Hello there}%
+ {This is my own box.}
+\end{dispExample*}
+
\end{docCommand}
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.coreoptions.tex b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.coreoptions.tex
index c220d7ceb70..c96326f8f5e 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.coreoptions.tex
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.coreoptions.tex
@@ -1357,10 +1357,9 @@ are drawn by the codes given with
%\newlength{\examlen}
\colorlet{colexam}{red!75!black}
-\newtcolorbox{myexample}{%
- phantom={\refstepcounter{example}%
- \settowidth{\global\examlen}{\Large\bfseries Example \arabic{example}}},%
- title={Example \arabic{example}},
+\newtcolorbox[use counter=example]{myexample}{%
+ phantom={\settowidth{\global\examlen}{\Large\bfseries Example \thetcbcounter}},%
+ title={Example \thetcbcounter},
coltitle=colexam,fonttitle=\Large\bfseries,
enhanced,breakable,before=\par\medskip,parbox=false,
frame hidden,interior hidden,segmentation hidden,
@@ -1396,17 +1395,16 @@ are drawn by the codes given with
\begin{dispExample}
% \tcbuselibrary{skins}
% \newcounter{example}
-\newtcolorbox{FancyTitle}[3][]{%
+\newtcolorbox[use counter=example]{FancyTitle}[3][]{%
enhanced,colback=blue!10!white,colframe=orange,top=4mm,
enlarge top by=\baselineskip/2+1mm,
enlarge top at break by=0mm,pad at break=2mm,
- fontupper=\normalsize,
- step and label={example}{#3},
+ fontupper=\normalsize,label={#3},
overlay unbroken and first={%
\node[rectangle,rounded corners,draw=black,fill=blue!20!white,
inner sep=1mm,anchor=west,font=\small]
at ([xshift=4.5mm]frame.north west)
- {\strut\textbf{Example \arabic{example}: #2}};},
+ {\strut\textbf{Example \thetcbcounter: #2}};},
#1}%
\begin{FancyTitle}{My fancy title}{fancy:title}
@@ -1885,6 +1883,133 @@ et malesuada fames ac turpis egestas. \tcbox{Mauris ut leo.}
\end{dispExample}
\end{docTcbKey}
+\clearpage
+\subsection{Layered Boxes and Every Box Settings}\label{subsec:everybox}
+A |tcolorbox| may contain another |tcolorbox| and so on. The package
+takes track of the nesting level using a counter |tcblayer|. Counter values
+may be used for doing some fancy things, but you should never change
+the counter value yourself.
+
+The package takes special care for the first four layers or nesting levels,
+called managed layers.
+Here, footnote texts are administrated to find their intended place
+and specific layer dependent options may be set by changing
+\refKey{/tcb/every box on layer n}.
+If needed, the number of managed layers can be increased by setting
+\refCom{tcbsetmanagedlayer} to a higher value than 4.
+
+The following styles have a considerable influence on how layered boxes
+are processed. Note especially that nested boxes are getting a
+\refKey{/tcb/reset} by default. You can change this, but be prepared for
+suprises if you do.
+
+If the defaults are \emph{not changed}, a |tcolorbox| gets its options
+in the following order. Following options overwrite preceding options.
+\begin{enumerate}
+\item On package load, all options are set to default values.
+\item Every \refCom{tcbset} command adds or changes options for the following boxes
+ inside the current \TeX\ group.
+\item While entering a |tcolorbox|, a \refKey{/tcb/every box on layer n} or
+ \refKey{/tcb/every box on higher layers} option list is applied.
+ With default settings this means:
+ \begin{itemize}
+ \item For layer 1 (lowest layer), the \refKey{/tcb/every box} option list is applied.
+ Not overwritten options given by a preceding \refCom{tcbset} survive.
+ \item For layer 2 and above (nested boxes), a \refKey{/tcb/reset} followed by
+ \refKey{/tcb/every box} option list is applied.
+ Every resettable options given by a preceding \refCom{tcbset}
+ and by the sourrounding box(es) are reset.
+ \end{itemize}
+\item The \meta{options} given to the |tcolorbox| are applied.
+ Or, if the box was generated by \refCom{newtcolorbox} or friends,
+ the \meta{options} given there are applied.
+\item If the box was generated by \refCom{newtcolorbox} or friends,
+ some automated options are applied.
+\end{enumerate}
+
+
+\begin{docTcbKey}{every box}{}{style}
+By default, this style is empty.
+\begin{dispListing}
+% default setting:
+\tcbset{every box/.style={}}
+\end{dispListing}
+It may be changed by redefining this style.
+\begin{dispListing}
+% setting all boxes to be enhanced:
+\tcbset{every box/.style={enhanced}}
+\end{dispListing}
+\end{docTcbKey}
+
+\clearpage
+\begin{docTcbKey}{every box on layer n}{}{style}
+Here, |n| has to be replaced by a number ranging from 1 to the highest
+managed layer number (4 by default).
+\begin{dispListing}
+% default settings:
+\tcbset{
+ every box on layer 1/.style={every box},
+ every box on layer 2/.style={reset,every box},
+ every box on layer 3/.style={reset,every box},
+ every box on layer 4/.style={reset,every box},
+ }
+\end{dispListing}
+\end{docTcbKey}
+
+
+\begin{docTcbKey}{every box on higher layers}{}{style}
+Higher layers are layers above the highest
+managed layer number (4 by default).
+\begin{dispListing}
+\tcbset{every box on higher layers/.style={reset,every box}}
+\end{dispListing}
+\end{docTcbKey}
+
+
+\begin{docCommand}{tcbsetmanagedlayer}{\marg{number}}
+Replaces the highest managed layer number by \meta{number} where 4 is
+the default. This macro can only be used inside the preamble.
+Using a \meta{number} lower than 4 typically makes no sense, but is
+not forbidden.
+\end{docCommand}
+
+\begin{tcboutputlisting}
+% \usepackage{lipsum}
+% \tcbuselibrary{skins,breakable}
+\tcbset{enhanced,breakable,colframe=red!75!black,fonttitle=\bfseries,
+ colback=red!5!white,
+ every box/.style={enhanced,watermark text=\thetcblayer,
+ before=\par\smallskip,after=\par\smallskip},
+ every box on layer 2/.style={reset,every box,colback=yellow!10!white,
+ drop fuzzy shadow}}
+\begin{tcolorbox}[title=Layer 1 Box]
+Here comes a footnote\footnote{Footnote from layer 1 box}.
+\lipsum[2]
+ \begin{tcolorbox}[title=Layer 2 Box]
+ abc\footnote{The footnote of abc}
+ \end{tcolorbox}
+ \begin{tcolorbox}[title=Another Box,ams equation]
+ \tcbhighmath{\sum\limits_{n=1}^{\infty} \frac{1}{n}} = \infty.
+ \end{tcolorbox}
+Some text\footnote{Footnote from some text}.
+ \begin{tcolorbox}[title=Yet Another Box]
+ \tcboxfit[height=2cm]{\lipsum[1]}
+ My text.
+ \begin{tcolorbox}
+ Another lipsum text\footnote{A lipsum text}. \lipsum[3]
+ \begin{tcolorbox}[title=Layer 4,colframe=blue,colback=white]
+ Layer 4\footnote{Layer 4 footnote}
+ \end{tcolorbox}
+ The End\footnote{Last footnote}.
+ \end{tcolorbox}
+ \end{tcolorbox}
+\end{tcolorbox}
+\end{tcboutputlisting}
+
+\tcbinputlisting{base example,listing only,listing style=mydocumentation}
+
+{\tcbuselistingtext}
+
\clearpage
\subsection{Capture Mode}\label{subsec:capture}
@@ -2013,12 +2138,13 @@ the core package are therefore described in section \ref{sec:skincorekeys} from
page \pageref{sec:skincorekeys}.
\clearpage
-\subsection{Counters and Page References}
+\subsection{Counters, Labels and References}
\begin{docTcbKey}{phantom}{=\meta{code}}{no default, initially unset}
The \meta{code} is put in a box at the upper left corner of the |tcolorbox|.
If the |tcolorbox| is breakable, the \meta{code} is executed for the first box of
-the break sequence only.\par
+the break sequence only. If there already was some phantom code given, the
+new \meta{code} is appended.\par
The \meta{code} is intended to be used for counter stepping, labelling, and
related operations which do not produce visible text.
\begin{itemize}
@@ -2042,14 +2168,50 @@ Example \ref{exe:tabular_example} on page \pageref{exe:tabular_example}.
Removes the phantom code if set before.
\end{docTcbKey}
+\begin{docTcbKey}{label}{=\meta{marker}}{no default, initially unset}
+Shortcut for |phantom={\label{#1}}|. The \meta{marker} is set as label text
+for a reference with the |\ref| macro.
+Typically, this option is used for numbered boxes, see Subsection \ref{sec:numberedboxes}
+from page \pageref{sec:numberedboxes}, e.\,g.\ \refKey{/tcb/new/auto counter}.
+\end{docTcbKey}
+
+\begin{docTcbKey}{step}{=\meta{counter}}{no default, initially unset}
+Shortcut for |phantom={\refstepcounter{#1}}|. The given \meta{counter} is
+increased and ready for labelling. This option is not needed when
+using the convenient automated numbering introduced with version 2.40,
+see Subsection \ref{sec:numberedboxes}
+from page \pageref{sec:numberedboxes}.
+\end{docTcbKey}
+
\begin{docTcbKey}{step and label}{=\marg{counter}\marg{marker}}{no default, initially unset}
-Shortcut for |phantom={\refstepcounter{#1}\label{#2}}|. The \meta{counter} is
-increased and the \meta{marker} is set as label text.\par
-Examples for the |phantom| usage are given in Section \ref{sec:latextutorial}
-from page \pageref{sec:latextutorial}, e.\,g.\
-Example \ref{firstExample} on page \pageref{firstExample}.
+Shortcut for using \refKey{/tcb/step} and \refKey{/tcb/label}. This option is not needed when
+using the convenient automated numbering introduced with version 2.40,
+see Subsection \ref{sec:numberedboxes}
+from page \pageref{sec:numberedboxes}.
\end{docTcbKey}
+
+\begin{docTcbKey}{list entry}{=\meta{text}}{no default, initially unset}
+If the \flqq list of tcolorbox(es)\frqq\ feature described in Subsection
+\ref{sec:listsof} from page \pageref{sec:listsof} is used, this key
+describes the \meta{text} for an entry into the generated list, e.\,g.
+\begin{dispListing}
+list entry={\numberline{\thetcbcounter}My beautiful Example}
+\end{dispListing}
+See Section \ref{listing:exercises} from page \pageref{listing:exercises}
+for a complete example.
+\end{docTcbKey}
+
+\begin{docTcbKey}{add to list}{=\marg{list}\marg{type}}{no default, initially unset}
+If the \flqq list of tcolorbox(es)\frqq\ feature described in Subsection
+\ref{sec:listsof} from page \pageref{sec:listsof} is used, list entries are
+generated automatically. With this key, you can enforce an entry to the
+given \meta{list} with the given \meta{type}.
+This issues:\\
+|\addcontentsline|\marg{list}\marg{type}\marg{entry text}
+\end{docTcbKey}
+
+
\clearpage
\begin{docTcbKey}{check odd page}{\colOpt{=\meta{boolean value}}}{default |true|, initially |false|}
If set to |true|, the even/odd page testing from the package |changepage|
@@ -2127,5 +2289,8 @@ Sets (nearly) all |tcolorbox| settings (including loaded libraries) back to thei
\refKey{/tcb/savedelimiter} and \refKey{/tcb/capture} keep their values.
This option is useful for boxes in boxes where the inner box should not inherit
the settings of the outer box.
-See \refCom{tcbhighmath} for an example.
+Note that for boxes inside boxes the |reset| is done automatically, if the
+standard settings of the package are used (v2.40 and above), see
+Section \ref{subsec:everybox} from page \pageref{subsec:everybox}.
+%See \refCom{tcbhighmath} for an example.
\end{docTcbKey}
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.documentation.tex b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.documentation.tex
index 24e8e35dffd..4d7fa97d35b 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.documentation.tex
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.documentation.tex
@@ -14,7 +14,7 @@ The library is loaded by a package option or inside the preamble by:
\end{dispListing}
This also loads the library 'listings', see section \ref{sec:listings},
and a bunch of packages, namely
-|doc|, |pifont|, |marvosym|, |hyperref|, and |makeidx|.
+|doc|, |pifont|, |marvosym|, |hyperref|, |makeidx|, and |refcount|.
For UTF-8 support, load:
\begin{dispListing}
@@ -24,9 +24,10 @@ For UTF-8 support, load:
\subsection{Macros of the Library}
-\begin{docEnvironment}{docCommand}{\marg{name}\marg{parameters}}
+\begin{docEnvironment}[doclang/environment content=command description]{docCommand}{\oarg{options}\marg{name}\marg{parameters}}
Documents a \LaTeX\ macro with given \meta{name} where \meta{name} is
- written without backslash. This macro takes mandatory or optional \meta{parameters}.
+ written without backslash. The given \meta{options} are set with \refCom{tcbset}.
+ This macro takes mandatory or optional \meta{parameters}.
It is automatically indexed and can be referenced with
\refCom{refCom}\marg{name}.
\begin{dispExample}
@@ -35,13 +36,21 @@ For UTF-8 support, load:
documentation of keys with the given \meta{key path}.
\end{docCommand}
\end{dispExample}
+\begin{dispExample}
+\begin{docCommand}[color definition=blue]{foomakedocSubKey*}%
+ {\marg{name}\marg{key path}}
+ Creates a new environment \meta{name} based on \refEnv{docKey} for the
+ documentation of keys with the given \meta{key path}.
+\end{docCommand}
+\end{dispExample}
\end{docEnvironment}
-
+\clearpage
{\let\xdocEnvironment\docEnvironment
\let\endxdocEnvironment\enddocEnvironment
-\begin{xdocEnvironment}{docEnvironment}{\marg{name}\marg{parameters}}
+\begin{xdocEnvironment}[doclang/environment content=environment description]{docEnvironment}{\oarg{options}\marg{name}\marg{parameters}}
Documents a \LaTeX\ environment with given \meta{name}.
+ The given \meta{options} are set with \refCom{tcbset}.
This environment takes mandatory or optional \meta{parameters}.
It is automatically indexed and can be referenced with
\refCom{refEnv}\marg{name}.
@@ -51,10 +60,18 @@ For UTF-8 support, load:
rounded corners and, optionally, two parts.
\end{docEnvironment}
\end{dispExample}
+\begin{dispExample}
+\begin{docEnvironment}%
+ [doclang/environment content=My content text]%
+ {foocolorbox*}{\oarg{options}}
+ This is the main environment to create an accentuated colored text box with
+ rounded corners and, optionally, two parts.
+\end{docEnvironment}
+\end{dispExample}
\end{xdocEnvironment}}
-\clearpage
-\begin{docEnvironment}{docKey}{\oarg{key path}\marg{name}\marg{parameters}\marg{description}}
+
+\begin{docEnvironment}[doclang/environment content=key description]{docKey}{\oarg{key path}\marg{name}\marg{parameters}\marg{description}}
Documents a key with given \meta{name} and an optional \meta{key path}.
This key takes mandatory or optional \meta{parameters} as value
with a short \meta{description}.
@@ -77,7 +94,7 @@ The macro \docAuxCommand{fooaux} holds some interesting data.
\end{dispExample}
\end{docCommand}
-
+\clearpage
\begin{docCommand}{docColor}{\marg{name}}
Documents a color with given \meta{name}. The color is automatically indexed.
\begin{dispExample}
@@ -109,7 +126,7 @@ This is a mandatory \marg{argument}.
\end{dispExample}
\end{docCommand}
-\clearpage
+
\begin{docCommand}{oarg}{\marg{text}}
Macro from |ltxdoc| \cite{carlisle:2007a} to typeset a \meta{text} with
square brackets as an optional argument. The library overwrites the original macro.
@@ -126,7 +143,7 @@ This is an optional \oarg{argument}.
\end{dispExample}
\end{docCommand}
-
+\clearpage
{\let\xdispExample\dispExample
\let\endxdispExample\enddispExample
@@ -214,27 +231,57 @@ Some key.
\begin{docCommand}{refCom}{\marg{name}}
References a documented \LaTeX\ macro with given \meta{name} where \meta{name} is
- written without backslash.
+ written without backslash. The page reference is suppressed if it links
+ to the same page.
\begin{dispExample}
We have created \refCom{foomakedocSubKey} as an example.
\end{dispExample}
\end{docCommand}
+\begin{docCommand}{refCom*}{\marg{name}}
+ References a documented \LaTeX\ macro with given \meta{name} where \meta{name} is
+ written without backslash. There is no page reference.
+\begin{dispExample}
+We have created \refCom*{foomakedocSubKey} as an example.
+\end{dispExample}
+\end{docCommand}
+
+
\begin{docCommand}{refEnv}{\marg{name}}
References a documented \LaTeX\ environment with given \meta{name}.
+ The page reference is suppressed if it links to the same page.
\begin{dispExample}
We have created \refEnv{foocolorbox} as an example.
\end{dispExample}
\end{docCommand}
+\begin{docCommand}{refEnv*}{\marg{name}}
+ References a documented \LaTeX\ environment with given \meta{name}.
+ There is no page reference.
+\begin{dispExample}
+We have created \refEnv*{foocolorbox} as an example.
+\end{dispExample}
+\end{docCommand}
+
+\clearpage
\begin{docCommand}{refKey}{\marg{name}}
References a documented key with given \meta{name} where \meta{name}
is the full path name of the key.
+ The page reference is suppressed if it links to the same page.
\begin{dispExample}
We have created \refKey{/foo/footitle} as an example.
\end{dispExample}
\end{docCommand}
+\begin{docCommand}{refKey*}{\marg{name}}
+ References a documented key with given \meta{name} where \meta{name}
+ is the full path name of the key.
+ There is no page reference.
+\begin{dispExample}
+We have created \refKey*{/foo/footitle} as an example.
+\end{dispExample}
+\end{docCommand}
+
%
\begin{docCommand}{colDef}{\marg{text}}
Sets \meta{text} with the definition color, see \refKey{/tcb/color definition}.
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.fitting.tex b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.fitting.tex
index e0d360cfe2c..e3afeacb0f5 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.fitting.tex
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.fitting.tex
@@ -36,12 +36,14 @@ The library is loaded by a package option or inside the preamble by:
\end{docCommand}
-\begin{docCommand}{newtcboxfit}{\marg{\texttt{\textbackslash}name}\oarg{number}\oarg{default}\marg{options}}
+\begin{docCommand}{newtcboxfit}{\oarg{init options}\marg{\texttt{\textbackslash}name}\oarg{number}\oarg{default}\marg{options}}
Creates a new macro \meta{\texttt{\textbackslash}name} based on \refCom{tcboxfit}.
Basically, |\newtcboxfit| operates like |\newcommand|.
The new macro \meta{\texttt{\textbackslash}name} optionally takes \meta{number}$+1$ arguments, where
\meta{default} is the default value for the optional first argument.
The \meta{options} are given to the underlying |tcboxfit|.
+ The \meta{init options} allow to set up automatic numbering,
+ see Section \ref{sec:initkeys} from page \pageref{sec:initkeys}.
\begin{dispExample*}{sbs,lefthand ratio=0.6}
\newtcboxfit{\mybox}{colback=red!5!white,
colframe=red!75!black,width=4cm,
@@ -134,7 +136,7 @@ The \refCom{tcboxfit} macro uses this algorithm by default.
\newtcolorbox{fitting}[2][]{fit,height=#2,boxsep=1pt,valign=center,
top=0.4\tcbfitdim,bottom=0.4\tcbfitdim,
left=0.75\tcbfitdim,right=0.75\tcbfitdim,
- enhanced,watermark text=\tcbfitsteps,
+ enhanced,watermark text={\tcbfitsteps},
colframe=blue!75!black,colback=white,#1}
\begin{fitting}{4cm}
@@ -322,7 +324,8 @@ If a \refKey{/tcb/fit width plus} is applied, the title is also adapted to
the new width. If counters are increased inside the title text, they may be
increased more than one time.
To avoid this, you are encouraged to use \refKey{/tcb/phantom} or \refKey{/tcb/step and label}
-to set counters.
+to set counters or use automatic numbering, see Subsection \ref{sec:numberedboxes}
+from page \pageref{sec:numberedboxes}.
\end{marker}
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.initoptions.tex b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.initoptions.tex
new file mode 100644
index 00000000000..e1335c1f5db
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.initoptions.tex
@@ -0,0 +1,207 @@
+% !TeX root = tcolorbox.tex
+% include file of tcolorbox.tex (manual of the LaTeX package tcolorbox)
+\clearpage
+\section{Initialization Option Keys}\label{sec:initkeys}
+The \emph{initialization} options are only applicable for the generation
+of new environments and commands based on |tcolorbox| and friends.
+Particularly, they can be used for
+\begin{itemize}
+\item\refCom{newtcolorbox},
+\item\refCom{newtcbox},
+\item\refCom{newtcblisting},
+\item\refCom{newtcbinputlisting},
+\item\refCom{newtcbtheorem}, and
+\item\refCom{newtcboxfit}.
+\end{itemize}
+
+\bigskip
+\begin{marker}
+Typically, these options may generate counters and alike.
+It is \textbf{strongly} recommended to use initialization options inside
+the preamble only. Otherwise, you may get trouble when using \LaTeX's |\include| features.
+\end{marker}
+
+
+\subsection{Numbered Boxes}\label{sec:numberedboxes}
+Counters assigned using the initialization options are administrated
+automatically. Especially, they are increased for each new box.
+Independent from the real counter name, the counter value can be
+referenced by \docAuxCommand{thetcbcounter}, e.\,g.\ inside the title of
+the box. The real counter name is stored inside \docAuxCommand{tcbcounter}.
+
+\begin{newTcbKey}{auto counter}{}{no value, initially unset}
+Creates a new counter automatically.
+With \refKey{/tcb/new/number format} and
+\refKey{/tcb/new/number within}, the appearance and behavior of the counter
+can be changed. The counter value is referenced by \docAuxCommand{thetcbcounter}.
+
+\inputpreamblelisting{A}
+
+\begin{dispExample}
+\begin{pabox}[label={myautocounter}]{Title with number}
+This box is automatically numbered with \ref{myautocounter} on page
+\pageref{myautocounter}. Inside the box, the \thetcbcounter\ can
+also be referenced by |\thetcbcounter|.
+The real counter name is \texttt{\tcbcounter}.
+\end{pabox}
+\end{dispExample}
+\end{newTcbKey}
+
+\clearpage
+\begin{newTcbKey}{use counter from}{=\meta{tcolorbox}}{no default, initially unset}
+Here, a counter from another \meta{tcolorbox} is reused.
+Note that the setting for \refKey{/tcb/new/number format} and
+\refKey{/tcb/new/number within} are inherited and cannot be changed.
+The counter value is referenced by \docAuxCommand{thetcbcounter}.
+
+\begin{dispExample}
+\newtcolorbox[use counter from=pabox]{mybox}[2][]{%
+colback=blue!5!white,colframe=blue!75!black,fonttitle=\bfseries,
+title=Some Box \thetcbcounter: #2,#1}
+
+\begin{mybox}[label={myusecounterfrom}]{Title with continued number}
+This box is automatically numbered with \ref{myusecounterfrom} on page
+\pageref{myusecounterfrom}. Inside the box, the \thetcbcounter\ can
+also be referenced by |\thetcbcounter|.
+The real counter name is \texttt{\tcbcounter}.
+\end{mybox}
+\end{dispExample}
+\end{newTcbKey}
+
+
+\begin{newTcbKey}{use counter}{=\meta{counter}}{no default, initially unset}
+Here, an ordinary existing \LaTeX\ counter is used for numbering.
+With \refKey{/tcb/new/number format} and
+\refKey{/tcb/new/number within}, the appearance and behavior of the counter
+can be changed. The counter value is referenced by \docAuxCommand{thetcbcounter}.
+
+\begin{dispExample}
+% \newcounter{myexample}% preamble
+\newtcolorbox[use counter=myexample,number format=\Alph]{mybox}[2][]{%
+colback=green!5!white,colframe=green!55!black,fonttitle=\bfseries,
+title=Some Box \thetcbcounter: #2,#1}
+
+\begin{mybox}[label={myusecounter}]{Title with \LaTeX\ number}
+This box is automatically numbered with \ref{myusecounter} on page
+\pageref{myusecounter}. Inside the box, the \thetcbcounter\ can
+also be referenced by |\thetcbcounter|.
+The real counter name is \texttt{\tcbcounter}.
+\end{mybox}
+\end{dispExample}
+\end{newTcbKey}
+
+
+\begin{newTcbKey}{no counter}{}{no value, initially set}
+The created boxes are not numbered. This is the default. The option may
+be used to overrule a previous option.
+\end{newTcbKey}
+
+\clearpage
+\begin{newTcbKey}{number within}{=\meta{counter}}{no default, initially unset}
+The automatic counter is set to zero, if \meta{counter} is increased.
+Additionally, during output, the value of \meta{counter} is prepended to the value of
+the automatic counter.\par
+To prepend the automatic counter with the chapter number and to reset it
+with every new chapter, use:
+\begin{dispListing}
+number within=chapter
+\end{dispListing}
+See \refKey{/tcb/new/use counter} for a complete example.
+\end{newTcbKey}
+
+
+\begin{newTcbKey}{number format}{=\meta{format macro}}{no default, initially \texttt{\textbackslash arabic}}
+Declares the format of the automatic counter. The \meta{format macro} can be
+any valid \LaTeX\ number formatting macro like |\arabic|, |\roman|, etc.\par
+To display the counter value in large roman numbers, use:
+\begin{dispListing}
+number format=\Roman
+\end{dispListing}
+See \refKey{/tcb/new/auto counter} for a complete example.
+\end{newTcbKey}
+
+
+\begin{newTcbKey}{number freestyle}{=\meta{code}}{no default, initially unset}
+Allows advanced control over the complete number format. This option overrules
+the format given by \refKey{/tcb/new/number within} and \refKey{/tcb/new/number format}.
+Nevertheless, you can combine it with \refKey{/tcb/new/number within} to
+get the desired reset property.\par
+The \meta{code} is some formatting code which should contain |\tcbcounter| to
+reference the automated counter. Since this \meta{code} is expanded, you have
+to secure each macro with |\noexpand| with \emph{exception} of |\tcbcounter|.
+
+\inputpreamblelisting{H}
+
+\begin{dispExample}
+\begin{phbox}[label={myfreestyle}]{Title with freestyle number}
+This box is automatically numbered with \ref{myfreestyle} on page
+\pageref{myfreestyle}. Inside the box, the \thetcbcounter\ can
+also be referenced by |\thetcbcounter|.
+The real counter name is \texttt{\tcbcounter}.
+\end{phbox}
+\end{dispExample}
+\end{newTcbKey}
+
+
+\clearpage
+\subsection{Lists of \texttt{tcolorbox}es}\label{sec:listsof}
+For figures and tables, \LaTeX\ provides the |\listoffigures| and
+|\listoftables| commands to create lists of these numbered entities.
+Also, a |tcolorbox| can be part of such a kind of list.
+\begin{enumerate}
+\item Assign a list \meta{name} by the \emph{initialization} option
+ \refKey{/tcb/new/list inside}.
+\item Optionally, a new \meta{type} for list entries may be assigned
+ by the \emph{initialization} option \refKey{/tcb/new/list type}.
+\item List entries a generated automatically within each new |tcolorbox|
+ using the above initialization.
+ \begin{itemize}
+ \item If \refKey{/tcb/list entry} is set, the entry is generated with it.
+ \item Otherwise, if \refKey{/tcb/title} is set, the entry is generated with it.
+ \item Otherwise, the entry is generated with the current number and the environment name.
+ \end{itemize}
+\item The generated list is displayed by \refCom{tcblistof}.
+\end{enumerate}
+
+\begin{newTcbKey}{list inside}{=\meta{name}}{no default, initially unset}
+Assigns a list or contents file to the generated |tcolorbox|es.
+Entries to this list are saved to a file which gets the \meta{name} as
+file name extension. The list is references by this name in
+\refCom{tcblistof}.
+For example:
+\begin{dispListing}
+list inside=exam
+\end{dispListing}
+See Section \ref{listing:exercises} from page \pageref{listing:exercises}
+for a complete example.
+\end{newTcbKey}
+
+
+\begin{newTcbKey}{list type}{=\meta{type}}{no default, initially |tcolorbox|}
+Optionally, some \meta{type} can be assigned to the list entries.
+For a new \meta{type}, a macro |\l@|\meta{type} has to exist which controls
+the format of the list entry. The default type is defined by
+\begin{dispListing}
+\newcommand*\l@tcolorbox{\@dottedtocline{1}{1.5em}{2.3em}}
+\end{dispListing}
+This is identical to the |\l@section| setting of \LaTeX. |\l@tcolorbox| can
+be redefined or a new \meta{type} can be assigned.
+\end{newTcbKey}
+
+
+\begin{docCommand}{tcblistof}{\oarg{macro}\marg{name}\marg{title text}}
+Displays the generated list of |tcolorbox|es with the given \meta{name}.
+The heading is generated by \meta{macro}\marg{title text} where \texttt{\textbackslash section}
+is the default setting for \meta{macro}.\par
+To display the list inside a subsection, use for example:
+\begin{dispListing}
+\tcblistof[\subsection]{exam}{List of Exercises}
+\end{dispListing}
+The result of the example is found as Subsection \ref{listofexercises} on
+page \pageref{listofexercises}.
+\begin{marker}
+The core of the list is generated by |\@starttoc|\marg{name} which
+can be wrapped into an own macro.
+\end{marker}
+\end{docCommand}
+
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.intro.tex b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.intro.tex
index c6330c6a44a..d009fce353d 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.intro.tex
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.intro.tex
@@ -44,12 +44,13 @@ and there is nothing special to do for a user.
If you intend to make a local
installation \emph{by hand}, see the |README| file of the |tcolorbox| package
for some hints. The short story is: you have to install not only
-|tcolorbox.sty| but also all |*.code.tex| files in the local |texmf| tree.
+|tcolorbox.sty|, but also all |*.code.tex| files in the local |texmf| tree.
\subsection{Loading the Package}
The base package |tcolorbox| loads the packages
|pgf| \cite{tantau:2010c}, |verbatim| \cite{schoepf:2001a},
+|etoolbox| \cite{lehmann:2011a},
and |environ| \cite{robertson:2013a}.
|tcolorbox| itself is loaded in the usual manner in the preamble:
\begin{dispListing}
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.listings.tex b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.listings.tex
index 317ad7e5166..6bbac3e8cb5 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.listings.tex
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.listings.tex
@@ -98,7 +98,7 @@ This \textbf{text} is written to a standardized file for later usage.
\clearpage
-\begin{docCommand}{newtcblisting}{\marg{name}\oarg{number}\oarg{default}\marg{options}}
+\begin{docCommand}{newtcblisting}{\oarg{init options}\marg{name}\oarg{number}\oarg{default}\marg{options}}
Creates a new environment \meta{name} based on \refEnv{tcblisting}.
Basically, |\newtcblisting| operates like |\newenvironment|. This means,
the new environment \meta{name} optionally takes \meta{number} arguments, where
@@ -106,6 +106,8 @@ This \textbf{text} is written to a standardized file for later usage.
The \meta{options} are given to the underlying |tcblisting|.
Note that \refKey{/tcb/savedelimiter} is set to the given \meta{name}
automatically.
+ The \meta{init options} allow to set up automatic numbering,
+ see Section \ref{sec:initkeys} from page \pageref{sec:initkeys}.
\begin{dispExample*}{sbs,lefthand ratio=0.5}
\newtcblisting{mybox}{%
colback=red!5!white,
@@ -146,13 +148,76 @@ This is my \LaTeX\ box.
This is my
\LaTeX\ box.
\end{mybox}
+\end{dispExample*}
+
+\inputpreamblelisting{C}
+\begin{dispExample*}{sbs,lefthand ratio=0.5}
+\begin{mycbox}{Listing Box}
+This is my \LaTeX\ box.
+\end{mycbox}
\end{dispExample*}
+
\end{docCommand}
\clearpage
+\begin{docCommand}{newtcbinputlisting}{\oarg{init options}\marg{\texttt{\textbackslash}name}\oarg{number}\oarg{default}\marg{options}}
+ Creates a new macro \meta{\texttt{\textbackslash}name} based on \refCom{tcbinputlisting}.
+ Basically, |\newtcbinputlisting| operates like |\newcommand|.
+ The new macro \meta{\texttt{\textbackslash}name} optionally takes \meta{number}$+1$ arguments, where
+ \meta{default} is the default value for the optional first argument.
+ The \meta{options} are given to the underlying |tcbinputlisting|.
+ The \meta{init options} allow to set up automatic numbering,
+ see Section \ref{sec:initkeys} from page \pageref{sec:initkeys}.
+
+\begin{dispExample}
+\newtcbinputlisting[use counter from=mycbox]{\mylisting}[2][]{%
+ listing file={#2},
+ title=Listing (\thetcbcounter) of \texttt{#2},
+ colback=red!5!white,colframe=red!75!black,fonttitle=\bfseries,
+ listing only,breakable,#1}
+
+\mylisting[before upper=\textit{This is the included file content:}]
+ {\jobname.tcbtemp}
+\end{dispExample}
+
+% \begin{dispExample*}{sbs,lefthand ratio=0.6}
+% \newtcbinputlisting{\mybox}{colback=red!5!white,
+ % colframe=red!75!black}
+%
+% \mybox{This is my own box.}
+% \end{dispExample*}
+%
+% \begin{dispExample*}{sbs,lefthand ratio=0.6}
+% \newtcbinputlisting{\mybox}[1]{colback=red!5!white,
+ % colframe=red!75!black,fonttitle=\bfseries,
+ % title=#1}
+%
+% \mybox{Hello there}{This is my own box.}
+% \end{dispExample*}
+%
+% \begin{dispExample*}{sbs,lefthand ratio=0.6}
+% \newtcbinputlisting{\mybox}[2][]{colback=red!5!white,
+ % colframe=red!75!black,fonttitle=\bfseries,
+ % title=#2,#1}
+%
+% \mybox[colback=yellow]{Hello there}%
+ % {This is my own box.}
+% \end{dispExample*}
+%
+% \inputpreamblelisting{B}
+%
+% \begin{dispExample*}{sbs,lefthand ratio=0.6}
+% \pbbox[colback=yellow]{Hello there}%
+ % {This is my own box.}
+% \end{dispExample*}
+
+\end{docCommand}
+
+
+\clearpage
\subsection{Option Keys of the Library}
For the \meta{options} in \refEnv{tcblisting} respectively \refCom{tcbinputlisting}
the following |pgf| keys can be applied. The key tree path |/tcb/| is not to
@@ -360,23 +425,17 @@ The following source code gives a guideline for the creation of \LaTeX\ tutorial
In the next section, a framework for \LaTeX\ exercises is described.
All examples shall be numbered optionally.
-Firstly, some additional |tcb| keys are defined for the appearance and automatic
-numbering.
+Firstly, some additional |tcb| keys are defined for the appearance.
+For the examples, three environments |texexp|, |texexptitled|,
+and |texexptitledspec| are defined with automatic numbering.
-\begin{dispListing}
-%\newcounter{texexp} % preamble
-
-\tcbset{
- texexp/.style={colframe=red!50!yellow!50!black, colback=red!50!yellow!5!white,
- coltitle=red!50!yellow!3!white,
- fonttitle=\small\sffamily\bfseries, fontupper=\small, fontlower=\small},
- example/.style 2 args={texexp,
- step and label={texexp}{#2},
- title={Example \thetexexp: #1}},
-}
-\end{dispListing}
-\tcbusetemp
+\begin{itemize}
+\item |texexp| is used for untitled examles,
+\item |texexptitled| is used for titled examles,
+\item |texexptitledspec| is used for titled examles with special treatment.
+\end{itemize}
+\inputpreamblelisting{D}
\begin{dispExample}
\begin{tcblisting}{texexp}
@@ -387,27 +446,11 @@ and in compiled form.
\begin{dispExample}
-\begin{tcblisting}{example={Direct application of \texttt{example}}{firstExample}}
+\begin{texexptitled}{First example with a title line}{firstExample}
Here, we use Example \ref{firstExample} with a title line.
-\end{tcblisting}
+\end{texexptitled}
\end{dispExample}
-For the next examples, two environments
-|texexp| and |texexptitled|
-are defined for abbreviation.
-
-\begin{dispListing}
-\newtcblisting{texexp}[1]{texexp,#1}
-
-\newtcblisting{texexptitled}[3][]{example={#2}{#3},#1}
-\end{dispListing}
-\tcbusetemp
-
-For special cases, |tcolorbox| with the key
-|texexp| can be used instead of these two environments.
-
-Now, we have a flexible box for \LaTeX\ examples which is demonstrated in
-the following.
\begin{dispExample}
\begin{texexp}{}
@@ -472,15 +515,15 @@ on page \pageref{heading3}.
\begin{dispExample}
-\begin{tcolorbox}[example={Direct application of the style |texexp|}{texexpbox1}]
+\begin{texexptitledspec}{Special application}{texexpbox1}
\begin{lstlisting}[style=tcblatex]
Some \LaTeX\ source code.
\end{lstlisting}
\tcblower
-For special cases, the environment |tcolorbox| with style
+For special cases, the environment |texexptitledspec| with style
|example| can be used directly. As one can see, the upper and the lower
part of the box can be used uncoupled also.
-\end{tcolorbox}
+\end{texexptitledspec}
\end{dispExample}
@@ -584,7 +627,7 @@ processing. The solution contents themselves are saved to a subdirectory named
\newwrite\solout
\def\openoutsol{\immediate\openout\solout\jobname.sol}
\def\solfile#1{solutions/texercise#1.tex}
-\def\writesol#1{\immediate\write\solout{\noexpand\processsol{\thetexercise}{#1}}}%
+\def\writesol#1{\immediate\write\solout{\noexpand\processsol{\thetcbcounter}{#1}}}%
\def\closeoutsol{\immediate\closeout\solout}
\def\inputsol{\IfFileExists{\jobname.sol}{\input{\jobname.sol}}{}}
\end{dispListing}
@@ -622,6 +665,8 @@ and the label |sol:|\meta{marker} is used to mark the solution.
With these preparations, the kernel environment |texercise| for our
exercises is created quickly:
+\inputpreamblelisting{E}
+
\begin{dispListing}
\newtcolorbox{texercise}[2][]{texercisestyle,
listing file={\solfile\thetexercise},
@@ -629,7 +674,7 @@ exercises is created quickly:
title={Exercise \arabic{texercise}%
\hfill\mdseries Solution on page \pageref{sol:#2}},#1}
\end{dispListing}
-\tcbusetemp
+%\tcbusetemp
The following examples demonstrate the application.
\openoutsol
@@ -727,10 +772,19 @@ total line width.\par\smallskip
\tcbusetemplisting\par\smallskip\tcbusetemp%
\end{texercise}
\end{dispExample}
+\closeoutsol
+\bigskip
+Now, we give a list of all exercises with:
-\closeoutsol
+\begin{dispListing}
+\tcblistof[\subsection]{exam}{List of Exercises%
+ \label{listofexercises}}
+\end{dispListing}
+\tcbusetemp
+
+\clearpage
\subsection{Solutions for the given \LaTeX\ Exercises}
For all solutions, a macro |\processsol| was written to the file |\jobname.sol|.
@@ -742,7 +796,7 @@ Now, we need a definition for this macro to use the solutions.
\tcbinputlisting{texercisestyle,listing only,
phantom={\phantomsection\label{sol:#2}},%
title={Solution for Exercise \ref{exe:#2} on page \pageref{exe:#2}},
- listing file={\solfile#1}}}
+ listing file={\solfile{#1}}}}
\end{dispListing}
\tcbusetemp
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.theorems.tex b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.theorems.tex
index 236d3eb4ff3..8766b6d1eff 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.theorems.tex
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.theorems.tex
@@ -10,32 +10,69 @@ This also loads the package |amsmath|.
\subsection{Macros of the Library}
-\begin{docCommand}{tcbmaketheorem}{\marg{name}\marg{display name}\marg{options}\marg{counter}\marg{prefix}}
+
+\begin{docCommand}{newtcbtheorem}{\oarg{init options}\marg{name}\marg{display name}\marg{options}\marg{prefix}}
Creates a new environment \meta{name} based on |tcolorbox| to frame a
(mathematical) theorem. The \meta{display name} is used in the title line
with a number, e.\,g. \mbox{\flqq Theorem 5.1\frqq}.
The \meta{options} are given to the underlying |tcolorbox| to control
the appearance.
- The \meta{counter} is used for automatic numbering.
+ %The \meta{counter} is used for automatic numbering.
+ The \meta{init options} allow to set up automatic numbering,
+ see Section \ref{sec:initkeys} from page \pageref{sec:initkeys}.\par
The new environment \meta{name} takes one optional and two mandatory
parameters. The optional parameter supplements the options and should be
used only in rare cases.
The first mandatory parameter is the title text for the theorem and
the second mandatory parameter is a \meta{marker}. The theorem is
automatically labeled with \meta{prefix}|:|\meta{marker}.
+
+\enlargethispage*{20mm}
+\inputpreamblelisting{F}
+\begin{dispExample}
+\begin{mytheo}{This is my title}{theoexample}
+ This is the text of the theorem. The counter is automatically assigned and,
+ in this example, prefixed with the section number. This theorem is numbered with
+ \ref{th:theoexample} and is given on page \pageref{th:theoexample}.
+\end{mytheo}
+\end{dispExample}
+
\begin{dispExample}
-\tcbmaketheorem{theo}{My Theorem}{colback=green!5,colframe=green!35!black,
- fonttitle=\bfseries}{texercise}{th}
-
-\begin{theo}{This is my title}{theoexample}
- This is the text of the theorem. As can be seen, the counter \texttt{texercise}
- is reused. The theorem is numbered with \ref{th:theoexample} and is
- given on page \pageref{th:theoexample}.
-\end{theo}
+\begin{mytheo}[label=myownlabel]{This is my title}{}
+ The label parameter can be left empty without \LaTeX\ error.
+ Or you may use an own label to reference Theorem \ref{myownlabel}.
+\end{mytheo}
+\end{dispExample}
+
+\begin{dispExample}
+\begin{mytheo}{}{}
+ The title can also be left empty without problem. Note that the ':'
+ vanished magically.
+\end{mytheo}
\end{dispExample}
\end{docCommand}
+\clearpage
+\begin{deprecated}
+\begin{docCommand}{tcbmaketheorem}{\oarg{init options}\marg{name}\marg{display name}\marg{options}\marg{counter}\marg{prefix}}
+ Creates a new environment \meta{name} based on |tcolorbox| to frame a
+ (mathematical) theorem. The \meta{display name} is used in the title line
+ with a number, e.\,g. \mbox{\flqq Theorem 5.1\frqq}.
+ The \meta{options} are given to the underlying |tcolorbox| to control
+ the appearance.
+ The \meta{counter} is used for automatic numbering.
+ The \meta{init options} allow to set up automatic numbering,
+ see Section \ref{sec:initkeys} from page \pageref{sec:initkeys}.\par
+ The new environment \meta{name} takes one optional and two mandatory
+ parameters. The optional parameter supplements the options and should be
+ used only in rare cases.
+ The first mandatory parameter is the title text for the theorem and
+ the second mandatory parameter is a \meta{marker}. The theorem is
+ automatically labeled with \meta{prefix}|:|\meta{marker}.
+\end{docCommand}
+\end{deprecated}
+
\begin{docCommand}{tcboxmath}{\oarg{options}\marg{mathematical box content}}
Creates a \refEnv{tcolorbox} which is fitted to the width of the given
\meta{mathematical box content}. This box is intended to be applied as
@@ -54,6 +91,7 @@ This also loads the package |amsmath|.
\end{docCommand}
\clearpage
+
\begin{docCommand}{tcbhighmath}{\oarg{options}\marg{mathematical box content}}
This is a special case of the \refCom{tcboxmath} macro which uses
the style \refKey{/tcb/highlight math}.
@@ -63,7 +101,7 @@ This also loads the package |amsmath|.
\begin{dispExample}
\tcbset{myformula/.style={colback=yellow!10!white,colframe=red!50!black,
- highlight math style={reset,colback=LightBlue!50!white,colframe=Navy}}}
+ highlight math style={colback=LightBlue!50!white,colframe=Navy}}}
\begin{align}
\tcbhighmath{\sum\limits_{n=1}^{\infty} \frac{1}{n}} &= \infty.\\
@@ -330,31 +368,13 @@ the colored boxes. It is assumed that theorems and corollaries should be
identically colored.
All following environments are numbered with a common counter, but this
can be changed easily. Here, the counter output is supplemented by
-the section number.
+the subsection number.
-\begin{dispListing}
-%\newcounter{mytheorem}[section] % preamble
-\def\themytheorem{\thesection.\arabic{mytheorem}}
-
-\tcbset{
- defstyle/.style={fonttitle=\bfseries\upshape, fontupper=\slshape,
- arc=0mm, colback=blue!5!white,colframe=blue!75!black},
- theostyle/.style={fonttitle=\bfseries\upshape, fontupper=\slshape,
- colback=red!10!white,colframe=red!75!black},
-}
-\end{dispListing}
-\tcbusetemp
+\inputpreamblelisting{G}
-By \refCom{tcbmaketheorem}, commonly numbered theorem environments are
+By \refCom{newtcbtheorem}, commonly numbered theorem environments are
created now. |defstyle| and |theostyle| are used for the appearance.
-\begin{dispListing}
-\tcbmaketheorem{Definition}{Definition}{defstyle}{mytheorem}{def}
-\tcbmaketheorem{Theorem}{Theorem}{theostyle}{mytheorem}{theo}
-\tcbmaketheorem{Corollary}{Corollary}{theostyle}{mytheorem}{cor}
-\end{dispListing}
-\tcbusetemp
-
Now, everything is prepared for the following examples.
\begin{dispExample}
@@ -414,12 +434,13 @@ referenced with the marker \texttt{cor:nullstellen}.\bigskip
\begin{dispExample}
% \tcbuselibrary{skins}
-\tcbmaketheorem{YetAnotherTheorem}{Theorem}{enhanced,frame hidden,
+\newtcbtheorem[use counter from=Definition]{YetAnotherTheorem}{Theorem}%
+ {enhanced,frame hidden,
boxrule=2mm,titlerule=0mm,toptitle=1mm,bottomtitle=1mm,
fonttitle=\bfseries\large,fontupper=\normalsize,
coltitle=green!35!black,colbacktitle=green!15!white,
colback=green!50!yellow!15!white,borderline={1pt}{0pt}{green!25!blue},
- }{mytheorem}{theo}
+ }{theo}
\begin{YetAnotherTheorem}{Mittelwertsatz f\"{u}r $n$ Variable}{mittelwertsatz_n}%
Es sei $n\in\mathbb{N}$, $D\subseteq\mathbb{R}^n$ eine offene Menge und
@@ -434,14 +455,15 @@ referenced with the marker \texttt{cor:nullstellen}.\bigskip
\begin{dispExample}
% \tcbuselibrary{skins}
-\tcbmaketheorem{YetAnotherTheorem}{Theorem}{enhanced,arc=0mm,outer arc=0mm,
+\newtcbtheorem[use counter from=Definition]{YetAnotherTheorem}{Theorem}%
+ {enhanced,arc=0mm,outer arc=0mm,
boxrule=0mm,toprule=1mm,bottomrule=1mm,left=1mm,right=1mm,
titlerule=0mm,toptitle=0mm,bottomtitle=1mm,top=0mm,
colframe=red!50!black,colback=red!5!white,coltitle=red!50!black,
title style={top color=yellow!50!white,bottom color=red!5!white,
middle color=yellow!50!white},
fonttitle=\bfseries\sffamily\normalsize,fontupper=\normalsize\itshape,
- }{mytheorem}{theo}
+ }{theo}
\begin{YetAnotherTheorem}{Mittelwertsatz f\"{u}r $n$ Variable}{mittelwertsatz_n}%
Es sei $n\in\mathbb{N}$, $D\subseteq\mathbb{R}^n$ eine offene Menge und
@@ -470,5 +492,30 @@ You need more attention for your theorems? Here, you are \ldots
\end{Theorem}
\end{dispExample}
+\clearpage
+Using \refCom{newtcbtheorem} is a convenient way to generate a new
+theorem type. On the other hand, it enforces to use a titled |tcolorbox|.
+If you prefer to have an embedded title, you may create a new theorem
+type with the more flexible \refCom{newtcolorbox} macro:
+\begin{dispExample}
+% \tcbuselibrary{skins}
+\newtcolorbox[use counter from=Definition]{YetAnotherTheorem}[3][%
+ enhanced,colframe=blue!50!black,colback=yellow!20!white,
+ drop fuzzy shadow=blue!50!black!50!white,boxrule=0.4pt,
+ fontupper=\itshape]{%
+ before upper={\textcolor{red!50!black}{\upshape\bfseries
+ Theorem~\thetcbcounter\ (#2)}\quad},
+ list entry={\numberline{\thetcbcounter}#2},%
+ label={theo:#3},#1}
+
+\begin{YetAnotherTheorem}{Mittelwertsatz f\"{u}r $n$ Variable}{mittelwertsatz_n}%
+ Es sei $n\in\mathbb{N}$, $D\subseteq\mathbb{R}^n$ eine offene Menge und
+ $f\in C^{1}(D,\mathbb{R})$. Dann gibt es auf jeder Strecke
+ $[x_0,x]\subset D$ einen Punkt $\xi\in[x_0,x]$, so dass gilt
+ \begin{equation*}
+ f(x)-f(x_0) = \operatorname{grad} f(\xi)^{\top}(x-x_0)
+ \end{equation*}
+\end{YetAnotherTheorem}
+\end{dispExample}
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.pdf b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.pdf
index bbe315426a3..f57d4b89109 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.pdf
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.tex b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.tex
index cd0f87a6665..94e5b372b2c 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.tex
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.tex
@@ -1,5 +1,5 @@
% \LaTeX-Main\
-%% The LaTeX package tcolorbox - version 2.33 (2013/07/04)
+%% The LaTeX package tcolorbox - version 2.40 (2013/07/15)
%% tcolorbox.tex: Manual
%%
%% -------------------------------------------------------------------------------------------
@@ -67,6 +67,7 @@
\tcbmakedocSubKey{docTcbKey}{tcb}
\tcbmakedocSubKey{langTcbKey}{tcb/doclang}
+\tcbmakedocSubKey{newTcbKey}{tcb/new}
\makeatletter
\def\index@Skin#1{\index{#1\idx@actual\texttt{#1} Skin}\index{Skins\idx@level#1\idx@actual\texttt{#1}}}
@@ -78,8 +79,8 @@
\newtcolorbox{marker}[1][]{marker,#1}
-\def\version{2.33}%
-\def\datum{2013/07/04}%
+\def\version{2.40}%
+\def\datum{2013/07/15}%
\makeindex
\hypersetup{
@@ -93,6 +94,8 @@
\newcounter{texercise}
\newcounter{mytheorem}[section]
+\newcounter{myexample}
+
\newcounter{example}
\newlength{\examlen}
@@ -108,11 +111,11 @@
endtcolorbox,endtcbverbatimwrite,newtcolorbox,newtcbox,newtcboxfit,tcbusetemp,
tcblower,tcbox,tcboxfit,tcbset,tcbuselibrary,tcolorbox,tcbverbatimwrite,
% listings
- endtcblisting,newtcblisting,
+ endtcblisting,newtcblisting,newtcbinputlisting,
tcblisting,tcbinputlisting,tcbuselistingtext,tcbuselistinglisting,tcbusetemplisting,
tcbfitdim,tcbfitsteps,
% theorems
- tcbmaketheorem,tcboxmath,tcbhighmath,
+ tcbmaketheorem,tcboxmath,tcbhighmath,thetcbcounter,newtcbtheorem,
% documentation
brackets,
colDef,colOpt,cs,
@@ -131,14 +134,14 @@
morekeywords={% core
adjusted,adjust,after,arc,auto,autoparskip,align,
before,bottom,boxsep,boxrule,bottomtitle,bottomrule,broken,basedim,
- collower,coltext,coltitle,colback,colframe,colupper,center,code,capture,check,
- equal,enlarge,enlargement,extrude,
- fontupper,fontlower,fonttitle,first,floatplacement,float,fit,fontsize,flushleft,flushright,
+ collower,coltext,coltitle,colback,colframe,colupper,center,code,capture,check,counter,
+ equal,enlarge,enlargement,extrude,every,box,higher,layers,
+ fontupper,fontlower,fonttitle,first,floatplacement,float,fit,fontsize,flushleft,flushright,freestyle,format,
group,gap,
height,
lowerbox,left,leftrule,lefttitle,leftupper,leftlower,lower,last,lefthand,label,
middle,minimum,maxstep,macros,
- notitle,natural,noparskip,nobeforeafter,nofloat,
+ notitle,natural,noparskip,nobeforeafter,nofloat,number,
parskip,parbox,phantom,page,
outer,oversize,overlay,odd,
right,rightrule,righttitle,rightupper,rightlower,righthand,ratio,
@@ -146,7 +149,7 @@
title,top,toptitle,toprule,titlerule,tabularx,tikz,toggle,tight,tempfile,text,
upper,unbroken,
valign,
- width,
+ width,within,
% listings
comment,
file,
@@ -207,14 +210,111 @@
sbs/.style={sidebyside,before lower app={\tcbset{sidebyside=false}}},%
innerbox/.style={reset,documentation listing style=mydocumentation,docexample/.style={docexample original},
},
- docexample/.style={colframe=Navy!50!ExampleFrame,colback=Navy!5!ExampleBack,fontlower=\footnotesize,
- bicolor,colbacklower=ExampleBack!5!white,drop fuzzy shadow,%,
- before upper={\tcbset{innerbox}},before lower={\tcbset{innerbox}}},
+ base example/.style={enhanced,colframe=Navy!50!ExampleFrame,colback=Navy!5!ExampleBack,fontlower=\footnotesize,
+ bicolor,colbacklower=ExampleBack!5!white,drop fuzzy shadow},
+ docexample/.style={base example,%
+ every box on layer 2/.style={every box},
+ before upper={\tcbset{innerbox}},before lower={\tcbset{innerbox}}
+ },
docexample original/.style={colframe=ExampleFrame,colback=ExampleBack,fontlower=\footnotesize,frame style={}},
}
-%\includeonly{tcolorbox.doc.coreoptions}
+\newcommand{\inputpreamblelisting}[1]{%
+ \tcbinputlisting{title=Definition in the preamble:,
+ base example,coltitle=black,fonttitle=\itshape,titlerule=0pt,
+ colbacktitle=Navy!15!ExampleBack,
+ top=0mm,
+ before=\par\smallskip,%
+ listing style=mydocumentation,
+ listing only,listing file={\jobname_preamble_#1.tex}}%
+}
+
+\newtcolorbox{deprecated}{blank,breakable,watermark text=deprecated}
+
+%\tcbset{every box/.style={enhanced}}
+
+\begin{tcbverbatimwrite}{\jobname_preamble_A.tex}
+\newtcolorbox[auto counter,number within=section]{pabox}[2][]{%
+ colback=red!5!white,colframe=red!75!black,fonttitle=\bfseries,
+ title=Examp.~\thetcbcounter: #2,#1}
+\end{tcbverbatimwrite}
+\input{\jobname_preamble_A.tex}
+
+\begin{tcbverbatimwrite}{\jobname_preamble_B.tex}
+% counter from previous example
+\newtcbox[use counter from=pabox]{\pbbox}[2][]{%
+ colback=red!5!white,colframe=red!75!black,fonttitle=\bfseries,
+ title=(\thetcbcounter) #2,#1}
+\end{tcbverbatimwrite}
+\input{\jobname_preamble_B.tex}
+
+\begin{tcbverbatimwrite}{\jobname_preamble_C.tex}
+\newtcblisting[auto counter]{mycbox}[1]{%
+ colback=red!5!white,colframe=red!75!black,fonttitle=\bfseries,
+ title=Listing \thetcbcounter: #1}
+\end{tcbverbatimwrite}
+\input{\jobname_preamble_C.tex}
+
+\begin{tcbverbatimwrite}{\jobname_preamble_D.tex}
+\tcbset{
+ texexp/.style={colframe=red!50!yellow!50!black, colback=red!50!yellow!5!white,
+ coltitle=red!50!yellow!3!white,
+ fonttitle=\small\sffamily\bfseries, fontupper=\small, fontlower=\small},
+ example/.style 2 args={texexp,
+ title={Example \thetcbcounter: #1},label={#2}},
+}
+
+\newtcblisting{texexp}[1]{texexp,#1}
+\newtcblisting[auto counter,number within=section]{texexptitled}[3][]{%
+ example={#2}{#3},#1}
+\newtcolorbox[use counter from=texexptitled]{texexptitledspec}[3][]{%
+ example={#2}{#3},#1}
+\end{tcbverbatimwrite}
+\input{\jobname_preamble_D.tex}
+
+\begin{tcbverbatimwrite}{\jobname_preamble_E.tex}
+\newtcolorbox[auto counter,number within=section,list inside=exam]%
+ {texercise}[2][]{texercisestyle,
+ listing file={\solfile\thetcbcounter},label={exe:#2},
+ phantom={\writesol{#2}},
+ title={Exercise \thetcbcounter\hfill\mdseries Solution on page \pageref{sol:#2}},
+ list entry={\numberline{\thetcbcounter}Exercise with solution on
+ page \pageref{sol:#2}},#1}
+\end{tcbverbatimwrite}
+\input{\jobname_preamble_E.tex}
+
+\begin{tcbverbatimwrite}{\jobname_preamble_F.tex}
+\newtcbtheorem[number within=section]{mytheo}{My Theorem}%
+ {colback=green!5,colframe=green!35!black,fonttitle=\bfseries}{th}
+\end{tcbverbatimwrite}
+\input{\jobname_preamble_F.tex}
+
+
+\begin{tcbverbatimwrite}{\jobname_preamble_G.tex}
+\tcbset{
+ defstyle/.style={fonttitle=\bfseries\upshape, fontupper=\slshape,
+ arc=0mm, colback=blue!5!white,colframe=blue!75!black},
+ theostyle/.style={fonttitle=\bfseries\upshape, fontupper=\slshape,
+ colback=red!10!white,colframe=red!75!black},
+}
+\newtcbtheorem[number within=subsection]{Definition}{Definition}{defstyle}{def}
+\newtcbtheorem[use counter from=Definition]{Theorem}{Theorem}{theostyle}{theo}
+\newtcbtheorem[use counter from=Definition]{Corollary}{Corollary}{theostyle}{cor}
+\end{tcbverbatimwrite}
+\input{\jobname_preamble_G.tex}
+
+
+\begin{tcbverbatimwrite}{\jobname_preamble_H.tex}
+\newtcolorbox[auto counter,number within=section,
+ number freestyle={(Q/\noexpand\thesection/\noexpand\Alph{\tcbcounter})},
+ ]{phbox}[2][]{%
+ colback=yellow!15!white,colframe=blue!75!black,fonttitle=\bfseries,
+ title=Question~\thetcbcounter: #2,#1}
+\end{tcbverbatimwrite}
+\input{\jobname_preamble_H.tex}
+
+%\includeonly{tcolorbox.doc.abstract,tcolorbox.doc.coreoptions}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -224,6 +324,7 @@
\include{tcolorbox.doc.intro}
\include{tcolorbox.doc.coremacros}
\include{tcolorbox.doc.coreoptions}
+\include{tcolorbox.doc.initoptions}
\include{tcolorbox.doc.verbatim}
\include{tcolorbox.doc.skins}
\include{tcolorbox.doc.listings}