widget: Add draw signal
For now, the draw signal is emitted by default from the expose event, so widgets can chose to either implement the expose event or the draw function. This is for the transitional period from expose event to draw signal. Note that for now subclasses can only implement the draw function when none of their parents implemented the expose event.
This commit is contained in:
@ -348,6 +348,8 @@ struct _GtkWidgetClass
|
||||
gboolean was_grabbed);
|
||||
void (* child_notify) (GtkWidget *widget,
|
||||
GParamSpec *pspec);
|
||||
gboolean (* draw) (GtkWidget *widget,
|
||||
cairo_t *cr);
|
||||
|
||||
/* Mnemonics */
|
||||
gboolean (* mnemonic_activate) (GtkWidget *widget,
|
||||
@ -937,6 +939,9 @@ void gtk_widget_set_has_tooltip (GtkWidget *widget,
|
||||
gboolean has_tooltip);
|
||||
gboolean gtk_widget_get_has_tooltip (GtkWidget *widget);
|
||||
|
||||
gboolean gtk_cairo_should_draw_window (cairo_t *cr,
|
||||
GdkWindow *window);
|
||||
|
||||
GType gtk_requisition_get_type (void) G_GNUC_CONST;
|
||||
GtkRequisition *gtk_requisition_new (void) G_GNUC_MALLOC;
|
||||
GtkRequisition *gtk_requisition_copy (const GtkRequisition *requisition);
|
||||
|
||||
Reference in New Issue
Block a user