indexing
description: "A region is a rectangle, polygon, or ellipse (or a combination of two or more of these shapes) that can be filled, painted, inverted, framed, and used to perform hit testing."
status: "See notice at end of class."
date: "$Date$"
revision: "$Revision$"
class interface
WEL_REGION
create
make_empty
make_elliptic (left, top, right, bottom: INTEGER)
lefttoprightbottom
make_elliptic_indirect (rect: WEL_RECT)
rect
require
rect_not_void: rect /= void
make_polygon_alternate (points: ARRAY [INTEGER])
points
require
points_not_void: points /= void
points_count: points.count \\ 2 = 0
make_polygon_winding (points: ARRAY [INTEGER])
points
require
points_not_void: points /= void
points_count: points.count \\ 2 = 0
make_rect (left, top, right, bottom: INTEGER)
lefttoprightbottom
make_rect_indirect (rect: WEL_RECT)
rect
require
rect_not_void: rect /= void
make_by_pointer (a_pointer: POINTER)
itema_pointer
item
a_pointer
WEL_GDI_ANY
ensure WEL_ANY
item_set: item = a_pointer
shared: shared
feature
gdi_objects_count: INTEGER
WEL_GDI_ANY
item: POINTER
WEL_ANY
feature
is_equal (other: like Current): BOOLEAN
Currentother
require ANY
other_not_void: other /= void
ensure ANY
symmetric: Result implies other.is_equal (Current)
consistent: standard_is_equal (other) implies Result
feature
exists: BOOLEAN
item
WEL_ANY
ensure WEL_ANY
Result = (item /= default_pointer)
point_in (x, y: INTEGER): BOOLEAN
xy
require
exists: exists
rect_in (rect: WEL_RECT): BOOLEAN
rect
require
exists: exists
rect_not_void: rect /= void
shared: BOOLEAN
item
item
destroy_item
item
WEL_ANY
feature
set_shared
shared
WEL_ANY
ensure WEL_ANY
shared: shared
set_unshared
shared
WEL_ANY
ensure WEL_ANY
unshared: not shared
feature
set_item (an_item: POINTER)
iteman_item
WEL_ANY
ensure WEL_ANY
item_set: item = an_item
feature
delete
Current
WEL_REFERENCE_TRACKABLE
require WEL_REFERENCE_TRACKABLE
reference_not_tracked: not reference_tracked
ensure WEL_REFERENCE_TRACKABLE
destroyed: not shared implies not exists
dispose
Current
delete
WEL_REFERENCE_TRACKABLE
feature
to_integer: INTEGER
item
WEL_ANY
ensure WEL_ANY
Result = cwel_pointer_to_integer (item)
feature
combine (region: WEL_REGION; mode: INTEGER): WEL_REGION
regionmode
WEL_RGN_CONSTANTSmode
require
exists: exists
region_not_void: region /= void
region_exists: region.exists
ensure
result_not_void: Result /= void
offset (x_offset, y_offset: INTEGER)
x_offsety_offset
require
exists: exists
set_rect (left, top, right, bottom: INTEGER)
lefttoprightbottom
require
exists: exists
feature
reference_tracked: BOOLEAN
Current
WEL_REFERENCE_TRACKABLE
references_count: INTEGER
WEL_REFERENCE_TRACKABLE
feature
decrement_reference
delete
WEL_REFERENCE_TRACKABLE
require WEL_REFERENCE_TRACKABLE
exists: exists
tracking_references_started: reference_tracked
enable_reference_tracking
references_tracked
WEL_REFERENCE_TRACKABLE
require WEL_REFERENCE_TRACKABLE
exists: exists
tracking_reference_not_started: not reference_tracked
increment_reference
WEL_REFERENCE_TRACKABLE
require WEL_REFERENCE_TRACKABLE
exists: exists
tracking_references_started: reference_tracked
object_id: INTEGER
Current
WEL_REFERENCE_TRACKABLE
invariant
ANY
reflexive_equality: standard_is_equal (Current)
reflexive_conformance: conforms_to (Current)
end -- WEL_REGION