- y coordinate of upper-left corner of rectangle to redraw.
- x coordinate of upper-left corner of rectangle to redraw.
- Width of region to draw.
- Height of region to draw.
Invalidates the rectangular area of widget defined by x, y, width and height by calling Gdk.Window.InvalidateRect on the widget's window and all its child windows. Once the main loop becomes idle (after the current batch of events has been processed, roughly), the window will receive Widget.ExposeEvent events for the union of all regions that have been invalidated.
Normally you would only use this method in widget implementations. You might also use it, or Gdk.Window.InvalidateRect directly, to schedule a redraw of a Gtk.DrawingArea or some portion thereof. Frequently you can just call Gdk.Window.InvalidateRect or Gdk.Window.InvalidateRegion instead of this method. Those methods will invalidate only a single window, instead of the widget and all its children.
The advantage of adding to the invalidated region compared to simply drawing immediately is efficiency; using an invalid region ensures that you only have to redraw one time.
If an immediate redraw is desired, a call to Gdk.Window.ProcessUpdates will force an immediate refresh of the drawable. This can be useful in situations where mouse activity requires immediate visible feedback on the widget.