Re: getting text from an entry box
- From: Matt Hillebrand <hill9361 uidaho edu>
- To: Maher Awamy <muhri muhri net>
- Cc: Jeremy Savoy <jsavoy us ibm com>, <gtk-app-devel-list gnome org>
- Subject: Re: getting text from an entry box
- Date: Fri, 23 Mar 2001 14:47:15 -0800 (PST)
By the way, gtk_entry_get_text() is deprecated. I've actually run into
seg.faults because of it. Use gtk_editable_get_chars() instead.
Matthew P. Hillebrand
On 23 Mar 2001, Maher Awamy wrote:
you need to g_strdup() what you get before inserting it in the glist - dont
forget to g_free() it later when you dont need it anymore ... so
config_data = g_list_append (config_data,
g_strdup(gtk_entry_get_text(GTK_ENTRY(entry1))));
is what you should be doing.
Maher
On Fri, 23 Mar 2001 16:27:32 -0500, Jeremy Savoy said:
I have a gtk text entry box that I would like to use to get information
from a user in a gnome druid app. I am using the following:
config_data = g_list_append (config_data,
gtk_entry_get_text(GTK_ENTRY(entry1)));
to get the data from the entry box 'entry1' and put it into the GList
config_data. config_data also contains data from several combo boxes, but
when I print the contents of the list, no matter what order I inserted the
data from entry1, there is always a blank line in the place of data that
was entered. I'm pretty new to gtk/gnome programming so the problem may be
obvious but I'm at a loss here. Any ideas or suggestions??
Regards,
Jeremy Savoy
Linux Admin
IBM - Retail Store Solutions
919-301-5273
jsavoy us ibm com
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
--
http://www.muhri.net -- muhri muhri net
_______________________________________________
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]