Cross-platform native theme loading for Rust GUI applications. Reads OS themes
on Linux (KDE, GNOME), macOS, and Windows, or loads any of 16 bundled presets
(Catppuccin, Nord, Dracula, Tokyo Night, …), and hands your UI code a fully
populated ResolvedTheme.
| Your GUI framework | Add this crate |
|---|---|
| gpui | native-theme-gpui |
| iced | native-theme-iced |
| Writing a new framework connector | native-theme directly |
The connectors pull native-theme in transitively, so you only add one
dependency for the common case.
Theme— the sparse, TOML-shaped definition a preset or file loads. Fields areOption<T>because presets may omit almost anything.ResolvedTheme— the fully-populated variantTheme::resolve(mode)produces. Every field has a value. Your UI code reads from this.- Preset — a named, bundled theme (e.g.
catppuccin-mocha,kde-breeze,macos-sonoma). Load withTheme::preset("name"). - Connector — a small crate that maps
ResolvedThemeonto a GUI framework's native theming system. You depend on one of these.
- gpui — full widget gallery with live theme switching
- Run:
cargo run -p native-theme-gpui --example showcase-gpui - Screenshots:
native-theme-gpui/README.md
- Run:
- iced — full widget gallery with live theme switching
- Run:
cargo run -p native-theme-iced --example showcase-iced - Screenshots:
native-theme-iced/README.md
- Run:
Semantic icon roles (like StatusBusy or DialogSuccess) map to platform-appropriate glyphs:
- Material Symbols and Lucide bundled for offline use
- freedesktop on Linux — reads the active icon theme (Breeze, Adwaita, …)
- SF Symbols on macOS, Segoe Fluent Icons on Windows (platform lookups)
- Animated indicators respect the OS
prefers-reduced-motionpreference
See native-theme crate docs for the icon-loading API.
- CHANGELOG — release notes per version
- CONTRIBUTING — dev setup, commit conventions, PR workflow
- SECURITY — vulnerability reporting policy
- ROADMAP — what's planned next
Licensed under any of
at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be triple licensed as above, without any additional terms or conditions.



