[Gtk-sharp-list] Howto use WaitForTargets

einKI.ml einKI.ml at gmx.net
Fri Jun 30 12:36:30 EDT 2006


Hi

I tried to get all targets the clipboard currently supports through the
WaitForTargets Method.

public bool WaitForTargets (Gdk.Atom targets, out int n_targets)

I am sursprised why it only takes a Gdk.Atom as parameter instead of a
Gdk.Atom[] like the function form the C-API (GdkAtom**).

When I use the function i get a native SIGSEV.

int targ=0;
Gdk.Atom atom = Gdk.Atom.Intern("",false); //Have to creeate a atom but
it works with none i tired
cl.WaitForTargets(atom,out targ);

The corresponding C-code works without any problems

GdkAtom *atoms;
gint targets;
gtk_clipboard_wait_for_targets(cp,&atoms,&targets);

But I am not looking forward to use DLLImport and make a .so library for
this single function.

thx
einKI



More information about the Gtk-sharp-list mailing list