indexing description: "[ A one-color background. ]" date: "$Date$" revision: "$Revision$" class EM_COLOR_BACKGROUND inherit EM_BACKGROUND create make_from_color feature {NONE} -- Initialisation make_from_color (a_color: like color) is -- Initialise background with `a_color'. require a_color_not_void: a_color /= Void do color := a_color ensure color_set: color = a_color end feature -- Access color: EM_COLOR -- Background color feature -- Element change set_color (a_color: like color) is -- Set `color' to `a_color'. require a_color_not_void: a_color /= Void do color := a_color ensure color_set: color = a_color end feature -- Drawing draw_on (a_widget: EM_WIDGET) is -- Draw background on `a_widget'. do a_widget.surface.put_rectangle_filled (0, 0, a_widget.surface.width, a_widget.surface.height, color) end invariant color_not_void: color /= Void end