Re: expose vs draw



On Wed, 16 Jul 2014 18:57:16 +0200
ax487 <ax487 gmx de> wrote:
Well, assume that drawing the widget requires a large amount of work
per pixel. If I knew the region that I need to repaint then I could
save myself a lot of time. If the context is clipped this would not
help much if I don't know the relevant region, would it?

From the documentation on the draw signal:

"The signal handler will get a cr with a clip region already set to the
widget's dirty region, i.e. to the area that needs repainting.
Complicated widgets that want to avoid redrawing themselves completely
can get the full extents of the clip region with
gdk_cairo_get_clip_rectangle(), or they can get a finer-grained
representation of the dirty region with
cairo_copy_clip_rectangle_list()."

Chris


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]