Function
GdkPopupLayoutnew
Declaration [src]
GdkPopupLayout*
gdk_popup_layout_new (
const GdkRectangle* anchor_rect,
GdkGravity rect_anchor,
GdkGravity surface_anchor
)
Description [src]
Create a popup layout description.
Used together with gdk_popup_present()
to describe how a popup
surface should be placed and behave on-screen.
anchor_rect
is relative to the top-left corner of the surface’s parent.
rect_anchor
and surface_anchor
determine anchor points on anchor_rect
and surface to pin together.
The position of anchor_rect
‘s anchor point can optionally be offset using
gdk_popup_layout_set_offset()
, which is equivalent to offsetting the
position of surface.
Parameters
anchor_rect
-
Type:
GdkRectangle
The anchor
GdkRectangle
to alignsurface
with.The data is owned by the caller of the function. rect_anchor
-
Type:
GdkGravity
The point on
anchor_rect
to align withsurface
‘s anchor point. surface_anchor
-
Type:
GdkGravity
The point on
surface
to align withrect
‘s anchor point.
Return value
Type: GdkPopupLayout
Newly created instance of GdkPopupLayout
.
The caller of the function takes ownership of the data, and is responsible for freeing it. |