Portability | portable (depends on GHC) |
---|---|
Stability | provisional |
Maintainer | gtk2hs-users@lists.sourceforge.net |
- data IImageTool
- class GObjectClass o => IImageToolClass o
- iimageToolPixbufChanged :: IImageToolClass tool => tool -> Bool -> Maybe Rectangle -> IO ()
Details
IImageTool
is an interface that defines how ImageView
interacts with objects that acts as
tools. ImageView
delegates many of its most important tasks (such as drawing) to its tool which
carries out all the hard work. The ImageView
package comes with two tools; ImageToolDragger
and ImageToolSelector
, but by implementing your own tool it is possible to extend ImageView
to
do stuff its author (thats me) didn't imagine.
ImageView
uses ImageToolDragger
by default, as that tool is he most generally useful
one. However, it is trivial to make it use another tool.
Types
data IImageTool Source
class GObjectClass o => IImageToolClass o Source
Methods
:: IImageToolClass tool | |
=> tool | |
-> Bool |
|
-> Maybe Rectangle |
|
-> IO () |
Indiate to the tool that either a part of, or the whole pixbuf that the image view shows has changed. This method is called by the view whenever its pixbuf or its tool changes. That is, when any of the following methods are used:
-
imageViewSetPixbuf
If the resetFit
parameter is True
, it means that a new pixbuf has been loaded into the view. rect
is a rectangle in image space coordinates that indicates which rectangular region of the pixbufs
pixels that is modified. If rect is Nothing
, then all of the pixbuf has changed. See also
pixbufChanged
.