gdk.popup

Module for Popup interface

Types 2

interfacePopup

A gdk.popup.Popup is a surface that is attached to another surface.

The gdk.popup.Popup is positioned relative to its parent surface.

gdk.popup.Popups are typically used to implement menus and similar popups. They can be modal, which is indicated by the gdk.popup.Popup.autohide property.

Methods
bool autohide() @propertyGet `autohide` property. Returns: Whether to hide on outside clicks.
gdk.surface.Surface parent() @propertyGet `parent` property. Returns: The parent surface.
bool getAutohide()Returns whether this popup is set to hide on outside clicks. Returns: true if popup will autohide
gdk.surface.Surface getParent()Returns the parent surface of a popup. Returns: the parent surface
int getPositionX()Obtains the position of the popup relative to its parent. Returns: the X coordinate of popup position
int getPositionY()Obtains the position of the popup relative to its parent. Returns: the Y coordinate of popup position
gdk.types.Gravity getRectAnchor()Gets the current popup rectangle anchor.
gdk.types.Gravity getSurfaceAnchor()Gets the current popup surface anchor.
bool present(int width, int height, gdk.popup_layout.PopupLayout layout)Present popup after having processed the [gdk.popup_layout.PopupLayout] rules.

Fluent builder implementation template for gdk.popup.Popup

Methods
T autohide(bool propval)Set `autohide` property. Params: propval = Whether to hide on outside clicks. Returns: Builder instance for fluent chaining
T parent(gdk.surface.Surface propval)Set `parent` property. Params: propval = The parent surface. Returns: Builder instance for fluent chaining