summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.verbatim.tex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2017-07-06 21:27:18 +0000
committerKarl Berry <karl@freefriends.org>2017-07-06 21:27:18 +0000
commit4344c241bb6300f064703c309f98ea1fa550fc21 (patch)
treea0a4173ecfb412735cbcd4b5db7b960662249c15 /Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.verbatim.tex
parent57d4d64524ef6e9e6589a8f2744a981649606ea0 (diff)
tcolorbox (6jul17)
git-svn-id: svn://tug.org/texlive/trunk@44759 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.verbatim.tex')
-rw-r--r--Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.verbatim.tex60
1 files changed, 60 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.verbatim.tex b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.verbatim.tex
index 19770abfe04..de7d56aeb96 100644
--- a/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.verbatim.tex
+++ b/Master/texmf-dist/doc/latex/tcolorbox/tcolorbox.doc.verbatim.tex
@@ -55,3 +55,63 @@ Now, we are using the file:\par
\begin{docCommand}{tcbusetemp}{}
Loads the current temporary file which was saved by \refEnv{tcbwritetemp}.
\end{docCommand}
+
+\clearpage
+
+\begin{docTcbKey}[][doc new=2017-07-05]{verbatim ignore percent}{\colOpt{=true\textbar false}}{default |true|, initially |false|}
+ If this option is set to be |true|, the percent sign \% is silently
+ ignored for \refEnv{tcbverbatimwrite} and all macros and environments
+ which are built using \refEnv{tcbverbatimwrite}, e.g.\
+ \refEnv{tcbwritetemp}, \refEnv{tcblisting}, or \refEnv{dispExample}.\par
+ This option may be useful for creating some special effects, but mainly
+ it is intended to be applied for documentation with DocStrip.
+ The creation of this option was motivated by Yudai Nakata.
+ Note that this option is not getting reset by \refKey{/tcb/reset}.
+\begin{dispExample*}{sidebyside}
+Normal usage:
+\begin{tcbwritetemp}
+%\begin{center}\bfseries
+This is my text.
+%\end{center}
+\end{tcbwritetemp}
+
+\tcbusetemp
+
+\tcbset{verbatim ignore percent}
+\bigskip Option applied:
+\begin{tcbwritetemp}
+%\begin{center}\bfseries
+This is my text.
+%\end{center}
+\end{tcbwritetemp}
+
+\tcbusetemp
+\end{dispExample*}
+
+\begin{marker}
+Note that \emph{every} percent sign is removed, also escaped ones.
+\end{marker}
+
+\begin{dispExample*}{sidebyside}
+% \tcbuselibrary{listings}
+\def\percent{\%}
+
+\begin{tcblisting}{title=Normal}
+%\begin{center}\bfseries
+This is my 5\percent\ text
+and this is my 10\% text.
+%\end{center}
+\end{tcblisting}
+
+\begin{tcblisting}{
+ title=Option applied,
+ verbatim ignore percent}
+%\begin{center}\bfseries
+This is my 5\percent\ text
+and this is my 10\% text.
+%\end{center}
+\end{tcblisting}
+\end{dispExample*}
+
+\end{docTcbKey}
+