Re: Retrieving data from a GtkList
- From: "Jean-Christophe Berthon" <Jean-Christophe Berthon cgey com>
- To: "Ramon Alberto Triay Espinosa" <rtriay avantel net>, "Gtk List" <gtk-list gnome org>
- Subject: Re: Retrieving data from a GtkList
- Date: Tue, 5 Mar 2002 18:07:51 +0100
Hello,
I'm not using the GtkList but the GtkCList, maybe there are similar
function. Here is anyway the function I'm using for it (N.B.: I'm looking
for all the selected fields as my CList can handle multiple selection):
GList *pxGList = NULL;
ast_short sLoop;
/* Get the list of all the selected row out of the CList */
pxGList = GTK_CLIST(lstMyList)->selection;
pxGList = g_list_first(pxGList);
sLoop = 0;
while (pxGList != NULL)
{
/* The arguments are CList, Row, Column, String | I guess you don't
need the column argument */
gtk_clist_get_text(GTK_CLIST(lstMyList), GPOINTER_TO_INT(pxGList->data),
0, &pcMyString);
pxGList = g_list_next(pxGList);
sLoop++;
}
Best regards,
---
Jean-Christophe Berthon
Cap Gemini -- Ernst & Young
France
Skill IS -- Image Quality
Email: Jean-Christophe Berthon cgey com
Tel: (+33) 561 31 6671
----- Original Message -----
From: "Ramon Alberto Triay Espinosa" <rtriay avantel net>
To: <gtk-list gnome org>
Sent: Sunday, March 03, 2002 6:11 PM
Subject: Retrieving data from a GtkList
> Hi...
> This time i found myself looking for a function to retrieve the text of
> a selected item i'm displaying in a GtkList but found none. Do i have to
> keep my string values (or any data i want to retrieve from the list) in
> a separate GList and then "mark" them with the same index used in the
> gtk_list_select_item function? I usually do stuff like that in Visual
> Basic since the MS bound controls are very unstable.
>
> SALUDOS!!!
> rtriay
> :)
>
>
> _______________________________________________
> gtk-list mailing list
> gtk-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtk-list
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]