resize


Description:

public void resize (int width, int height)

Resizes the window as if the user had done so, obeying geometry constraints.

The default geometry constraint is that windows may not be smaller than their size request; to override this constraint, call set_size_request to set the window's request to a smaller value.

If resize is called before showing a window for the first time, it overrides any default size set with set_default_size.

Windows may not be resized smaller than 1 by 1 pixels.

When using client side decorations, GTK+ will do its best to adjust the given size so that the resulting window size matches the requested size without the title bar, borders and shadows added for the client side decorations, but there is no guarantee that the result will be totally accurate because these widgets added for client side decorations depend on the theme and may not be realized or visible at the time resize is issued.

If the GtkWindow has a titlebar widget (see set_titlebar), then typically, resize will compensate for the height of the titlebar widget only if the height is known when the resulting GtkWindow configuration is issued. For example, if new widgets are added after the GtkWindow configuration and cause the titlebar widget to grow in height, this will result in a window content smaller that specified by resize and not a larger window.

Parameters:

this

a Window

width

width in pixels to resize the window to

height

height in pixels to resize the window to