Re: Missing drag'n'drop methods in GtkTreeView



On Wed, 13 Aug 2003 12:44:00 -0400 (EDT), muppet wrote:

[1] I'm not sure if I got the stack thingies (EXTEND, PUSHs) right.
    Please check it.

you did it right, but there's an easier way:

void gtk_tree_widget_to_tree_coords (GtkTreeView * tree_view, gint wx,
gint wy, OUTLIST gint tx, OUTLIST ty)

does what your hand-written XS does with a lot less typing.  this is
one of the nifty features new to xsubpp in 5.8.0...

Is it safe to assume that everyone has 5.8.0?

[2] I'm not sure if newSVGtkTreePath or _copy or _own should be used
    since I simply don't know the difference.

_copy should be used when returning an object that you are not allowed
to modify.  _own should be used when returning an object that you are
supposed to free.  if you use _copy where you should use _own, you get
a leak.  if you use_own where you should use nothing, then you destroy
something that's not yours.

i haven't looked yet into which one is correct where.

I see. I couldn't find any documentation or usage exmaples on
gtk_tree_view_get_drag_dest_row. So I've no idea what would be The Right
Thing here.

I failed implementing gtk_tree_view_get_search_equal_func due to a
"missing" entry in the typemap (GtkTreeViewSearchEqualFunc). I can't
tell whether it's /really/ missing or I simply did something wrong.

[...]

that sucks.  this is why the callback stuff is a bit of grey magic. 
(not black, because it is documented, but not white because there are
inevitably sticky issues like this.)

I didn't find documentation on returning function pointers and the only
other occurence of this thingy I found[1] is
 
  gtk_color_selection_set_change_palette_hook

which, coincidentally, is still unimplemented, too. :) All that to say
that I'm still at a loss at how to implement this.

Bye,
-Torsten

[1] grep -r '^[# ]*Gtk[a-zA-Z]*Func' gtk2-perl-xs/*



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]