Package: gdk

Function gdk:surface-set-input-region

Lambda List

gdk:surface-set-input-region (surface region)

Arguments

surface -- a gdk:surface object
region -- a cairo:region-t instance with the region of surface to be reactive

Details

Apply the region to the surface for the purpose of event handling. Mouse events which happen while the pointer position corresponds to an unset bit in the mask will be passed on the surface below surface.

An input region is typically used with RGBA surfaces. The alpha channel of the surface defines which pixels are invisible and allows for nicely antialiased borders, and the input region controls where the surface is "clickable".

Use the gdk:display-supports-input-shapes function to find out if a particular backend supports input regions.
 

See also

#2023-4-8