summaryrefslogtreecommitdiff
path: root/graphics/pgf/contrib/pgf-spectra/pgf-spectraManual_defs.tex
diff options
context:
space:
mode:
Diffstat (limited to 'graphics/pgf/contrib/pgf-spectra/pgf-spectraManual_defs.tex')
-rw-r--r--graphics/pgf/contrib/pgf-spectra/pgf-spectraManual_defs.tex154
1 files changed, 150 insertions, 4 deletions
diff --git a/graphics/pgf/contrib/pgf-spectra/pgf-spectraManual_defs.tex b/graphics/pgf/contrib/pgf-spectra/pgf-spectraManual_defs.tex
index 268fbee066..6d4a505280 100644
--- a/graphics/pgf/contrib/pgf-spectra/pgf-spectraManual_defs.tex
+++ b/graphics/pgf/contrib/pgf-spectra/pgf-spectraManual_defs.tex
@@ -3,6 +3,9 @@
% the code is not optimized, made by «chunks»
% to carry out the development of the package
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\setcounter{secnumdepth}{1}%
+\setcounter{tocdepth}{4}%
+%
\usepackage{makeidx}
\makeindex%
\usepackage{listings}
@@ -58,7 +61,23 @@
{\if@restonecol\onecolumn\else\clearpage\fi}%
\makeatother%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\def\pgfspectraMnewinversion#1{new in v#1}%
+\def\pgfspectraMchangedinversion#1{changed in v#1}%
\def\bs#1{\textcolor{blue!50!black}{\textbackslash#1}}%
+\def\lb{\textcolor{blue!50!black}{\{}}%
+\def\rb{\textcolor{blue!50!black}{\}}}%
+\def\lp{\textcolor{blue!50!black}{[}}%
+\def\rp{\textcolor{blue!50!black}{]}}%
+\def\pl{\textcolor{blue!50!black}{(}}%
+\def\pr{\textcolor{blue!50!black}{)}}%
+\def\cyan#1{\textcolor{cyan!50!black}{#1}}%
+\def\dcyan#1{\textcolor{cyan!30!black}{#1}}%
+\def\gray#1{\textcolor{black!50}{#1}}%
+\def\blue#1{\textcolor{blue!50!black}{#1}}%
+\def\lblue#1{\textcolor{blue!70!black}{#1}}%
+\def\green#1{\textcolor{green!50!black}{#1}}%
+\def\red#1{\textcolor{red!50!black}{#1}}%
+\def\orange#1{\textcolor{orange!80!black}{#1}}%
\def\txttikz{\textsf{Ti\textit{k}Z}}%
\def\txtPGFPLOTS{\textsf{\small PGFPLOTS}}%
\def\txtspec{\textcolor{blue!50!black}{\textbackslash pgfspectra}}%
@@ -74,6 +93,7 @@
\def\txtshadetikz#1#2#3{\texttt{\textbackslash tikz\{\textbackslash\string f{i}ll[#1] (#2) rectangle (#3);\}}}%
\def\txtnewline{\textbackslash\textbackslash\ }%
\def\txtplotshadename{\textcolor{blue!50!black}{\textbackslash pgfspectraplotshade}}%
+\def\txtcomname#1{\textcolor{blue!50!black}{\textbackslash#1}}%
\def\txtplotshade{\textcolor{blue!50!black}{\textbackslash pgfspectraplotshade[}\textcolor{red!50!black}{options}\textcolor{blue!50!black}{]\{}\textcolor{red!50!black}{name}\textcolor{blue!50!black}{\}}}%
\def\txtplotshadecom#1{\textcolor{blue!50!black}{\textbackslash pgfspectraplotshade\{}\textcolor{red!50!black}{#1}\textcolor{blue!50!black}{\}}}%
\def\txtplotshadecomoption[#1]#2{\textcolor{blue!50!black}{\textbackslash pgfspectraplotshade[}\textcolor{red!50!black}{#1}\textcolor{blue!50!black}{]\{}\textcolor{red!50!black}{#2}\textcolor{blue!50!black}{\}}}%
@@ -81,8 +101,8 @@
\def\txtplotmap{\textcolor{blue!50!black}{\textbackslash pgfspectraplotmap[}\textcolor{red!50!black}{<l|h>}\textcolor{blue!50!black}{]\{}\textcolor{red!50!black}{name}\textcolor{blue!50!black}{\}}}%
\def\txtplotmapcom#1{\textcolor{blue!50!black}{\textbackslash pgfspectraplotmap\{}\textcolor{red!50!black}{#1}\textcolor{blue!50!black}{\}}}%
\def\txtplotmapcomoption[#1]#2{\textcolor{blue!50!black}{\textbackslash pgfspectraplotmap[}\textcolor{red!50!black}{#1}\textcolor{blue!50!black}{]\{}\textcolor{red!50!black}{#2}\textcolor{blue!50!black}{\}}}%
-\def\txtrainbow{\textcolor{blue!50!black}{\textbackslash pgfspectrarainbow}\textcolor{red!50!black}{<[tikz options]><(rainbow options)>}\textcolor{blue!50!black}{\{}\textcolor{red!50!black}{radius}\textcolor{blue!50!black}{\}}}%
-\def\txtrainbowtitle{\textcolor{blue!50!black}{\textbackslash pgfspectrarainbow}\textcolor{red!50!black}{<[tikz options]><(rainbow\\ [2pt]\makebox[1.1em][s]{}options)>}\textcolor{blue!50!black}{\{}\textcolor{red!50!black}{radius}\textcolor{blue!50!black}{\}}}%
+\def\txtrainbow{\textcolor{blue!50!black}{\textbackslash pgfspectrarainbow}\textcolor{red!50!black}{\lp tikz options\rp\pl rainbow options\pr}\textcolor{blue!50!black}{\{}\textcolor{red!50!black}{radius}\textcolor{blue!50!black}{\}}}%
+\def\txtrainbowtitle{\textcolor{blue!50!black}{\textbackslash pgfspectrarainbow}\textcolor{red!50!black}{\lp tikz options\rp\pl rainbow\\ [2pt]\makebox[1.1em][s]{}options\pr}\textcolor{blue!50!black}{\{}\textcolor{red!50!black}{radius}\textcolor{blue!50!black}{\}}}%
\def\txtrainbowname{\textcolor{blue!50!black}{\textbackslash pgfspectrarainbow}}%2em
\def\txtrainbowcom#1{\textcolor{blue!50!black}{\textbackslash pgfspectrarainbow}\textcolor{blue!50!black}{\{}\textcolor{red!50!black}{#1}\textcolor{blue!50!black}{\}}}%
\def\txtrainbowcomoptions[#1](#2)#3{\textcolor{blue!50!black}{\textbackslash pgfspectrarainbow}\textcolor{red!50!black}{[#1](#2)}\textcolor{blue!50!black}{\{}\textcolor{red!50!black}{#3}\textcolor{blue!50!black}{\}}}%
@@ -141,6 +161,31 @@
\end{pgfonlayer}
\end{tikzpicture}%
}%
+\def\liboption#1#2#3{\index{OPTIONS@\textbf{OPTIONS}\addtoind!#1}% option,default,description
+% before skip in class 3.25ex plus -1ex minus -0.2ex after skip in class1.5ex plus 0.2ex ->
+\vskip-4.75ex\paragraph*{}\hspace{-1em}\addcontentsline{toc}{paragraph}{\texorpdfstring{$\rightsquigarrow$ #1}{#1}}%
+\begin{tikzpicture}%
+\node[below right,font=\small\bfseries] (a) at (0,0) {\hypertarget{optionlib:#1}{#1}};%
+\node[below left,font=\small] (b) at (\textwidth-.3333em,0) {default: \itshape#2};
+\node[below right,text=black!80,font=\small,text width=\textwidth-.6666em] (c) at (a.south west) {#3};
+\begin{pgfonlayer}{back}
+\path[left color=orange!20,right color=black!30!orange!50,rounded corners=2pt] (a.north west) rectangle (c.south east);
+\end{pgfonlayer}
+\end{tikzpicture}%
+}%
+\def\liboptionmultiline#1#2#3{\index{OPTIONS@\textbf{OPTIONS}\addtoind!#1}% option,default,description
+% before skip in class 3.25ex plus -1ex minus -0.2ex after skip in class1.5ex plus 0.2ex ->
+\vskip-4.75ex\paragraph*{}\hspace{-1em}\addcontentsline{toc}{paragraph}{\texorpdfstring{$\rightsquigarrow$ #1}{#1}}%
+\begin{tikzpicture}%
+\node[below right,font=\small\bfseries] (a) at (0,0) {\hypertarget{optionlib:#1}{#1}};%
+\node[below left,font=\small] (b) at (.45\textwidth-.3333em,0) {default:\ };
+\node[below right,font=\small,align=center,text width=.55\linewidth-.6666em] (c) at (.45\textwidth,0) {\itshape#2};
+\node[below right,text=black!80,font=\small,text width=\textwidth-.9999em] (d) at ([xshift=-.45\textwidth+.3333em]c.south west) {#3};
+\begin{pgfonlayer}{back}
+\path[left color=orange!20,right color=black!30!orange!50,rounded corners=2pt] (a.north west) rectangle (d.south east);
+\end{pgfonlayer}
+\end{tikzpicture}%
+}%
\def\newoption#1#2#3{\index{OPTIONS@\textbf{OPTIONS}\addtoind!#1}% option,default,description
\vskip-4.75ex\vskip-18pt\ \subsection*{}\addcontentsline{toc}{subsection}{\texorpdfstring{$\rightsquigarrow$ #1}{#1}}%
\begin{tikzpicture}%
@@ -157,7 +202,18 @@
\begin{tikzpicture}%
\node[below right,font=\small\bfseries] (a) at (0,0) {\hypertarget{option:#1}{#1}};%
\node[below left,font=\small] (b) at (\textwidth-.3333em,0) {default: \itshape#2};
-\node[below right,text=black!80,font=\small,text width=\textwidth-.6666em] (c) at (a.south west) {#3\hfill\textit{\textcolor{blue}{(new in v\minorversion)}}};
+\node[below right,text=black!80,font=\small,text width=\textwidth-.6666em] (c) at (a.south west) {#3\hfill\textit{\textcolor{blue}{(new in v\inversion{2.1.0})}}};
+\begin{pgfonlayer}{back}
+\path[left color=orange!20,right color=black!30!orange!50,rounded corners=2pt] (a.north west) rectangle (c.south east);
+\end{pgfonlayer}
+\end{tikzpicture}%
+}%
+\def\libnewminoroption#1#2#3{\noindent\index{OPTIONS@\textbf{OPTIONS}\addtoind!#1}% option,default,description
+\vskip-4.75ex\paragraph*{}\hspace{-1em}\addcontentsline{toc}{paragraph}{\texorpdfstring{$\rightsquigarrow$ #1}{#1}}%
+\begin{tikzpicture}%
+\node[below right,font=\small\bfseries] (a) at (0,0) {\hypertarget{option:#1}{#1}};%
+\node[below left,font=\small] (b) at (\textwidth-.3333em,0) {default: \itshape#2};
+\node[below right,text=black!80,font=\small,text width=\textwidth-.6666em] (c) at (a.south west) {#3\hfill\textit{\textcolor{blue}{(new in v\inversion{2.1.0})}}};
\begin{pgfonlayer}{back}
\path[left color=orange!20,right color=black!30!orange!50,rounded corners=2pt] (a.north west) rectangle (c.south east);
\end{pgfonlayer}
@@ -168,7 +224,18 @@
\begin{tikzpicture}%
\node[below right,font=\small\bfseries] (a) at (0,0) {\hypertarget{option:#1}{#1}};%
\node[below left,font=\small] (b) at (\textwidth-.3333em,0) {default: \itshape#2};
-\node[below right,text=black!80,font=\small,text width=\textwidth-.6666em] (c) at (a.south west) {#3\hfill\mbox{\textit{\textcolor{blue}{(new in v\minorrevversion)}}}};
+\node[below right,text=black!80,font=\small,text width=\textwidth-.6666em] (c) at (a.south west) {#3\hfill\mbox{\textit{\textcolor{blue}{(new in v\inversion{2.1.1})}}}};
+\begin{pgfonlayer}{back}
+\path[left color=orange!20,right color=black!30!orange!50,rounded corners=2pt] (a.north west) rectangle (c.south east);
+\end{pgfonlayer}
+\end{tikzpicture}%
+}%
+\def\libnewminorrevoption#1#2#3{\index{OPTIONS@\textbf{OPTIONS}\addtoind!#1}% option,default,description
+\vskip-4.75ex\paragraph*{}\hspace{-1em}\addcontentsline{toc}{paragraph}{\texorpdfstring{$\rightsquigarrow$ #1}{#1}}%
+\begin{tikzpicture}%
+\node[below right,font=\small\bfseries] (a) at (0,0) {\hypertarget{option:#1}{#1}};%
+\node[below left,font=\small] (b) at (\textwidth-.3333em,0) {default: \itshape#2};
+\node[below right,text=black!80,font=\small,text width=\textwidth-.6666em] (c) at (a.south west) {#3\hfill\mbox{\textit{\textcolor{blue}{(new in v\inversion{2.1.1})}}}};
\begin{pgfonlayer}{back}
\path[left color=orange!20,right color=black!30!orange!50,rounded corners=2pt] (a.north west) rectangle (c.south east);
\end{pgfonlayer}
@@ -252,4 +319,83 @@
\node[text width=\wdbv+.55\boxinnersep] (values) at ([xshift=-1pt]default.north east) {\usebox4};
\end{tikzpicture}%
}%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% LIBRARIES
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%\pgfdeclarelayer{back}%
+%\pgfsetlayers{back,main}%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\makeatletter%
+\def\manualData{\pgfspectra@last@dataset}%
+\makeatother%
+\def\uselib#1{%
+\begin{tikzpicture}
+\node[rounded corners=2pt,font=\small\bfseries,text=white,fill=cyan!50!white,draw=cyan!50!black,inner sep=0pt,minimum height=14pt,text depth=0pt] (usage) at (0,0) { \raisebox{4.25pt}{\ USAGE:\ }\tikz{\node[fill=cyan!10!white,font=\fontseries{n}\small] {\ #1\mbox{\ }}}};
+\end{tikzpicture}
+}%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\def\pgfspectralib#1#2{\begingroup\renewcommand{\hrulefill}{\leavevmode\leaders\hrule height 1pt\hfill\kern0pt}%
+\renewcommand{\dotfill}{\leavevmode\cleaders\hbox to 1.0em{\hss --\hss }\hfill\kern0pt}%
+\setbox0=\hbox{\ pgf-spectra Library \red{\hypertarget{lib:#1}{#1}}\ }%
+\raisebox{.25\ht0}{\makebox[.1125\linewidth][s]{\color{cyan!50!black}\hrulefill}}%
+\hspace{-.1125\linewidth}\raisebox{.25\ht0+1.75pt}{\makebox[.1125\linewidth][s]{\color{cyan!70!black}\hrulefill}}%
+\usebox0%
+\raisebox{.25\ht0}{\makebox[.8875\linewidth-\wd0][s]{\color{cyan!50!black}\hrulefill}}%
+\hspace{-.8875\linewidth}\hspace{\wd0}\raisebox{.25\ht0+1.75pt}{\makebox[.8875\linewidth-\wd0][s]{\color{cyan!70!black}\hrulefill}}%
+\\ [12pt]\makebox[8pt][s]{}\uselib{\bs{usepgfspectralibrary}\lb\red{#1}\rb}%
+\\ [12pt]\makebox[\linewidth][s]{\color{cyan!50!black}\dotfill}%
+\\ [6pt]\makebox[8pt][s]{}\begin{minipage}{\linewidth-16pt}#2\end{minipage}%
+\\ [6pt]\makebox[\linewidth][s]{\color{cyan!70!black}\hrulefill}\hspace{-\linewidth}%
+\raisebox{1.75pt}{\makebox[\linewidth][s]{\color{cyan!50!black}\hrulefill}}\endgroup%
+}%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\def\pgfspectralibsubsubsection#1{%
+\tikz{\node[cyan!50!black,font=\large] (ding) at (0,0) {\ding{224} };%
+\node[fill=cyan!5!white,text width={\linewidth-14.68799pt-1em},below right] (txt) at ([yshift=1pt]ding.north east) {#1};%
+\draw[cyan!50!black] ([xshift={-14.68799pt-.3333em}]txt.north west) -- (txt.north east);%
+\draw[cyan!50!black] ([xshift={-14.68799pt-.3333em}]txt.south west) -- (txt.south east);%
+}}%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\makeatletter%
+\newread\tmpFILE%
+\newcount\tmpNlines%
+\newcount\thechar%
+\def\pgfspectraMloadfile{\@ifnextchar[{\pgfspectraM@loadfile}{\pgfspectraM@loadfile[]}}%
+\def\pgfspectraM@loadfile[#1]#2.#3\relax{%
+\tmpNlines=0%
+\edef\tmpFILEcontents{}%
+\edef\tmpTestRS{#1}\ifx\tmpTestRS\tmpFILEcontents\relax\edef\MAXLines{4}\else\edef\MAXLines{5}\fi%
+\immediate\openin\tmpFILE=#2.#3 %
+\@whilesw\unless\ifeof\tmpFILE\fi{%
+ \advance\tmpNlines by1\relax%
+ \begingroup\endlinechar=-1%
+ \global\readline\tmpFILE to\tmpFILEline%
+ \endgroup%
+ \ifnum\tmpNlines>\MAXLines\relax\thechar=0\edef\tmpa{}\edef\tmpb{\tmpFILEline}\ifx\tmpa\tmpb\relax\else%
+ \edef\thelinedata@tmp{}\edef\MAXLINECHARS{125}\expandafter\pgfspectra@formatline\tmpFILEline\relax\edef\tmpFILEline{\thelinedata@tmp}%
+ \fi\fi%
+ \edef\tmpb{\tmpFILEline}\ifx\tmpa\tmpb\relax\else%
+ \edef\tmpFILEcontents{\tmpFILEcontents\vskip0pt\vbox{\hsize=.9\textwidth\tmpFILEline}}\fi%
+}%
+\immediate\closeout\tmpFILE%
+\begin{tikzpicture}%
+\node[text width=\textwidth-2pt-.6666em,draw=black!10,fill=black!10,line width=2pt,rounded corners=2pt,inner ysep=4pt] (a) at (0,0) {The contents of \textbf{#2.#3}};%
+\node[below right,text width=\textwidth-2pt-.6666em,draw=black!10,line width=2pt,font=\scriptsize,rounded corners=2pt] at ([yshift=4pt]a.south west) %
+{\textsf{\tmpFILEcontents}};%
+\end{tikzpicture}%
+}%
+\def\pgfspectra@formatline#1#2\relax{%
+\edef\testa{}\edef\testb{#2}\edef\testc{#1}\edef\testd{+}\edef\testf{o}%
+\global\advance\thechar by1\relax%
+\ifx\testa\testb\relax\edef\thelinedata@tmp{\thelinedata@tmp#1}%
+\else%
+\ifx\testc\testd\relax\edef\MAXLINECHARS{126}\relax\fi%
+\if\testc\testf\relax\edef\spc{ }\else\edef\spc{}\relax\fi%
+\ifnum\thechar<\MAXLINECHARS\relax\edef\thelinedata@tmp{\thelinedata@tmp#1\spc}\else%
+\edef\thelinedata@tmp{\thelinedata@tmp\vskip0pt\hskip1.5em#1}\global\thechar=0\relax\fi%ifnum
+\expandafter\pgfspectra@formatline#2\relax%
+\fi%\ifx
+}%
+\makeatother%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\endinput%