$Date: 2005/10/23 10:57:04 $
$Revision: 1.4 $
-- Should Current not scale when drawed?
-- True means that the object will be drawed unscaled
-- but its position (reference_point) will still be transformed correctly
-- if drawed on a transformed scaled coordinate system
-- (This is handled accordingly by draw_object of EM_SURFACE)
-- (From EM_DRAWABLE)
-- Line color used to draw Current
-- Line width used to draw Current
-- Horizontal position, distance in pixels from left
-- (From EM_DRAWABLE)
-- Vertical position, distance in pixels from top
-- (From EM_DRAWABLE)
-- Set is_size_fixed to a_boolean.
-- (From EM_DRAWABLE)
-- Set x and y to x_position and y_position.
-- Moves all contained points accordingly.
-- (From EM_DRAWABLE)
-- Recalculate bounding_box (x, y, width, height)
-- to surround all points.
-- Draw rectangular part of Current defined by a_rect to a_surface.
-- (Subclasses could redefine this feature for providing an implementation
-- with better performance, otherwise its just done per default by
-- transforming and clipping coordinates on a_surface before calling draw).
-- (From EM_DRAWABLE)
-- Have events been initialized?
-- (From EM_DRAWABLE)
-- Event initialization.
-- Needs to be called before subscribing for events.
-- (From EM_DRAWABLE)
-- Mouse button down event,
-- gets published when the mouse button is pressed over Current,
-- an EM_MOUSEBUTTON_EVENT is passed as argument
-- (From EM_DRAWABLE)
-- Mouse button up event,
-- gets published when the mouse button is released over Current,
-- an EM_MOUSEBUTTON_EVENT is passed as argument
-- (From EM_DRAWABLE)
-- Mouse button up event,
-- gets published when the mouse button is released over Current,
-- an EM_MOUSEMOTION_EVENT is passed as argument
-- (From EM_DRAWABLE)
-- Publish mouse event when a_mouse_event occured on Current.
-- Descendants should redefine this feature
-- for only catching and publishing their mouse events when mouse pointer
-- is realy inside object or for
-- distributing mouse events to child objects.
-- (From EM_DRAWABLE)
-- Orthogonal rectangle surrounding Current; (i.e. usefull
-- for visibility testing if it intersects with
-- coordinate_area of EM_SURFACE) TODO: We create a new
-- one on each call. Maybe there is a more efficient way to
-- do that?
-- (From EM_DRAWABLE)
-- Height of Current defining its bounding_box (x, y, width, height).
-- (From EM_DRAWABLE)
-- Reference point of Current relative to which it should be positioned.
-- (i.e. important when drawn on a scaled coordinate system and is_size_fixed is True)
-- (From EM_DRAWABLE)
-- Width of Current defining its bounding_box (x, y, width, height).
-- (From EM_DRAWABLE)
Abstraction for drawable figures. Drawable figures have a line_width and a line_color in which they will be drawed.
A figure basicaly is defined through points (points) so is its position and size (x, y, width, height).
When the points are changed the position and size needs updating (update_bounding_box).
When the position of a figure is changed (set_x_y) all its points have to be moved accordingly.
To ensure updating of the bounding box, descendants have to call update_bounding_box whenever
something changes that influences the 'bounding_box' of the figure.