Expand description
§egui Weave
Accessible components, modern layout ergonomics, and UI-system tooling for egui applications using Taffy.
egui Weave is an immediate-mode integration layer. It keeps widgets, interaction, painting, focus, and responses in egui; keeps intrinsic measurement and the Taffy lifecycle in egui_taffy; and keeps Block, Flexbox, and Grid algorithms in Taffy.
The crate owns a smaller missing contract:
- ergonomic Box, Row, Column, and Grid composition;
- semantic component recipes and themes;
- keyboard and accessibility behavior;
- deterministic container breakpoints;
- layout/pass inspection and regression tests.
It does not provide a DOM, CSS parser, retained widget tree, renderer, state framework, or replacement layout engine.
use egui_weave::{Button, Column, Space, Text, TextRole, WeaveTheme};
fn settings(ui: &mut egui::Ui, saved: &mut bool) {
let theme = WeaveTheme::dark();
Column::new()
.gap(theme.space(Space::Md))
.show(ui, ui.id().with("settings"), &theme, |weave| {
weave.text("title", Text::new("Settings").role(TextRole::PageTitle));
if weave.button("save", Button::new("Save")).clicked() {
*saved = true;
}
});
}§Compatibility
The initial implementation intentionally pins the compatible dependency line:
| egui Weave | egui | egui_taffy | Taffy | Rust | Verified hosts |
|---|---|---|---|---|---|
| 0.1.x | 0.35.x | 0.13.x | 0.9.x | 1.92+ | eframe 0.35, headless egui_kittest 0.35, any host supplying a normal egui::Ui |
The dependency contract remains the exact egui 0.35.0 / egui_taffy 0.13.0 pair.
An isolated package upgrade to egui 0.36.1 / egui_taffy 0.14.0 passes the core tests;
it requires Rust 1.95 and is an upgrade exercise, not a second supported dependency line.
§Run the proof
cargo run --example settings_gallery
cargo run -p weave-data-browser -- applications/data-browser/data/sample.csv
bash scripts/check.sh
python3 scripts/check-performance.py
python3 scripts/check-upgrade.pyThe gallery can switch the same demanding settings surface between direct egui_taffy and the
Weave facade. It also exposes every component, semantic variant, theme, density, breakpoint, zoom,
font scale, representative edge states, and the read-only layout inspector.
§Status
The core and tooling are implemented, with two Codebase settings migrations on an integration
branch and a functional, separately themed CSV application. Application-owned component geometry,
live AccessKit inspection, evidence-linked coverage checks, and executable performance budgets are
present. This is a pre-1.0 candidate, not a claim of production adoption or stability. See
docs/milestone-status.md for the evidence and blockers,
docs/usage.md for integration boundaries, and
docs/customization.md for application styling.
The source checkout also contains the original design in notes/spec.md and the second app in
applications/data-browser; these are not part of the registry library package.
Re-exports§
pub use accessibility::AccessibilityContract;pub use accessibility::COMPONENT_CONTRACTS;pub use accessibility::KeyboardContract;pub use accessibility::NameContract;pub use components::Badge;pub use components::Button;pub use components::Card;pub use components::Checkbox;pub use components::Dialog;pub use components::DialogResponse;pub use components::Divider;pub use components::IconButton;pub use components::Panel;pub use components::ScrollSurface;pub use components::Switch;pub use components::Text;pub use components::TextInput;pub use inspect::AccessibilityTrace;pub use inspect::Diagnostics;pub use inspect::Inspector;pub use inspect::InteractionTrace;pub use inspect::LayoutTrace;pub use inspect::NodeTrace;pub use inspect::ResolvedTokenTrace;pub use inspect::TraceRect;pub use inspect::TraceSize;pub use inspect::TraceWarning;pub use layout::BoxLayout;pub use layout::Column;pub use layout::Grid;pub use layout::LayoutResponse;pub use layout::Row;pub use layout::WeaveUi;pub use responsive::Breakpoint;pub use responsive::Breakpoints;pub use responsive::Responsive;pub use responsive::ResponsiveContext;pub use tokens::Density;pub use tokens::Space;pub use tokens::SurfaceVariant;pub use tokens::TextRole;pub use tokens::Variant;pub use tokens::WeaveTheme;pub use egui_taffy::taffy;
Modules§
- accessibility
- Machine-readable accessibility and keyboard contracts. Machine-readable accessibility and keyboard contracts for public components.
- components
- Accessible egui component recipes. egui-native component recipes.
- governance
- Optional source-consistency and component-coverage checks. Optional, dependency-free source governance checks.
- inspect
- Layout and multipass diagnostics. Read-only diagnostics for Weave layouts.
- layout
- Taffy-backed layout primitives.
Thin ergonomic facade over
egui_taffy. - responsive
- Container-responsive values and breakpoints. Deterministic container-width breakpoints.
- tokens
- Semantic design tokens and themes. Semantic values used by component recipes and layout helpers.
Structs§
- Compatibility
- Human-readable dependency compatibility information.
Constants§
- COMPATIBILITY
- Versions tested together by this release.