Docs / UI

Glossary: MarkupAnimation

The members of MarkupAnimation, in alphabetical order.

Color legend plain property method

An animation a markup declares in <Ui.Animations> (see MarkupDocument.Animations): a property of one of its elements taken from a value to another over a time, or through several, one <Step> after another. It starts as the markup is loaded, when an element raises an event, or by Start, and stops on an element’s event or by Stop. Starting it stops the markup’s other animations of the same property of the same element, so one started as the mouse enters an element and one as it leaves take turns. One without a From starts from the value the property has as it starts.

A sealed class of the BorrowedTorch.UI.Markup package (namespace BorrowedTorch.UI.Markup). The markup page shows it in context.

Names are colored by what they are: a property, a method or an event; values and fields keep the plain color.

Properties

Animation 🠆

BaseAnimation · Read-only. The BorrowedTorch.UI animation of its last start, an Animation<T> of the property’s type made anew at each start; null before its first start or Seek.

DurationMs 🠆

int · Read-only. Its whole time line, in milliseconds: its Delay, and its steps’ delays and durations (its own Duration for one without steps). One run, without its repeats and the way back of an auto reversing one.

EasingNames 🠆

IReadOnlyList<string> · Static, read-only. The names an Easing takes, in any case: the class names of the shaping functions of BorrowedTorch.ShapingFunctions made by a constructor without parameters (Linear, CubicEaseOut), sorted. For a tool offering them.

IsRunning 🠆

bool · Read-only. Whether it runs now: started, and neither completed nor stopped.

Key 🠆

string · Read-only. The key the markup gives it, the include’s name before it for one of an included UI (left.pulse); null for none. FindAnimation finds it by it.

PositionMs 🠆

int · Read-only. Where its time line is now, in milliseconds from its start: 0 before it first starts or is put somewhere with Seek, and after it stops.

Property 🠆

string · Read-only. The name of the property it animates (DesiredWidth).

StartOn 🠆

string · Read-only. What starts it, as the markup has it: Load, an element’s event (play.OnMouseEnter), or a list of them (Load, play.OnClick); null for none, an animation only code starts.

StopOn 🠆

string · Read-only. The elements’ events that stop it, as the markup has them (play.OnMouseLeave, or a list of them); null for none.

Target 🠆

BaseElement · Read-only. The element whose property it animates.

Methods

Seek() 🠆

Seek(int positionMs) · Shows a moment of it: the property given the value it has at the position, the markup’s other animations of the same property of the same element stopped first. A running one goes on from there; one not running stays there, until Start runs it from its beginning. Before its first start or seek, one without a From is shown from the value the property has now. For a tool scrubbing through it.

Parameter Type Description
positionMs int The moment, in milliseconds from its start, kept within 0 and DurationMs.

Start() 🠆

Start() · Runs it from its beginning, again when it ran before, the markup’s other animations of the same property of the same element stopped first. One without a From starts from the value the property has now.

Stop() 🠆

Stop() · Stops it where it is: the property keeps the value it set last. The next Start runs it from its beginning.