[pstricks] colored background of labels
Herbert Voss
Herbert.Voss at FU-Berlin.DE
Mon Nov 3 09:50:03 CET 2014
Am 02.11.2014 um 19:59 schrieb Doris Behrendt:
> when I plot labels on an axis sometimes I want to have the labels with a colored background;
> is there an option to do this and also to change the color of the labels?
\documentclass{article}
\usepackage{pst-plot}
\makeatletter
\def\pst@@@hlabel#1{\colorbox{blue!30}{\textcolor{blue}{#1}}}
\def\pst@@@vlabel#1{\colorbox{red!30}{\textcolor{red}{#1}}}
\makeatother
\begin{document}
\begin{pspicture}(-0.1,-0.1)(5,5)
\psaxes{->}(0,0)(0,0)(4,4)
\end{pspicture}
\end{document}
Herbert
More information about the PSTricks
mailing list