gtk4::prelude

Trait GtkWindowExt

Source
pub trait GtkWindowExt:
    IsA<Window>
    + Sealed
    + 'static {
Show 94 methods // Provided methods fn close(&self) { ... } fn destroy(&self) { ... } fn fullscreen(&self) { ... } fn fullscreen_on_monitor(&self, monitor: &Monitor) { ... } fn application(&self) -> Option<Application> { ... } fn child(&self) -> Option<Widget> { ... } fn is_decorated(&self) -> bool { ... } fn default_size(&self) -> (i32, i32) { ... } fn default_widget(&self) -> Option<Widget> { ... } fn is_deletable(&self) -> bool { ... } fn must_destroy_with_parent(&self) -> bool { ... } fn focus(&self) -> Option<Widget> { ... } fn gets_focus_visible(&self) -> bool { ... } fn group(&self) -> WindowGroup { ... } fn is_handle_menubar_accel(&self) -> bool { ... } fn hides_on_close(&self) -> bool { ... } fn icon_name(&self) -> Option<GString> { ... } fn is_mnemonics_visible(&self) -> bool { ... } fn is_modal(&self) -> bool { ... } fn is_resizable(&self) -> bool { ... } fn title(&self) -> Option<GString> { ... } fn titlebar(&self) -> Option<Widget> { ... } fn transient_for(&self) -> Option<Window> { ... } fn has_group(&self) -> bool { ... } fn is_active(&self) -> bool { ... } fn is_fullscreen(&self) -> bool { ... } fn is_maximized(&self) -> bool { ... } fn is_suspended(&self) -> bool { ... } fn maximize(&self) { ... } fn minimize(&self) { ... } fn present(&self) { ... } fn present_with_time(&self, timestamp: u32) { ... } fn set_application(&self, application: Option<&impl IsA<Application>>) { ... } fn set_child(&self, child: Option<&impl IsA<Widget>>) { ... } fn set_decorated(&self, setting: bool) { ... } fn set_default_size(&self, width: i32, height: i32) { ... } fn set_default_widget(&self, default_widget: Option<&impl IsA<Widget>>) { ... } fn set_deletable(&self, setting: bool) { ... } fn set_destroy_with_parent(&self, setting: bool) { ... } fn set_display(&self, display: &impl IsA<Display>) { ... } fn set_focus(&self, focus: Option<&impl IsA<Widget>>) { ... } fn set_focus_visible(&self, setting: bool) { ... } fn set_handle_menubar_accel(&self, handle_menubar_accel: bool) { ... } fn set_hide_on_close(&self, setting: bool) { ... } fn set_icon_name(&self, name: Option<&str>) { ... } fn set_mnemonics_visible(&self, setting: bool) { ... } fn set_modal(&self, modal: bool) { ... } fn set_resizable(&self, resizable: bool) { ... } fn set_startup_id(&self, startup_id: &str) { ... } fn set_title(&self, title: Option<&str>) { ... } fn set_titlebar(&self, titlebar: Option<&impl IsA<Widget>>) { ... } fn set_transient_for(&self, parent: Option<&impl IsA<Window>>) { ... } fn unfullscreen(&self) { ... } fn unmaximize(&self) { ... } fn unminimize(&self) { ... } fn default_height(&self) -> i32 { ... } fn set_default_height(&self, default_height: i32) { ... } fn default_width(&self) -> i32 { ... } fn set_default_width(&self, default_width: i32) { ... } fn set_fullscreened(&self, fullscreened: bool) { ... } fn set_maximized(&self, maximized: bool) { ... } fn connect_activate_default<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn emit_activate_default(&self) { ... } fn connect_activate_focus<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn emit_activate_focus(&self) { ... } fn connect_close_request<F: Fn(&Self) -> Propagation + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_enable_debugging<F: Fn(&Self, bool) -> bool + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn emit_enable_debugging(&self, toggle: bool) -> bool { ... } fn connect_keys_changed<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_application_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_child_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_decorated_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_default_height_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_default_widget_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_default_width_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_deletable_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_destroy_with_parent_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_display_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_focus_visible_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_focus_widget_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_fullscreened_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_handle_menubar_accel_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_hide_on_close_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_icon_name_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_is_active_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_maximized_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_mnemonics_visible_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_modal_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_resizable_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_startup_id_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_suspended_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_title_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_titlebar_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... } fn connect_transient_for_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId { ... }
}

Provided Methods§

Source

fn close(&self)

Source

fn destroy(&self)

Source

fn fullscreen(&self)

Source

