Hi Doug,
I made a bit of a pointer mess there. Not the best of answers or way to go
about iterating through a list. Looking at some GTK code, this is better done
with a for loop. As usual, you don't want to move the pointer you get from
gtk_text_iter_get_tags() and then free it. This will cause you grief later on
along with buggy code that may not be so easy to debug.
Very glad you got things working well even with a less than good answer. Need
to be careful of the pointers myself.
Eric
GSList *tlist=NULL;
GSList *p=NULL;
tlist=gtk_text_iter_get_tags(&start);
g_print("List %p p %p\n", tlist, p);
for(p=tlist;p;p=p->next)
{
gchar *string=NULL;
g_object_get(G_OBJECT(p->data), "name", &string, NULL);
g_print("p %p %s\n", p, string);
g_free(string);
}
g_print("List %p\n", tlist);
if(tlist!=NULL) g_slist_free(tlist);
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list