hatching background

Christian Meesters <meesters@...624...>
writes:

is it somehow possible to have a hatch in parts of the background, which
would achieve something like this pseudo-parameter to axvspan
pylab.axvspan(2, 10, hatch='//')?

Do you mean something like this?

In [34]: phi=pi*array((0,.2,.4,.6,.8,1,-.8,-.6,-.4,-.2))

In [35]: fill(cos(phi), sin(phi))
Out[35]: [<matplotlib.patches.Polygon instance at 0x1894cda0>]

In [36]: a=gca()

In [37]: setp(getp(a,'frame'), hatch='//')
Out[37]: [None]

(For some reason I don't see the hatch pattern in Agg-based backends, in
current svn, but it is there in e.g. eps and pdf.)

···

--
Jouni K. Sepp�nen
http://www.iki.fi/jks