Expand description
The element layer of Kova Native: elements, styling, reactive bindings, the retained element tree and its frame pipeline, event dispatch, focus and the built-in widgets.
Re-exports§
pub use responsive::Breakpoint;pub use responsive::breakpoint;pub use responsive::responsive;pub use responsive::viewport_size;
Modules§
- elements
- Built-in elements.
- headless
- Driving an element tree without a window: tests, scripted demos and offscreen captures.
- icons
- A small built-in icon set.
- prelude
- Common element-building vocabulary of this crate (the
kova-nativefacade’s prelude re-exports it together with core types). - responsive
- Responsive layout: the window size as reactive state, and breakpoints.
- widgets
- Ready-made widgets built from the primitive elements.
Macros§
- impl_
element_ builder - Implements
InteractiveandIntoElementfor an element type whoseElement::base_mutis available.
Structs§
- AnyElement
- A type-erased element.
- BoxShadow
- A CSS-like box shadow.
- Dispatch
Context - Resources for dispatching an input event.
- Dispatch
Result - Result of dispatching an input event.
- Drag
Event - Pointer drag information.
- Element
Base - State and configuration common to every element.
- Element
Tree - The retained UI of one window.
- EventCx
- Context for event handlers.
- Frame
Context - Resources needed to produce a frame.
- Frame
Output - What the window must do after a frame.
- Frame
Stats - Per frame counters, useful to verify incremental behavior.
- Measure
Cx - Context for measuring leaf content.
- Memory
Clipboard - An in-memory clipboard (tests, headless use).
- NodeId
- Identifies a node in an
ElementTree. - PaintCx
- Context for painting. All public methods take logical coordinates in window space; conversion to device pixels, pixel snapping, transforms, clipping and group opacity are applied automatically.
- Style
- The complete style of an element.
- Text
Editor - Text with a caret, selection and undo/redo. Single-line by default;
TextEditor::set_multilinekeeps line breaks and tabs. - Text
Refinement - Text properties that cascade to descendants.
None= inherit. - Theme
- Colors, radii and type scale used by the built-in widgets.
Enums§
- Mask
- Masks an element and its descendants (like CSS
mask). The element is rendered offscreen and composited through the mask, which is stretched over its border box; anything outside the border box is cut off. - Window
Command - Requests from UI code to the window / application.
Traits§
- Clipboard
- Access to the system clipboard from event handlers.
- Element
- A node in the element tree.
- Interactive
- Builder methods for identity, state styles, reactivity and event handlers.
- Into
Element - Conversion into an element. Implemented for all elements, strings
(become text),
Options andAnyElement. - Styled
- Builder methods shared by every element and by
Styleitself (so state closures like.hover(|s| s.bg(..))use the same vocabulary).