Package: gtk

Function gtk-window-parse-geometry

Lambda List

gtk-window-parse-geometry (window geometry)

Arguments

window -- a gtk-window widget
geometry -- a geometry string

Return Value

True if the geometry string was parsed successfully.

Details

Parses a standard X Window System geometry string. The gtk-window-parse-geometry function does work on all GTK ports including Win32 but is primarily intended for an X environment.

If either a size or a position can be extracted from the geometry string, the gtk-window-parse-geometry function returns true and calls the gtk-window-default-size and/or gtk-window-move functions to resize/move the window.

If the gtk-window-parse-geometry function returns true, it will also set the :user-pos and/or :user-size hints of the gdk-window-hints flags indicating to the window manager that the size/position of the window was user specified. This causes most window managers to honor the geometry.

Note that for the gtk-window-parse-geometry function to work as expected, it has to be called when the window has its "final" size, i.e. after calling the gtk-widget-show-all function on the contents and the gtk-window-set-geometry-hints function on the window.

Warning

The gtk-window-parse-geometry function has been deprecated since version 3.20 and should not be used in newly written code. Geometry handling in GTK is deprecated.
 

See also

2021-9-12