Re: Getting the string from a gtktext?
- From: Oliver Buecker <o buecker fz-juelich de>
- To: Antonio Martínez Álvarez <pascal eresmas net>
- Cc: gtk-devel <gtk-app-devel-list gnome org>
- Subject: Re: Getting the string from a gtktext?
- Date: Fri, 09 Nov 2001 08:18:16 +0100
Hi
you have to use the funktion:
gchar* gtk_editable_get_chars (GtkEditable *editable,
gint start_pos,
gint end_pos);
Here a short example for your problem:
int
print_cb (GtkText *text)
{
gchar *tmpstr;
tmpstr =
gtk_editable_get_chars (GTK_EDITABLE (text), 0,
gtk_text_get_length (GTK_TEXT (text)));
g_print ("%s\n", tmpstr);
}
--
Mit freundlichen Grüßen
Oliver Bücker
Forschungszentrum Juelich
52425 Juelich privat: Fritz-Erler-Ring 44
52457 Aldenhoven
Tel.: 0 24 61 / 61 6676
Fax: 0 24 61 / 61 6695 Tel.: 0 24 64 / 6418
e-mail: o buecker fz-juelich de
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]