Expand description
day-piece-activity — an EXTERNAL Day Piece (DESIGN.md §15) wrapping each toolkit’s NATIVE
indeterminate activity/loading spinner: NSProgressIndicator (Spinning style) on AppKit,
UIActivityIndicatorView on UIKit, GtkSpinner on GTK, a busy QProgressBar (range 0..0) on
Qt, android.widget.ProgressBar on Android, and ProgressRing on XAML. One Rust API registered
link-time into each backend’s renderer slice without touching day, carrying both a
front-end AND its own native backends (including an Android Java shim), see docs/extending.md.
Unlike a media player, a spinner has an intrinsic size — the piece is a natural-size leaf
(no fill_measure; each backend’s default measure returns the native indicator’s fitting
size), so it does not need a .frame(w, h) to be visible (though one gives it a stable region).
.animating(_) accepts a bool, a Signal<bool>, or a closure (default true): a reactive
source starts/stops the animation through an ActivityPatch::Animating write. .large(true)
selects the platform’s large control size.
Structs§
- Activity
- A native activity/loading spinner. Bind its running state with
.animating(_)and pick the large control size with.large(true). - Activity
Props - Full props (realize). Both are set at build; only
animatingpatches thereafter.
Enums§
- Activity
Patch - The one sparse update the spinner takes after creation.
Constants§
Functions§
- activity
activity()— a native indeterminate spinner, animating by default. Configure with.animating(_)(abool,Signal<bool>, or closure) and.large(bool).