Documentation
¶
Overview ¶
Package reveal plays the [animations] config on lys-ui revealers: the transition style and duration each transient surface resolves for entering or exiting (the per-surface, global, base cascade), the job of the Rust shell's surface_anim helper.
Index ¶
- Constants
- func Arm(r *widget.Revealer, anims config.AnimationsConfig, s config.AnimSurface, ...)
- func GenieEdge(top bool) widget.Edge
- func Hide(r *widget.Revealer, anims config.AnimationsConfig, s config.AnimSurface, ...)
- func Show(r *widget.Revealer, anims config.AnimationsConfig, s config.AnimSurface)
- func Transition(t config.AnimationType) widget.RevealTransition
Constants ¶
const FadeFrom = 0.4
FadeFrom is the opacity an opening surface fades in from: its first frame is already readable rather than nearly transparent.
Variables ¶
This section is empty.
Functions ¶
func Arm ¶
func Arm(r *widget.Revealer, anims config.AnimationsConfig, s config.AnimSurface, exiting bool)
Arm sets r up for surface s entering (exiting false) or exiting: the resolved transition and duration, disabled animations snapping.
func GenieEdge ¶
GenieEdge is the edge a genie collapses toward for a surface anchored at the top (the popup position's rule: top positions collapse up, everything else down).
func Hide ¶
func Hide(r *widget.Revealer, anims config.AnimationsConfig, s config.AnimSurface, done func())
Hide arms r for exiting s and hides it; done runs once the exit has played (at once when animations are off or nothing shows), unless a Show interrupts it first.
func Show ¶
func Show(r *widget.Revealer, anims config.AnimationsConfig, s config.AnimSurface)
Show arms r for entering s and reveals it.
func Transition ¶
func Transition(t config.AnimationType) widget.RevealTransition
Transition is the revealer transition for a config animation style.
Types ¶
This section is empty.