[pstricks] Bluring self-created High Level Object
Herbert Voss
LaTeX at zedat.fu-berlin.de
Fri Jun 22 18:12:15 CEST 2007
martin at wudika.de wrote:
> Hello together,
>
> I don't know how to group a self-created object in a way such that I can
> apply different effects on it, e.g. to use blur shadowing.
> An example may explain my concerns. I want the entire "CPU" object to use
> shadowing or use a special outline. How would I attack this problem?
>
\documentclass{scrartcl}
\usepackage{pstricks}
\usepackage{multido}
\pagestyle{empty}
\makeatletter
\def\pstCPU{\pst at object{pstCPU}}
\def\pstCPU at i(#1)#2{{% #1: lower left #2: text
\psset{framearc=0.2,linecolor=gray,fillcolor=gray,fillstyle=solid}%
default
\begin at ClosedObj
\rput[lb](#1){%
\multirput[lb](0,0)(0,0.3){5}{\psline[linewidth=4pt](-0.1,0.2)(1.5,0.2)}
\psframe(1.4,1.6)
\rput(0.7,1.4){\footnotesize\bfseries\textsf{CPU#2}}}
\end at ClosedObj}%
\ignorespaces%
}
\makeatother
\begin{document}
\begin{pspicture}(0,0)(4,5)
\multido{\rA=0+2,\iB=0+1}{2}{\pstCPU[fillcolor=red!50](\rA,3.4){-\iB}}
\pstCPU[fillcolor=blue!10](0,0){-X}
\pstCPU[linecolor=black](3,0){-XX}
\end{pspicture}
\end{document}
Herbert
More information about the PSTricks
mailing list