Creates a new gtk.application_window.ApplicationWindow.
Gets the gtk.shortcuts_window.ShortcutsWindow that is associated with window.
Returns the unique ID of the window.
Returns whether the window will display a menubar for the app menu and menubar as needed.
Associates a shortcuts window with the application window.
Sets whether the window will display a menubar for the app menu and menubar as needed.
Emits the #GActionGroup::action-added signal on action_group.
Emits the #GActionGroup::action-enabled-changed signal on action_group.
Emits the #GActionGroup::action-removed signal on action_group.
Emits the #GActionGroup::action-state-changed signal on action_group.
Activate the named action within action_group.
Request for the state of the named action within action_group to be changed to value.
Checks if the named action within action_group is currently enabled.
Queries the type of the parameter that must be given when activating the named action within action_group.
Queries the current state of the named action within action_group.
Requests a hint about the valid range of values for the state of the named action within action_group.
Queries the type of the state of the named action within action_group.
Checks if the named action exists within action_group.
Lists the actions contained within action_group.
Queries all aspects of the named action within an action_group.
Connect to ActionAdded signal.
Connect to ActionEnabledChanged signal.
Connect to ActionRemoved signal.
Connect to ActionStateChanged signal.
Adds an action to the action_map.
Looks up the action with the name action_name in action_map.
Removes the named action from the action map.
Returns the fallback icon name for windows.
Returns a list of all existing toplevel windows.
Returns a list of all existing toplevel windows.
Sets whether the window should request startup notification.
Sets an icon to be used as fallback.
Opens or closes the interactive debugger.
Requests that the window is closed.
Drop the internal reference GTK holds on toplevel windows.
Asks to place window in the fullscreen state.
Asks to place window in the fullscreen state on the given monitor.
Gets the gtk.application.Application associated with the window.
Gets the child widget of window.
Returns whether the window has been set to have decorations.
Gets the default size of the window.
Returns the default widget for window.
Returns whether the window has been set to have a close button.
Returns whether the window will be destroyed with its transient parent.
Retrieves the current focused widget within the window.
Gets whether “focus rectangles” are supposed to be visible.
Returns the group for window.
Returns whether this window reacts to F10 key presses by activating a menubar it contains.
Returns whether the window will be hidden when the close button is clicked.
Returns the name of the themed icon for the window.
Gets whether mnemonics are supposed to be visible.
Returns whether the window is modal.
Gets the value set by gtk.window.Window.setResizable.
Retrieves the title of the window.
Returns the custom titlebar that has been set with gtk.window.Window.setTitlebar.
Fetches the transient parent for this window.
Returns whether window has an explicit window group.
Returns whether the window is part of the current active toplevel.
Retrieves the current fullscreen state of window.
Retrieves the current maximized state of window.
Retrieves the current suspended state of window.
Asks to maximize window, so that it fills the screen.
Asks to minimize the specified window.
Presents a window to the user.
Presents a window to the user in response to an user interaction.
Sets or unsets the gtk.application.Application associated with the window.
Sets the child widget of window.
Sets whether the window should be decorated.
Sets the default size of a window.
Sets the default widget.
Sets whether the window should be deletable.
If setting is true, then destroying the transient parent of window will also destroy window itself.
Sets the gdk.display.Display where the window is displayed.
Sets the focus widget.
Sets whether “focus rectangles” are supposed to be visible.
Sets whether this window should react to F10 key presses by activating a menubar it contains.
If setting is true, then clicking the close button on the window will not destroy it, but only hide it.
Sets the icon for the window from a named themed icon.
Sets whether mnemonics are supposed to be visible.
Sets a window modal or non-modal.
Sets whether the user can resize a window.
Sets the startup notification ID.
Sets the title of the gtk.window.Window.
Sets a custom titlebar for window.
Dialog windows should be set transient for the main application window they were spawned from. This allows window managers to e.g. keep the dialog on top of the main window, or center the dialog over the main window. gtk.dialog.Dialog.newWithButtons and other convenience functions in GTK will sometimes call gtk.window.Window.setTransientFor on your behalf.
Asks to remove the fullscreen state for window, and return to its previous state.
Asks to unmaximize window.
Asks to unminimize the specified window.
Connect to ActivateDefault signal.
Connect to ActivateFocus signal.
Connect to CloseRequest signal.
Connect to EnableDebugging signal.
Connect to KeysChanged signal.
Emits the #GActionGroup::action-added signal on action_group.
Emits the #GActionGroup::action-enabled-changed signal on action_group.
Emits the #GActionGroup::action-removed signal on action_group.
Emits the #GActionGroup::action-state-changed signal on action_group.
Activate the named action within action_group.
Request for the state of the named action within action_group to be changed to value.
Checks if the named action within action_group is currently enabled.
Queries the type of the parameter that must be given when activating the named action within action_group.
Queries the current state of the named action within action_group.
Requests a hint about the valid range of values for the state of the named action within action_group.
Queries the type of the state of the named action within action_group.
Checks if the named action exists within action_group.
Lists the actions contained within action_group.
Queries all aspects of the named action within an action_group.
Connect to ActionAdded signal.
Connect to ActionEnabledChanged signal.
Connect to ActionRemoved signal.
Connect to ActionStateChanged signal.
Adds an action to the action_map.
Looks up the action with the name action_name in action_map.
Removes the named action from the action map.
gtk.application_window.ApplicationWindow is a gtk.window.Window subclass that integrates with gtk.application.Application.
Notably, gtk.application_window.ApplicationWindow can handle an application menubar.
This class implements the gio.action_group.ActionGroup and gio.action_map.ActionMap interfaces, to let you add window-specific actions that will be exported by the associated gtk.application.Application, together with its application-wide actions. Window-specific actions are prefixed with the “win.” prefix and application-wide actions are prefixed with the “app.” prefix. Actions must be addressed with the prefixed name when referring to them from a gio.menu_model.MenuModel.
Note that widgets that are placed inside a gtk.application_window.ApplicationWindow can also activate these actions, if they implement the gtk.actionable.Actionable interface.
The settings property@Gtk.Settings:gtk-shell-shows-app-menu and property@Gtk.Settings:gtk-shell-shows-menubar tell GTK whether the desktop environment is showing the application menu and menubar models outside the application as part of the desktop shell. For instance, on OS X, both menus will be displayed remotely; on Windows neither will be.
If the desktop environment does not display the menubar, then gtk.application_window.ApplicationWindow will automatically show a menubar for it. This behaviour can be overridden with the property@Gtk.ApplicationWindow:show-menubar property. If the desktop environment does not display the application menu, then it will automatically be included in the menubar or in the windows client-side decorations.
See gtk.popover_menu.PopoverMenu for information about the XML language used by gtk.builder.Builder for menu models.
See also: gtk.application.Application.setMenubar.
A GtkApplicationWindow with a menubar
The code sample below shows how to set up a gtk.application_window.ApplicationWindow with a menu bar defined on the gtk.application.Application: