I'm implementing a custom path effect by inheriting from AbstractPathEffect
and implementing draw_path as instructed here
That link references RenderBase.draw_path
define the required interface. Unfortunately, I can't find anywhere in the
associated documentation that tells me what the transform argument really
I've also read the transforms tutorial
while that explains the pipeline and all the intermediate transformations,
it doesn't really settle what I have available to me in draw_path. It is
clear that I can use it to transform coordinates from data to something --
but I don't know what to.
For the big picture -- I am implementing a path effect to allow drawing
hatched lines similar to this
which I did years ago in Matlab. Years before that, I've also done this in
Java Graphics2D by implementing a custom stroke. (The Java approach is
more applicable to the path effect approach, but I can't point to that code
Anyway, I have things mostly working -- and I am using the transform to go
from data coordinates to something that looks orthogonal and reasonable
on-screen. So, for minimum functionality, it works. However, I want to
give the user the ability to control the length and spacing of the hatches
-- which is in a coordinate system after the transformation is applied.
So, in order to document this thing, I need to know what it is. Or, if
there is a way to get intermediate stages of the transformation pipeline,
that would work too.
As for the user interface -- it seems to make the most sense to specify the
hatch length and spacing in terms of something similar to a line width
(typically points) or a marker size. I'm new to Python and matplotlib --
what is the Pythonic unit a user would expect to specify this in (and how
do I achieve that with what is available in draw_path)?
-------------- next part --------------
An HTML attachment was scrubbed...