Package: gdk

Function gdk-window-move-to-rect

Lambda List

gdk-window-move-to-rect (window rect rect-anchor window-anchor anchor-hints rect-anchor-dx rect-anchor-dy)

Arguments

window -- the gdk-window object to move
rect -- the destination gdk-rectangle to align window with
rect-anchor -- a gdk-gravity value with the point on rect to align with window's anchor point
window-anchor -- a gdk-gravity value with the point on window to align with rect's anchor point
anchor-hints -- positioning hints of type gdk-anchor-hints to use when limited on space
rect-anchor-dx -- a :int with the horizontal offset to shift window, i.e. rect's anchor point
rect-anchor-dy -- a :int with the vertical offset to shift window, i.e. rect's anchor point

Details

Moves the window to rect, aligning their anchor points.

rect is relative to the top-left corner of the window that window is transient for. rect-anchor and window-anchor determine anchor points on rect and window to pin together. rect's anchor point can optionally be offset by rect-anchor-dx and rect-anchor-dy, which is equivalent to offsetting the position of window.

anchor-hints determines how window will be moved if the anchor points cause it to move off-screen. For example, :flip-x will replace :north-west with :north-east and vice versa if window extends beyond the left or right edges of the monitor.

Connect to the "moved-to-rect" signal to find out how it was actually positioned.

Since 3.24
 

See also

2020-9-22