pub trait PreferencesWindowExt: IsA<PreferencesWindow> + Sealed + 'static {
Show 19 methods // Provided methods fn add(&self, page: &impl IsA<PreferencesPage>) { ... } fn add_toast(&self, toast: Toast) { ... } fn close_subpage(&self) { ... } fn can_navigate_back(&self) -> bool { ... } fn is_search_enabled(&self) -> bool { ... } fn visible_page(&self) -> Option<PreferencesPage> { ... } fn visible_page_name(&self) -> Option<GString> { ... } fn pop_subpage(&self) -> bool { ... } fn present_subpage(&self, subpage: &impl IsA<Widget>) { ... } fn push_subpage(&self, page: &impl IsA<NavigationPage>) { ... } fn remove(&self, page: &impl IsA<PreferencesPage>) { ... } fn set_can_navigate_back(&self, can_navigate_back: bool) { ... } fn set_search_enabled(&self, search_enabled: bool) { ... } fn set_visible_page(&self, page: &impl IsA<PreferencesPage>) { ... } fn set_visible_page_name(&self, name: &str) { ... } fn connect_can_navigate_back_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_search_enabled_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_visible_page_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_visible_page_name_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... }
}
Expand description

Trait containing all PreferencesWindow methods.

§Implementors

PreferencesWindow

Provided Methods§

source

fn add(&self, page: &impl IsA<PreferencesPage>)

Adds a preferences page to @self.

§page

the page to add

source

fn add_toast(&self, toast: Toast)

Displays @toast.

See ToastOverlay::add_toast().

§toast

a toast

source

fn close_subpage(&self)

👎Deprecated: Since 1.4

Closes the current subpage.

If there is no presented subpage, this does nothing.

§Deprecated since 1.4

Use pop_subpage() instead.

source

fn can_navigate_back(&self) -> bool

👎Deprecated: Since 1.4

Gets whether gestures and shortcuts for closing subpages are enabled.

§Deprecated since 1.4

Use NavigationPageExt::can_pop() instead.

§Returns

whether gestures and shortcuts are enabled.

source

fn is_search_enabled(&self) -> bool

Gets whether search is enabled for @self.

§Returns

whether search is enabled for @self.

source

fn visible_page(&self) -> Option<PreferencesPage>

Gets the currently visible page of @self.

§Returns

the visible page

source

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

Gets the name of currently visible page of @self.

§Returns

the name of the visible page

source

fn pop_subpage(&self) -> bool

Available on crate feature v1_4 only.

Pop the visible page from the subpage stack of @self.

§Returns

TRUE if a page has been popped

source

fn present_subpage(&self, subpage: &impl IsA<Widget>)

👎Deprecated: Since 1.4

Sets @subpage as the window’s subpage and opens it.

The transition can be cancelled by the user, in which case visible child will change back to the previously visible child.

§Deprecated since 1.4

Use push_subpage() instead.

§subpage

the subpage

source

fn push_subpage(&self, page: &impl IsA<NavigationPage>)

Available on crate feature v1_4 only.

Pushes @page onto the subpage stack of @self.

The page will be automatically removed when popped.

§page

the subpage

source

fn remove(&self, page: &impl IsA<PreferencesPage>)

Removes a page from @self.

§page

the page to remove

source

fn set_can_navigate_back(&self, can_navigate_back: bool)

👎Deprecated: Since 1.4

Sets whether gestures and shortcuts for closing subpages are enabled.

The supported gestures are:

  • One-finger swipe on touchscreens
  • Horizontal scrolling on touchpads (usually two-finger swipe)
  • Back mouse button

The keyboard back key is also supported, as well as the Alt+ shortcut.

For right-to-left locales, gestures and shortcuts are reversed.

§Deprecated since 1.4

Use NavigationPageExt::set_can_pop() instead.

Has no effect for subpages added with push_subpage().

§can_navigate_back

the new value

source

fn set_search_enabled(&self, search_enabled: bool)

Sets whether search is enabled for @self.

§search_enabled

whether search is enabled

source

fn set_visible_page(&self, page: &impl IsA<PreferencesPage>)

Makes @page the visible page of @self.

§page

a page of @self

source

fn set_visible_page_name(&self, name: &str)

Makes the page with the given name visible.

See visible-page.

§name

the name of the page to make visible

source

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

👎Deprecated: Since 1.4
source

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

source

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

source

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

Object Safety§

This trait is not object safe.

Implementors§