summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/bchart
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2012-03-17 23:10:28 +0000
committerKarl Berry <karl@freefriends.org>2012-03-17 23:10:28 +0000
commit63d3000c4b397c52ad8017366f49f98a07f6a795 (patch)
treebe7e866586aa7c98b0cda08084d826470359f1af /Master/texmf-dist/tex/latex/bchart
parentb85e85862ea9263c2a0ed994368016498e31d3eb (diff)
bchart (17mar12)
git-svn-id: svn://tug.org/texlive/trunk@25677 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/bchart')
-rw-r--r--Master/texmf-dist/tex/latex/bchart/bchart.sty9
1 files changed, 6 insertions, 3 deletions
diff --git a/Master/texmf-dist/tex/latex/bchart/bchart.sty b/Master/texmf-dist/tex/latex/bchart/bchart.sty
index 36851c4763f..212d4feac4e 100644
--- a/Master/texmf-dist/tex/latex/bchart/bchart.sty
+++ b/Master/texmf-dist/tex/latex/bchart/bchart.sty
@@ -1,8 +1,8 @@
%-------------------------------------------------------------------------------
% bchart (LaTeX package)
%-------------------------------------------------------------------------------
-% Version: 0.1.0
-% Date: 22 November 2011
+% Version: 0.1.1
+% Date: 16 March 2012
% Author: Tobias Kuhn
%-------------------------------------------------------------------------------
@@ -45,11 +45,13 @@
\newcommand{\bcbarcolor}{}
\newcommand{\bcbartext}{}
\newcommand{\bcbarlabel}{}
+\newcommand{\bcbarvalue}{}
\newcommand{\bcplainbar}{}
\makeatletter
\define@key{bcbar}{color}{\renewcommand{\bcbarcolor}{#1}}
\define@key{bcbar}{text}{\renewcommand{\bcbartext}{#1}}
\define@key{bcbar}{label}{\renewcommand{\bcbarlabel}{#1}}
+\define@key{bcbar}{value}{\renewcommand{\bcbarvalue}{#1}}
\define@key{bcbar}{plain}[false]{\renewcommand{\bcplainbar}{true}}
\makeatother
@@ -71,6 +73,7 @@
\renewcommand{\bcbarcolor}{blue!20}
\renewcommand{\bcbartext}{}
\renewcommand{\bcbarlabel}{}
+ \renewcommand{\bcbarvalue}{##2\bcunit}
\renewcommand{\bcplainbar}{false}
% Read parameters:
\setkeys{bcbar}{##1}
@@ -79,7 +82,7 @@
\draw (0,\bcpos) rectangle ($##2-\bcmin*(\bcwidth/\bcrange,0) + (0,\bcpos-5mm)$);
\ifthenelse{\equal{\bcplainbar}{true}}{}{
% Write value:
- \node[anchor=west] at ($##2-\bcmin*(\bcwidth/\bcrange,0) + (0,\bcpos-2.5mm)$) {\sf ##2\bcunit};
+ \node[anchor=west] at ($##2-\bcmin*(\bcwidth/\bcrange,0) + (0,\bcpos-2.5mm)$) {\sf \bcbarvalue};
}
% Write text:
\node[anchor=west] at (0,\bcpos-2.5mm) {\sf \bcbartext};