[reportlab-users] Anybody else hungry for Image shapes?
Robin Becker
reportlab-users@reportlab.com
Wed, 31 Jul 2002 16:59:04 +0100
In article <200207311227.g6VCRHci014083@ratthing-b246.strakt.com>, Laura
Creighton <lac@strakt.com> writes
>Since you aren't dependent on any rasterising, bitmaps and picmaps are
>a subset of the things you need a name for. If you forget, for a
>moment, the contents of the Image, are you left with what are usually
>called 'figures', 'diagrams' or 'plates' in books? When we were
>typesetting books, we called all of these things 'regions' and
>sometimes 'rectangular regions' -- or 'keeps' if the important thing
>to remember about the wretched thing was that you could not split them
>over a page. Some authors wanted their keep exactly where it followed
>logically in their argument -- and if that meant that one page was
>mostly blank, so be it. Others wanted the keep to show up 'the
>next time you have enough room for it' which was sometimes tricky.
>
>Laura Creighton
....
well the complete things could be called diagrams or pictures; we call
the top class Drawing. Underneath are Groups which are containers for
either primitives or other containers. Drawings have a size, Groups not.
Both can have a transformation applied to their contents. At the bottom
we have primitives called Shapes. Typical Shapes are Line, Rect, Path
etc.
These Image things are primitives constructed from external files (via
PIL). So while Line(0,0,10,10,strokeWidth=....) draws a line in the
current userspace Image(0,0,10,10,'bongo.gif') is supposed to draw the
contents of the gif file into the rectangle x,y,width,height=0,0,10,10
by appropriate transforms. If the local reference frame is itself skewed
etc then the transforms are composed.
--
Robin Becker