pub struct GnomePortalData {Show 13 fields
pub is_dark: bool,
pub accent_rgb: Option<(f64, f64, f64)>,
pub high_contrast: bool,
pub reduce_motion: Option<bool>,
pub font_name: Option<String>,
pub monospace_font_name: Option<String>,
pub titlebar_font: Option<String>,
pub text_scaling_factor: Option<f32>,
pub font_dpi: f32,
pub overlay_scrolling: Option<bool>,
pub icon_theme: Option<String>,
pub gsettings_high_contrast: Option<bool>,
pub gsettings_enable_animations: Option<bool>,
}Expand description
Portal + gsettings data using primitive types only.
Constructed from ashpd portal reads + gsettings in production, or directly in tests for deterministic verification. No ashpd types, no D-Bus access, no gsettings subprocess calls.
Fields§
§is_dark: boolWhether the user prefers a dark color scheme.
accent_rgb: Option<(f64, f64, f64)>Accent color as (R, G, B) with components in 0.0..=1.0 (XDG portal spec). None means no accent color set.
high_contrast: boolWhether high contrast is requested (from portal Contrast::High).
reduce_motion: Option<bool>Whether reduced motion is requested. None = not provided by portal.
font_name: Option<String>Primary UI font string in GNOME/Pango format (e.g. “Cantarell 11”).
monospace_font_name: Option<String>Monospace font string (e.g. “Source Code Pro 10”).
titlebar_font: Option<String>Window titlebar font string.
text_scaling_factor: Option<f32>Text scaling factor (e.g. 1.0, 1.25).
font_dpi: f32Font DPI from X resources or display hardware.
overlay_scrolling: Option<bool>Whether overlay scrollbars are enabled. None = not provided.
icon_theme: Option<String>Icon theme name (e.g. “Adwaita”, “Papirus”).
gsettings_high_contrast: Option<bool>High contrast from gsettings fallback (for GNOME < 44).
Only used when high_contrast is false (portal didn’t report high contrast).
gsettings_enable_animations: Option<bool>Reduced motion from gsettings enable-animations fallback.
Only used when reduce_motion is None (portal didn’t report).