FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

TreeModelT.get(TreeIter iter, ... ) doesn't seem to work.

 
Post new topic   Reply to topic     Forum Index -> gtkD
View previous topic :: View next topic  
Author Message
mwarning



Joined: 01 Apr 2007
Posts: 56

PostPosted: Tue Jul 15, 2008 6:36 pm    Post subject: TreeModelT.get(TreeIter iter, ... ) doesn't seem to work. Reply with quote

model and iter are both valid as far as I can tell.

Quote:
char[] data = new char[32]; //just for some testing
model.get(iter, 0, data.ptr, -1);


After this line, data is filled with null (empty).
I also tried column 1, same result.
Both columns contain strings (GType.STRING).
Adding a dummy null after iter in the argument list doesn't help.

There i also output on the console:

Code:

(gtk-gui:22311): Gtk-WARNING **: /tmp/buildd/gtk+2.0-2.12.9/gtk/gtktreemodel.c:1435: Invalid column number 135523188 accessed (remember to end your list of columns with a -1)
Back to top
View user's profile Send private message
Mike Wey



Joined: 07 May 2007
Posts: 428

PostPosted: Wed Jul 16, 2008 12:20 pm    Post subject: Reply with quote

Yes, functions with varargs are not wrapped correctly, see ticket #16.

You can use: TreeModelIF.getValueString(TreeIter iter, int column);
Back to top
View user's profile Send private message
mwarning



Joined: 01 Apr 2007
Posts: 56

PostPosted: Thu Jul 17, 2008 2:37 am    Post subject: Reply with quote

Quote:
TreeModelIF.getValueString(TreeIter iter, int column);


Works, thanks!
Back to top
View user's profile Send private message
eldar



Joined: 14 Jun 2008
Posts: 101
Location: Ufa, Russia

PostPosted: Tue Jul 22, 2008 7:47 am    Post subject: Reply with quote

mandel
I wanna ask you if you are implementing custom model? I didn't gain any success in it, I will appreciate any little help Smile
Back to top
View user's profile Send private message
mwarning



Joined: 01 Apr 2007
Posts: 56

PostPosted: Sun Jul 27, 2008 9:15 am    Post subject: Reply with quote

Code:
I wanna ask you if you are implementing custom model?


Not yet. Maybe some time in the future.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> gtkD All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group