fn fullscreen_on_monitor(&self, monitor: &Monitor)

Source

fn application(&self) -> Option<Application>

Source

fn child(&self) -> Option<Widget>

Source

fn is_decorated(&self) -> bool

Source

fn default_size(&self) -> (i32, i32)

Source

fn default_widget(&self) -> Option<Widget>

Source

fn is_deletable(&self) -> bool

Source

fn must_destroy_with_parent(&self) -> bool

Source

fn focus(&self) -> Option<Widget>

Source

fn gets_focus_visible(&self) -> bool

Source

fn group(&self) -> WindowGroup

Source

fn is_handle_menubar_accel(&self) -> bool

Available on crate feature v4_2 only.
Source

fn hides_on_close(&self) -> bool

Source

fn icon_name(&self) -> Option<GString>

Source

fn is_mnemonics_visible(&self) -> bool

Source

fn is_modal(&self) -> bool

Source

fn is_resizable(&self) -> bool

Source

fn title(&self) -> Option<GString>

Source

fn titlebar(&self) -> Option<Widget>

Source

fn transient_for(&self) -> Option<Window>

Source

fn has_group(&self) -> bool

Source

fn is_active(&self) -> bool

Source

fn is_fullscreen(&self) -> bool

Source

fn is_maximized(&self) -> bool

Source

fn is_suspended(&self) -> bool

Available on crate feature v4_12 only.
Source

fn maximize(&self)

Source

fn minimize(&self)

Source

fn present(&self)

Source

fn present_with_time(&self, timestamp: u32)

👎Deprecated: Since 4.14
Source

fn set_application(&self, application: Option<&impl IsA<Application>>)

Source

fn set_child(&self, child: Option<&impl IsA<Widget>>)

Source

fn set_decorated(&self, setting: bool)

Source

fn set_default_size(&self, width: i32, height: i32)

Source

fn set_default_widget(&self, default_widget: Option<&impl IsA<Widget>>)

Source

fn set_deletable(&self, setting: bool)

Source

fn set_destroy_with_parent(&self, setting: bool)

Source

fn set_display(&self, display: &impl IsA<Display>)

Source

fn set_focus(&self, focus: Option<&impl IsA<Widget>>)

Source

fn set_focus_visible(&self, setting: bool)

Source

fn set_handle_menubar_accel(&self, handle_menubar_accel: bool)

Available on crate feature v4_2 only.
Source

fn set_hide_on_close(&self, setting: bool)

Source

fn set_icon_name(&self, name: Option<&str>)

Source

fn set_mnemonics_visible(&self, setting: bool)

Source

fn set_modal(&self, modal: bool)

Source

fn set_resizable(&self, resizable: bool)

Source

fn set_startup_id(&self, startup_id: &str)

Source

fn set_title(&self, title: Option<&str>)

Source

fn set_titlebar(&self, titlebar: Option<&impl IsA<Widget>>)

Source

fn set_transient_for(&self, parent: Option<&impl IsA<Window>>)

Source

fn unfullscreen(&self)

Source

fn unmaximize(&self)

Source

fn unminimize(&self)

Source

fn default_height(&self) -> i32

Source

fn set_default_height(&self, default_height: i32)

Source

fn default_width(&self) -> i32

Source

fn set_default_width(&self, default_width: i32)

Source

fn set_fullscreened(&self, fullscreened: bool)

Source

fn set_maximized(&self, maximized: bool)

Source

fn connect_activate_default<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn emit_activate_default(&self)

Source

fn connect_activate_focus<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn emit_activate_focus(&self)

Source

fn connect_close_request<F: Fn(&Self) -> Propagation + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_enable_debugging<F: Fn(&Self, bool) -> bool + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn emit_enable_debugging(&self, toggle: bool) -> bool

Source

fn connect_keys_changed<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId

👎Deprecated: Since 4.10
Source

fn connect_application_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_child_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId

Source

fn connect_decorated_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_default_height_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_default_widget_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_default_width_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_deletable_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_destroy_with_parent_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_display_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_focus_visible_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_focus_widget_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_fullscreened_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_handle_menubar_accel_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Available on crate feature v4_2 only.
Source

fn connect_hide_on_close_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_icon_name_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_is_active_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_maximized_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_mnemonics_visible_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_modal_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId

Source

fn connect_resizable_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_startup_id_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Source

fn connect_suspended_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Available on crate feature v4_12 only.
Source

fn connect_title_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId

Source

fn connect_titlebar_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Available on crate feature v4_6 only.
Source

fn connect_transient_for_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§