[Contents] [index] [Help] [Retrace] [browse <] [Browse >]

The IM_ERASE method tells an image to erase itself.  Applications should
not call this method directly, instead they should call the Intuition
function eraseimage().  the return value for this method is not explicitly
defined.

The IM_ERASE method uses a custom message structure:

    struct impErase
    {
        ULONG           MethodID;   /* IM_ERASE */
        struct RastPort *imp_RPort; /* The image's RastPort */
        struct
        {
            WORD X;                 /* X and Y offset relative */
            WORD Y;                 /* to the image's IA_Left  */
        } imp_Offset;               /* and IA_Top attributes.  */
    };

The imageclass dispatcher calls the graphics.library function eraserect()
to erase the image.  The imageclass dispatcher gets the position of the
image using the offsets from the IM_ERASE message and the dimensions it
finds in the object's image structure.  the imageclass dispatcher does not
do any bounds checking before calling EraseRect().