Skip to main content

Crate liora_core

Crate liora_core 

Source
Expand description

Core runtime primitives for Liora native GPUI applications.

This crate owns application-wide theme configuration, system-theme synchronization, overlay/portal registries, z-index policy, and small helpers shared by every Liora component crate. Applications normally call liora_components::init_liora or liora::init_liora; use this crate directly when building lower-level integrations or custom component crates.

Re-exports§

pub use fonts::*;
pub use popper::*;

Modules§

fonts
Application-level font loading and typography helpers.
popper
Documents and exposes the popper module APIs.

Structs§

Config
Runtime state used by Liora config behavior.
FontConfig
Ordered font fallback lists used by Liora-rendered UI and code surfaces.
LinuxDesktopIdentity
Metadata and icon bytes used to publish a Linux desktop identity.
LinuxDesktopPngIcon
PNG icon bytes for one hicolor app-icon size bucket.
LioraOptions
Complete options for initializing Liora core state.
Theme
Complete Liora visual token set for one color mode.

Enums§

ThemeMode
Options that control theme mode behavior.

Traits§

ContextExt
Convenience accessors for reading Liora theme data from GPUI contexts.
ElementExt
Element extension points reserved for applying Liora-wide styling helpers.

Functions§

apply_theme_mode
Applies a new theme mode and refreshes the active GPUI window.
attach_system_theme_observer
Attach System theme tracking to a concrete GPUI window.
code_font_family
Returns the resolved code font family or GPUI’s generic monospace family.
ensure_linux_desktop_identity
Installs a user-scoped Linux desktop entry and hicolor icons for an app.
hex_color
Converts a packed RGB integer into a GPUI HSLA color.
init_liora
Initializes Liora core state with an explicit concrete theme.
init_liora_with_mode
Initializes Liora core state from a theme mode, including system mode resolution.
init_liora_with_options
Initializes Liora core state from full startup options.
linux_desktop_entry
Builds a user-level Linux desktop entry for a running Liora app.
linux_desktop_png_icon_path
Returns the user-scoped hicolor app-icon path for an app id and icon size.
liora_theme
Returns the active Liora theme stored in the GPUI application context.
load_custom_fonts
Registers application-provided font files with GPUI’s text system.
next_unique_id
Generate a process-wide unique, monotonically increasing numeric id.
render_active_drawer_in_window
Renders the render active drawer in window layer into native GPUI elements.
render_active_modal_in_window
Renders the render active modal in window layer into native GPUI elements.
render_active_popover_in_window
Renders the render active popover in window layer into native GPUI elements.
render_active_tooltip_in_window
Renders the render active tooltip in window layer into native GPUI elements.
resolve_font_family_from_available
Resolves an ordered fallback list against families currently visible to GPUI.
set_font_config
Replaces Liora font-family overrides for subsequent renders.
stable_unique_id
Return a stable process-wide unique id for the current element path.
startup_maximized_window_bounds
Return startup bounds for a window that should request GPUI maximized state.
sync_system_theme
Synchronizes the active theme from the current system/window appearance.
theme_for_window_appearance
Maps a GPUI window appearance to the matching Liora theme.
tooltip_content_lines
Splits tooltip content into GPUI-safe display lines.
ui_font_family
Returns the resolved UI font family, if the app overrides the system default.
unique_id
Generate a process-wide unique id string with a stable component prefix.
z_index_modal
Returns the z-index reserved for modal overlays.
z_index_notification
Returns the z-index reserved for notifications.
z_index_popup
Returns the z-index reserved for popup overlays.
z_index_tooltip
Returns the z-index reserved for tooltip overlays.