On Sun, 2004-11-21 at 19:49 -0700, Neil Zanella wrote: > Hello, > > Can I also rely on the fact that if a GtkToggleButton is active then a > function call > to set its active state to TRUE is not going to trigger a signal. In > general, is it true > that signal handlers are invoked when properties are CHANGED BY A FUNCTION > OR USER ACTION, and not when a function causes the given property to remain > the same? > In particular, if a toggle button state is true, then setting it to > true via a function > does not generate a signal. Is this concept true for GTK signals in general? It depends entirely on the signal and property in question. For signals in GTK+ itself, generally yes (I don't know of a counter-example within libgdk/libgdk-pixbuf/libgtk offhand). Outside of GTK+ it depends entirely on the code given. GObject's "notify" signal, for example, is always emitted when set_property() is called (so "toggled" will only be fired when the "active" property has changed, whereas "notify::active" will be fired anytime someone calls 'g_object_set (button, "active", someval, NULL);' -- Peace, Jim Cape http://esco.mine.nu http://ignore-your.tv "If even one reporter had stood up during a pre-Iraq Bush press conference last year and shouted, `Bullshit!' it might have made a difference." -- Matt Taibbi, New York Press
Attachment:
signature.asc
Description: This is a digitally signed message part
_______________________________________________ gtk-list@xxxxxxxxx http://mail.gnome.org/mailman/listinfo/gtk-list