adw.window
Module for [Window] class
Types 3
A freeform window.
The adw.window.Window widget is a subclass of gtk.window.Window which has no titlebar area. Instead, adw.toolbar_view.ToolbarView can be used together with adw.header_bar.HeaderBar or gtk.header_bar.HeaderBar as follows:
<object class="AdwWindow">
<property name="content">
<object class="AdwToolbarView">
<child type="top">
<object class="AdwHeaderBar"/>
</child>
<property name="content">
<!-- ... -->
</property>
</object>
</property>
</object>Using gtk.window.Window.titlebar or gtk.window.Window.child is not supported and will result in a crash. Use adw.window.Window.content instead.
Dialogs
adw.window.Window can contain adw.dialog.Dialog. Use adw.dialog.Dialog.present with the window or a widget within a window to show a dialog.
Breakpoints
adw.window.Window can be used with adw.breakpoint.Breakpoint the same way as adw.breakpoint_bin.BreakpointBin. Refer to that widget's documentation for details.
Example:
<object class="AdwWindow">
<property name="width-request">360</property>
<property name="height-request">200</property>
<property name="content">
<object class="AdwToolbarView">
<child type="top">
<object class="AdwHeaderBar"/>
</child>
<property name="content">
<!-- ... -->
</property>
<child type="bottom">
<object class="GtkActionBar" id="bottom_bar">
<property name="revealed">True</property>
<property name="visible">False</property>
</object>
</child>
</object>
</property>
<child>
<object class="AdwBreakpoint">
<condition>max-width: 500px</condition>
<setter object="bottom_bar" property="visible">True</setter>
</object>
</child>
</object>Like adw.breakpoint_bin.BreakpointBin, if breakpoints are used, adw.window.Window doesn't have a minimum size, and gtk.widget.Widget.widthRequest and gtk.widget.Widget.heightRequest properties must be set manually.
WindowGidBuilder builder() static nothrowGet builder for [adw.window.Window] Returns: New builder objectvoid content(gtk.widget.Widget propval) @property nothrowSet `content` property. Params: propval = The content widget.adw.breakpoint.Breakpoint currentBreakpoint() @property nothrowGet `currentBreakpoint` property. Returns: The current breakpoint.gio.list_model.ListModel dialogs() @property nothrowGet `dialogs` property. Returns: The open dialogs.adw.dialog.Dialog visibleDialog() @property nothrowGet `visibleDialog` property. Returns: The currently visible dialogadw.breakpoint.Breakpoint getCurrentBreakpoint() nothrowGets the current breakpoint. Returns: the current breakpointgio.list_model.ListModel getDialogs() nothrowReturns a [gio.list_model.ListModel] that contains the open dialogs of self.adw.dialog.Dialog getVisibleDialog() nothrowReturns the currently visible dialog in self, if there's one. Returns: the visible dialogFluent builder implementation template for adw.window.Window
T content(gtk.widget.Widget propval) nothrowSet `content` property. Params: propval = The content widget.Fluent builder for adw.window.Window