A 2-D affine transform (CoreGraphics row-vector convention): a point p maps to
(a·p.x + c·p.y + tx, b·p.x + d·p.y + ty). Used by canvas transform ops for shape
rotate/scale/offset — every native 2-D context concatenates it onto its CTM identically.
Animation intent (§8.4). Native-widget backends map it onto their own animator (Core Animation,
ViewPropertyAnimator, XAML Composition, OH_ArkUI_AnimateTo, …); the canvas/self-driven path
samples curve via Curve::fraction. Threaded through Toolkit::update/set_frame/
set_opacity/set_transform.
Animation intent (§8.4). Native-widget backends map it onto their own animator (Core Animation,
ViewPropertyAnimator, XAML Composition, OH_ArkUI_AnimateTo, …); the canvas/self-driven path
samples curve via Curve::fraction. Threaded through Toolkit::update/set_frame/
set_opacity/set_transform.
A set of screen edges, for the defers_system_gestures modifier (docs/cover.md). Mirrors
SwiftUI’s Edge.Set: on iOS these map to UIRectEdge for
preferredScreenEdgesDeferringSystemGestures; on Android any non-empty set enters
swipe-to-reveal immersive mode (the closest platform analogue).
The family name of a bundled custom font, feeding Font::custom. Holds a &'static str (so
Font stays Copy); generated res::fonts::… constants supply it. The untyped
Font::Custom(&'static str, f64) variant remains the escape hatch for a family known another way.
The full font descriptor a label carries: a semantic (or custom) Font style plus an optional
weight override and italic flag. Backends resolve this to one native font.
A linear gradient (docs/shapes.md §3.2 / §7): color stops along the line from start to
end, both in the unit space of the filled shape’s bounding box. Stops are
(offset 0..=1, color), ascending.
A radial gradient (docs/shapes.md §3.2 / §7): color stops from center outward. Both the
center and the radius live in the unit space of the filled shape’s bounding box, so the
gradient stretches into an ELLIPSE when the bounds aren’t square (the XAML relative-brush
behavior; the other backends reproduce it with a local matrix on a circular gradient). A
radius of 0.5 from the default center touches the edge midpoints of the bounds.
A keyboard shortcut for a menu item. primary is the platform’s command modifier — ⌘ on Apple,
Ctrl on GTK/Qt/XAML — so one declaration reads correctly everywhere. key is a single character
("s", ".") or a named key ("Return", "Delete", "Left", "F1").
A cheap per-node visual transform (§8.4 animation): translation, uniform/non-uniform scale, and
rotation about a unit anchor (0.0..1.0 within the node’s bounds; default center). Distinct
from the layout frame — animating a Transform never triggers relayout, so it is the vehicle
for movement/scaling animation. Each backend composes it onto the node’s laid-out frame via its
native transform channel (CALayer/GskTransform/RenderTransform/NODE_TRANSFORM/…).
A point in the unit space of a shape’s bounding box: (0,0) = top-leading, (1,1) =
bottom-trailing. Gradient geometry is expressed in unit points so one paint value works for
any shape size (docs/shapes.md §3.2).
Two-axis placement of a child within a container’s bounds (SwiftUI’s Alignment). Used by
the z-layering primitives ([OverlayLayout]): zstack, overlay/overlay_aligned.
The timing curve of an animation (§8.4). Native backends map each variant onto their own
easing (CAMediaTimingFunction, QEasingCurve, ArkUI ARKUI_CURVE_*, spring animators); the
canvas/self-driven path samples it via Curve::fraction. Spring matches SwiftUI’s
.spring(response:dampingFraction:).
A semantic (logical) text style. Each maps to the PLATFORM’s native text style where the toolkit
has one — UIFont/NSFont.preferredFont(forTextStyle:) on Apple (Dynamic Type), the
*TextBlockStyle resources on XAML — so a Day app matches the OS’s own typography and inherits its
accessibility text scaling for free. Backends without semantic styles (GTK/Qt/Android) approximate
with sizes that still track the platform’s text-scale / font-scale accessibility setting.
Font weight, matching UIFont.Weight / SwiftUI Font.Weight (lightest → heaviest).
Ordered by heaviness, so backends can e.g. map >= Semibold to a synthesized bold face.
A gesture a node wants delivered. Backends attach the matching native recognizer when day-core
calls Toolkit::enable_gesture; the default is no gesture (recognizers cost, so opt-in).
A standard menu-bar slot (macOS’s File/Edit/View/Window/Help, and their counterparts
elsewhere). A backend that has a house style for the menu bar fills every slot an app did
not claim with its own stock menu, so an app never has to restate the platform’s furniture
— and can still replace any of it by tagging its own submenu with the matching role.
A standard/system command. The backend supplies the NATIVE item — selector on AppKit/UIKit
(cut:/copy:/paste:…), a stock action on GTK/Qt/XAML — so it targets the focused control,
gets the platform’s default label + shortcut, and enables/disables itself automatically. This is
how default items (Edit ▸ Cut/Copy/Paste, the app’s Quit/About) are accommodated without the app
re-implementing them.
A fill source: a solid color, or a linear/radial gradient (docs/shapes.md §3.2 — angular and
semantic tokens are later phases). From<Color> keeps every existing fill(shape, color)
call site compiling unchanged.
A programmatic scroll destination (§7.6, docs/scroll.md). Edges are axis extremes
(Top/Bottom vertical, Leading/Trailing horizontal — start/end in layout direction);
Offset pins the viewport origin to a content-space point (clamped by the platform);
Id reveals the element with that dayscript id inside its nearest enclosing scroll.
A standard icon, named by what it MEANS rather than by how it looks, so each backend can
draw the platform’s own glyph for it — an SF Symbol on macOS, a freedesktop icon name on
GTK and Qt, a Fluent glyph on Windows. This is the only way an icon looks native on every
desktop at once; a bundled PNG cannot, because it is one artist’s take on all four.
What a toolbar item IS. The variants are the vocabulary every desktop toolbar shares; each
backend realizes one with its native control, never with a drawn imitation.
Linear interpolation of animatable values (t in 0.0..1.0). This drives the canvas /
self-driven animation path (docs/shapes.md §5) and Qt’s sampled spring; native-widget
animation does NOT use it — the toolkit interpolates on its own compositor.
Children of a container: a tuple of pieces (the floem ViewTuple pattern — implemented
ONLY for tuples, (), and PieceVec, never via a blanket, to stay coherent).
The binding primitive (§4.2): compute (tracked) + apply (untracked), equality-gated.
Structural priority — bindings drain before plain effects. apply receives the new value
by reference so V needs only PartialEq (no Clone).
Tell layout that a node’s intrinsic size may have changed. For tweaks (docs/tweaks.md):
after a native call that alters a widget’s preferred size (fonts, tick marks, bezel styles),
the measure cache along the node’s path must be invalidated — Day can’t see native mutations
it didn’t make. Relayout runs at the next turn boundary as usual. No-op on a disposed node.
Open url in the platform’s default handler (system browser for http(s), mail client for
mailto:, …). The seam behind the link piece; call it directly
from a tap handler for a custom affordance. Fire and forget — no result, unopenable URLs are
ignored by the backend.
Explicitly animate every state change made in f — Day’s equivalent of SwiftUI’s
withAnimation. The mutation runs inside a day_reactive::batch; that batch’s synchronous
fixpoint drain (bindings → patch, plus the turn-end layout → set_frame) executes while
spec is ambient, so the resulting native updates carry the animation intent and the toolkit
animates them on its own compositor. Nesting overrides; the previous ambient restores after.