Gtk_primary_selection_client.Gtk_primary_selection_offer
Offer to transfer primary selection contents.
A wp_primary_selection_offer represents an offer to transfer the contents of the primary selection clipboard to the client. Similar to wl_data_offer, the offer also describes the mime types that the source will transferthat the data can be converted to and provides the mechanisms for transferring the data directly to the client.
type 'v t = ([ `Gtk_primary_selection_offer ], 'v, [ `Client ]) Wayland.Proxy.t
val destroy : [< `V1 ] t -> unit
Destroy the primary selection offer.
Destroy the primary selection offer.
val receive : [< `V1 ] t -> mime_type:string -> fd:Unix.file_descr -> unit
Request that the data is transferred.
To transfer the contents of the primary selection clipboard, the client issues this request and indicates the mime type that it wants to receive. The transfer happens through the passed file descriptor (typically created with the pipe system call). The source client writes the data in the mime type representation requested and then closes the file descriptor.
The receiving client reads from the read end of the pipe until EOF and closes its end, at which point the transfer is complete.
Note: Servers will always want to use v1
.
class virtual +'a v1 : object ... end
Handler for a proxy with version >= 1.