[9484] in The GTK GIMP ToolKit mailing list archive

home help back first fref pref prev next nref lref last post

[gtk-list] Re: How can I syncronize two entries?

daemon@ATHENA.MIT.EDU (Johannes Keukelaar)
Thu Oct 22 05:37:30 1998

To: gtk-list@redhat.com
From: johannes@nada.kth.se (Johannes Keukelaar)
In-reply-to: Your message of "21 Oct 1998 11:46:31 +0200."
             <7uk91umemg.fsf@olivia.aibon.ping.de> 
Date: Thu, 22 Oct 1998 11:36:31 +0200
Resent-From: gtk-list@redhat.com
Reply-To: gtk-list@redhat.com

//Hi,

Hi,

//how can I syncronize two entries?  When I call gtk-entry-set-text for
//entry2 in the the callback for the "changed" signal of entry1 a
//"changed" signal for entry2 is emitted.  This emittes again the
//"changed" signal for entry1.  This goes for a while and in the end
//crashes Gtk.  Does a gtk-entry-set-text exist, that does not emmit a
//"changed" signal.  Or is it possible to stop the emmision of "changed"
//signals for a widget temporary?

Use strcmp (or your favorite scheme equivalent) to check if the strings in the 
two entries are different, and only call gtk-entry-set-text if they're actually 
different. By the way, shouldn't gtk-entry-set-text check if the new text is 
different, and only emit the changed signal if it's really different?

Just my two bits,

Johannes.
--
"FLASH!  Intelligence of mankind decreasing.  Details at ... uh, when
 the little hand is on the ...." -- Jarek Luberek

How do I connect to that real-life thing I keep hearing about?


-- 
To unsubscribe: mail -s unsubscribe gtk-list-request@redhat.com < /dev/null


home help back first fref pref prev next nref lref last post