Would it be possible to add a transparency option to the fill method? I
understand that postscript does not allow transparency but pdf does.
What I mean is that after a transparent fill the region below is
On 17.08.05, Mladen Bestvina wrote:
> Would it be possible to add a transparency option to the fill method? I
> understand that postscript does not allow transparency but pdf does.
> What I mean is that after a transparent fill the region below is
> partially visible.
Well, as far as I can see all we need to do is to modify the graphic
state, which contain several transparency features in PDF.
Unfortunately there are no PDF operators to modify those features
directly. Hence you need to create a ExtGState resource and use the gs
operator to set the feature. (The gs operator works on resources only,
you can't embed the graphic state dictionary directly into the content
Since the page need to know about the new resources to be written, we
have to overwrite it's output method. For the future we should change
that ... just make it a feature of the resource, that it knows whether
and how it needs to be inserted into a PDFpage output. (I do have
other things in mind -- about forms -- where we'll need that too.)
Still, it's not that worse as it sounds. You can do transparency as
demonstrated in the enclosed code ... ;-)
by _ _ _ Dr. André Wobst
/ \ \ / ) wobsta@..., http://www.wobsta.de/
/ _ \ \/\/ / PyX - High quality PostScript and PDF figures
(_/ \_)_/\_/ with Python & TeX: visit http://pyx.sourceforge.net/