Re: How do expose_events work?
- From: JParker coinstar com
- To: Jeans <jeans ace ulyssis org>
- Cc: gtk-app-devel-list gnome org, gtk-app-devel-list-admin gnome org
- Subject: Re: How do expose_events work?
- Date: Tue, 31 Oct 2000 12:14:22 -0800
G'Day !
Have you looked at the scribble.c example from the tutorial. It is really well
documented .... and the source code would answer most of your questions. If you
still need help I can send you some code. Most of it is based on the scribble
code though, so it might not help too much.
cheers,
Jim Parker
Sailboat racing is not a matter of life and death .... It is far more important
than that !!!
Jeans
<jeans ace ulyssis org> To: gtk-app-devel-list gnome org
Sent by: cc:
gtk-app-devel-list-admin Subject: Re: How do expose_events work?
@gnome.org
10/31/00 12:08 PM
after doing that, did you do a gtk_signal_connect(GTK_OBJECT(yourdrawingarea),
"expose_event", somefunction, data) ??
Yes. I wish it was that simple...
static gint PGCanvasExposeEvent(GtkWidget *widget, GdkEventExpose *event,
gpointer data) {
printf("Canvas expose event\n");
return FALSE;
}
void PGCanvas::addToWindow(PGWindow* parent) {
// Create new drawing area
m_hWidget = (GtkWidget*)gtk_drawing_area_new();
gtk_drawing_area_size(GTK_DRAWING_AREA(m_hWidget), 300, 300);
// Connect signal handler
gtk_signal_connect(GTK_OBJECT(m_hWidget), "expose_event",
GTK_SIGNAL_FUNC(PGCanvasExposeEvent), (gpointer)this);
gtk_widget_set_events(m_hWidget, GDK_EXPOSURE_MASK);
// Add to layobox (my own container)
pg_gtk_layobox_append(GTK_CONTAINER(parent->m_hPGContainer),
m_hWidget);
...
}
It's probably something with the container I've written
pg_gtk_layobox. Is that possible? Anybody a pointer where
I can start debugging?
Jeans.
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]