diff options
Diffstat (limited to 'Master/texmf-dist')
-rw-r--r-- | Master/texmf-dist/doc/latex/sparklines/sparklines.pdf | bin | 55608 -> 58998 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/latex/sparklines/sparklines.tex | 16 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/sparklines/sparklines.sty | 17 |
3 files changed, 22 insertions, 11 deletions
diff --git a/Master/texmf-dist/doc/latex/sparklines/sparklines.pdf b/Master/texmf-dist/doc/latex/sparklines/sparklines.pdf Binary files differindex f0cacec5eea..92df9977a8d 100644 --- a/Master/texmf-dist/doc/latex/sparklines/sparklines.pdf +++ b/Master/texmf-dist/doc/latex/sparklines/sparklines.pdf diff --git a/Master/texmf-dist/doc/latex/sparklines/sparklines.tex b/Master/texmf-dist/doc/latex/sparklines/sparklines.tex index 29f357960e1..04bf93b76bc 100644 --- a/Master/texmf-dist/doc/latex/sparklines/sparklines.tex +++ b/Master/texmf-dist/doc/latex/sparklines/sparklines.tex @@ -6,7 +6,7 @@ \let\env=\texttt \let\pkg=\textsf -\definecolor{sparkrectanglecolor}{rgb}{0.8,.95,0.8} +\definecolor{sparkrectanglecolor}{rgb}{0.8,0.95,0.8} \definecolor{sparkspikecolor}{rgb}{1,0,0} \setlength{\sparkdotwidth}{1.3pt} \setlength{\sparklinethickness}{.3pt} @@ -15,7 +15,7 @@ \title{Sparklines} \author{Andreas Loeffler \and Dan Luecking} -\date{updated 3.~April 2007}\maketitle +\date{updated 20.~April 2009}\maketitle \section{What are sparklines?} @@ -44,10 +44,10 @@ This is an example of sparkline: % This environment has now an own coordinate system. x and y run from 0 to 1. % % This draws a sparkling-rectangle with lower level y=0.3 and upper -% level y=0.5 -\sparkrectangle 0.3 0.5 +% level y=0.8 +\sparkrectangle 0.3 0.8 % -% This draws a blue colored sparkling-dot at x=0.5, y=0.8 +% This draws a blue colored sparkling-dot at x=0.5, y=0.62 \sparkdot 0.5 0.62 blue % % This draws a red colored sparkling-dot at x=1, y=0.2 @@ -67,7 +67,7 @@ The sparkline at the end of the previous section was created with the following: \begin{verbatim} \begin{sparkline}{10} - \sparkrectangle 0.3 0.5 + \sparkrectangle 0.3 0.8 \sparkdot 0.5 0.62 blue \sparkdot 1 0.2 red \spark 0.1 0.95 0.2 0.8 0.3 0.3 0.4 0.52 0.5 0.62 @@ -148,6 +148,10 @@ user may change (with \verb$\setlength$). The default is \texttt{2pt}. \section*{Version history} \begin{description} +\item[] Apr 20, 2009 + + version 1.4: Alexander Kowalski (Alexander.Kowarik@statistik.gv.at) found an error concerning spark-rectangles + \item[] Mar 21, 2007 version 1.3: User adjustable colors and parameters added by Dan diff --git a/Master/texmf-dist/tex/latex/sparklines/sparklines.sty b/Master/texmf-dist/tex/latex/sparklines/sparklines.sty index e81202b098c..33eff2183a1 100644 --- a/Master/texmf-dist/tex/latex/sparklines/sparklines.sty +++ b/Master/texmf-dist/tex/latex/sparklines/sparklines.sty @@ -1,4 +1,4 @@ -%%% sparklines.sty Version 1.3 +%%% sparklines.sty Version 1.4 %%% %%% What Are Sparklines? %%% Sparklines are intense, simple, wordlike graphics (so named by Edward Tufte). @@ -6,7 +6,7 @@ %%% release of a chapter on sparklines, see www.edwardtufte.com. A PHP %%% implementation can be found at http://sparkline.sourceforge.net/. %%% -%%% Copyright 2005 Andreas Loeffler +%%% Copyright 2009 Andreas Loeffler %%% ======================================================================== %%% LICENCE: %%% This file may be distributed under the terms of the LaTeX Project Public @@ -16,6 +16,8 @@ %%% al@wacc.de %%% %%% MODIFICATION HISTORY: +%%% Apr 20, 2009 +%%% version 1.4: Alexander Kowalski (Alexander.Kowarik@statistik.gv.at) found an error concerning spark-rectangles %%% Mar 21, 2007 %%% version 1.3: Dan Luecking (luecking@uark.edu) added user-changeable %%% parameters, and expanded documentation @@ -27,7 +29,8 @@ %%% version 1.0: first version of sparklines \ProvidesPackage{sparklines} - [2005/01/01 v1.3 Sparklines (see more on sparklines at www.EdwardTufte.com)] + [2007/04/20 v1.4 Sparklines (see more on sparklines at www.EdwardTufte.com)] + \typeout {Package: `sparklines' 1.4 \space 2007/04/20} \RequirePackage{pgf} % We define the colors of two features: the background rectangle and @@ -67,8 +70,12 @@ % defines sparkrectangle % Replace hard-coded rgb value with with previously defined color value. \def\sparkrectangle #1 #2 {% - {\pgfmoveto{\pgforigin}\color{sparkrectanglecolor} - \pgfrect[fill]{\pgfxy(0, #1)}{\pgfxy(1, #2)}}} + \ifdim #1pt > #2pt + \errmessage{The upper corner #2 of rectangle cannot be lower than #1}% + \fi + {\pgfmoveto{\pgforigin}\color{sparkrectanglecolor}% + \pgfrect[fill]{\pgfxy(0, #1)}{\pgfxy(1, #2-#1)}}}% + % defines sparkline-plot % Replace \@shouldIstop hack with equivalent \@ifnextchar code. |