Extracted from Pike v7.3 release 14 at 2002-02-15.
pike.roxen.com
[Top]
GTK
GTK.Widget

Method GTK.Widget()->selection_add_target()


Method selection_add_target

object(GTK.Widget) GTK.Widget()->selection_add_target(object(GDK.Atom)|void selection, object(GDK.Atom)|void target, int|void info)

Description

Supplying the selection is a bit more complicated than requesting it. You must register handlers that will be called when your selection is requested. For each selection/target pair you will handle, you make a call to this function.

selection, and target identify the requests this handler will manage. When a request for a selection is received, the "selection_get" signal will be called. info can be used as an enumerator to identify the specific target within the callback function.

Selection defaults to PRIMARY, and target defaults to STRING.