A surface that is attached to another surface.
The <GdkPopup> is positioned relative to its parent
surface.
<GdkPopup>s are typically used to implement menus
and similar popups. They can be modal, which is indicated by the
popup:autohide property.
Whether to hide on outside clicks.
Its value is a boolean.
It can only be set when the object is made, with #:autohide.
The parent surface.
Its value is a <GdkSurface>, or #f.
It can only be set when the object is made, with #:parent.
Returns whether this popup is set to hide on outside clicks.
Passed: a <GdkPopup>.
Returned: a boolean.
#t if self will autohide
Returns the parent surface of a popup.
Passed: a <GdkPopup>.
Returned: a <GdkSurface>, or #f.
the parent surface
Obtains the position of the popup relative to its parent.
Passed: a <GdkPopup>.
Returned: a 32-bit integer.
the X coordinate of self position
Obtains the position of the popup relative to its parent.
Passed: a <GdkPopup>.
Returned: a 32-bit integer.
the Y coordinate of self position
Gets the current popup rectangle anchor.
The value returned may change after calling popup:present?, or after the surface:layout signal is emitted.
Passed: a <GdkPopup>.
Returned: a <GdkGravity>.
the current rectangle anchor value of self
Gets the current popup surface anchor.
The value returned may change after calling popup:present?, or after the surface:layout signal is emitted.
Passed: a <GdkPopup>.
Returned: a <GdkGravity>.
the current surface anchor value of self
Present self after having processed the
<GdkPopupLayout> rules.
If the popup was previously not showing, it will be shown, otherwise it will change position according to layout.
After calling this function, the result should be handled in response to
the surface:layout signal being
emitted. The resulting popup position can be queried using
popup:get-position-x,
popup:get-position-y, and the
resulting size will be sent as parameters in the layout signal. Use
popup:get-rect-anchor and
popup:get-surface-anchor to get
the resulting anchors.
Presenting may fail, for example if the self is set to autohide
and is immediately hidden upon being presented. If presenting failed,
the surface:layout signal will not
me emitted.
Passed: a <GdkPopup>.
the <GdkPopup> to show
Passed: a 32-bit integer.
the unconstrained popup width to layout
Passed: a 32-bit integer.
the unconstrained popup height to layout
Passed: a <GdkPopupLayout>.
the <GdkPopupLayout> object used to layout
Returned: a boolean.
#f if it failed to be presented, otherwise #t.