diff options
author | Karl Berry <karl@freefriends.org> | 2013-07-23 22:29:26 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2013-07-23 22:29:26 +0000 |
commit | 393d6ac7f30401efc47612d4f4322910f32fcee5 (patch) | |
tree | 2d181466a6ff19d1c4518e7d1e2853c453baf887 /Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.listings.tex | |
parent | f59ca1d9cbe7adbdacee09b1da37ca357965c0c9 (diff) |
tcolorbox (23jul13)
git-svn-id: svn://tug.org/texlive/trunk@31275 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.listings.tex')
-rw-r--r-- | Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.listings.tex | 30 |
1 files changed, 26 insertions, 4 deletions
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 6bbac3e8cb5..544afba872b 100644 --- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.listings.tex +++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.listings.tex @@ -48,6 +48,17 @@ and in compiled form. </project> \end{tcblisting} \end{dispExample} + +\begin{dispExample} +% This box is as wide as needed (listing only !!) +% \usetikzlibrary{skins} +\begin{tcblisting}{colback=green!5!white,colframe=green!50!black,listing only, + hbox,enhanced,drop fuzzy shadow,before=\begin{center},after=\end{center}} +\begin{tikzpicture} +\fill[red] (0,0) rectangle (1,1); +\end{tikzpicture} +\end{tcblisting} +\end{dispExample} \end{docEnvironment} @@ -64,6 +75,7 @@ This \textbf{text} is written to a standardized file for later usage. \end{docEnvironment} +\clearpage \begin{docCommand}{tcbinputlisting}{\marg{options}} Creates a colored boxed based on a |tcolorbox|. The text content is read from a file named by the key value of |listing file|. Apart from that, @@ -74,7 +86,6 @@ This \textbf{text} is written to a standardized file for later usage. \end{dispExample} \end{docCommand} -\clearpage \begin{docCommand}{tcbuselistingtext}{} Loads text from a file named by the key value of |listing file|. \begin{dispExample} @@ -163,10 +174,10 @@ This is my \LaTeX\ box. \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}. +\begin{docCommand}{newtcbinputlisting}{\oarg{init options}\brackets{\texttt{\textbackslash}\rmfamily\meta{name}}\oarg{number}\oarg{default}\marg{options}} + Creates a new macro \texttt{\textbackslash}\meta{name} based on \refCom{tcbinputlisting}. Basically, |\newtcbinputlisting| operates like |\newcommand|. - The new macro \meta{\texttt{\textbackslash}name} optionally takes \meta{number}$+1$ arguments, where + The new macro \texttt{\textbackslash}\meta{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, @@ -420,6 +431,17 @@ This is a \LaTeX\ example. \clearpage +\begin{docTcbKey}{listing remove caption}{\colOpt{=\meta{boolean value}}}{default |true|, initially |true|} +If set to |true|, some part of the caption building code of the |listings| package +is silenced to prevent some unwanted interaction with the |hyperref| package resulting +in additional vertical space. +If set to |false|, the |listings| package code is kept unchanged. +Note that listings outside \refEnv{tcblisting} and +\refCom{tcbinputlisting} are always processed normally. +Typically, a user is not expected to use this key at all. +\end{docTcbKey} + +\clearpage \subsection{Creation of \LaTeX\ Tutorials}\label{sec:latextutorial} The following source code gives a guideline for the creation of \LaTeX\ tutorials. In the next section, a framework for \LaTeX\ exercises is described. |