1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
// Copyright 2025 the Xilem Authors
// SPDX-License-Identifier: Apache-2.0
// After you edit the crate's doc comment, run this command, then check README.md for any missing links
// cargo rdme --workspace-project=masonry_core
//! Masonry Core provides the base GUI engine for Masonry.
//!
//! Masonry's widgets are implemented in the Masonry crate, which re-exports this crate as `masonry::core`.
//! Most users who wish to use Masonry for creating applications (and UI libraries) should
//! prefer to depend on Masonry directly (i.e. the `masonry` crate).
//! [Masonry's documentation] can be found on docs.rs.
//!
//! Masonry Core provides:
//!
//! - [`Widget`][core::Widget], the trait for GUI widgets in Masonry.
//! - Event handling and bubbling, using types from [`ui-events`][ui_events] for interoperability.
//! - Communication between parent and child widgets for layout.
//! - Compositing of widget's content (to be rendered using [Imaging][imaging]).
//! - Creation of accessibility trees using [Accesskit][accesskit].
//! - APIs for widget manipulation (such as [`WidgetMut`][core::WidgetMut]).
//! - The [`Action`][core::Widget::Action] mechanism by which widgets send events to the application.
//!
//! Details of many of these can be found in the [Pass System][doc::pass_system] article.
//!
//! If you're writing a library in the Masonry ecosystem, you should depend on `masonry_core`
//! directly where possible (instead of depending on `masonry`).
//! This will allow applications using your library to have greater compilation parallelism.
//! Cases where this apply include:
//!
//! - Writing an alternative driver for Masonry (alike to [Masonry Winit][]).
//! - Writing a library containing one or more custom widget (such as a 2d mapping widget).
//!
//! Masonry Core can also be used by applications wishing to not use Masonry's provided
//! set of widgets, so as to have more control.
//! This can be especially useful if you wish to exactly match the appearance of an existing library,
//! or enforce following a specific design guide, which Masonry's widgets may not always allow.
//! Masonry Core provides a useful shared set of functionality to implement alternative widget libraries.
//! Note that Masonry Core is currently focused primarily on the main Masonry crate itself, as we're
//! not aware of any projects using Masonry Core as described in this paragraph.
//!
//! # Feature flags
//!
//! The following crate [feature flags](https://doc.rust-lang.org/cargo/reference/features.html#dependency-features) are available:
//!
//! - `tracy`: Enables creating output for the [Tracy](https://github.com/wolfpld/tracy) profiler using [`tracing-tracy`][tracing_tracy].
//! This can be used by installing Tracy and connecting to a Masonry with this feature enabled.
//!
//! [Masonry's documentation]: https://docs.rs/masonry/latest/
//! [Masonry Winit]: https://docs.rs/masonry_winit/latest/
//! [tracing_tracy]: https://crates.io/crates/tracing-tracy
// LINEBENDER LINT SET - lib.rs - v5
// See https://linebender.org/wiki/canonical-lints/
// These lints shouldn't apply to examples.
// Targeting e.g. 32-bit means structs containing usize can give false positives for 64-bit.
// END LINEBENDER LINT SET
// TODO: Remove any items listed as "Deferred"
pub use imaging;
pub use palette;
pub use ;
pub use ;
// TODO - re-add #[doc(hidden)]