pub struct SystemPreferences { /* private fields */ }Expand description
A point-in-time, renderer-independent system appearance and accessibility snapshot.
Optional values are None when the operating system does not publish an equivalent setting.
Implementations§
Source§impl SystemPreferences
impl SystemPreferences
pub fn snapshot() -> Result<Self>
pub const fn color_scheme(self) -> ColorScheme
pub const fn with_color_scheme(self, color_scheme: ColorScheme) -> Self
pub const fn with_reduce_motion(self, reduce_motion: Option<bool>) -> Self
pub const fn with_reduce_transparency( self, reduce_transparency: Option<bool>, ) -> Self
pub const fn with_increase_contrast( self, increase_contrast: Option<bool>, ) -> Self
pub const fn with_differentiate_without_color( self, differentiate_without_color: Option<bool>, ) -> Self
pub const fn with_invert_colors(self, invert_colors: Option<bool>) -> Self
pub const fn with_forced_colors(self, forced_colors: Option<bool>) -> Self
pub const fn with_system_color( self, role: SystemColorRole, color: Option<SystemColor>, ) -> Self
pub const fn with_screen_reader(self, screen_reader: Option<bool>) -> Self
pub const fn with_switch_control(self, switch_control: Option<bool>) -> Self
pub const fn reduce_motion(self) -> Option<bool>
pub const fn reduce_transparency(self) -> Option<bool>
pub const fn increase_contrast(self) -> Option<bool>
pub const fn differentiate_without_color(self) -> Option<bool>
pub const fn invert_colors(self) -> Option<bool>
pub const fn forced_colors(self) -> Option<bool>
pub const fn system_color(self, role: SystemColorRole) -> Option<SystemColor>
pub const fn accent_color(self) -> Option<SystemColor>
pub const fn screen_reader(self) -> Option<bool>
pub const fn switch_control(self) -> Option<bool>
Trait Implementations§
Source§impl Clone for SystemPreferences
impl Clone for SystemPreferences
impl Copy for SystemPreferences
Source§impl Debug for SystemPreferences
impl Debug for SystemPreferences
Source§impl Default for SystemPreferences
impl Default for SystemPreferences
impl Eq for SystemPreferences
Source§impl Hash for SystemPreferences
impl Hash for SystemPreferences
Source§impl PartialEq for SystemPreferences
impl PartialEq for SystemPreferences
impl StructuralPartialEq for SystemPreferences
Auto Trait Implementations§
impl Forget for SystemPreferences
impl Freeze for SystemPreferences
impl Move for SystemPreferences
impl RefUnwindSafe for SystemPreferences
impl Send for SystemPreferences
impl Sync for SystemPreferences
impl Unpin for SystemPreferences
impl UnsafeUnpin for SystemPreferences
impl UnwindSafe for SystemPreferences
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more