Skip to main content

CrossFade Class

Definition

Assembly:Avalonia.Base
Package:Avalonia

Defines a cross-fade animation between two Avalonia.Visuals.

public class CrossFade

Inheritance: object -> CrossFade

Implements:IPageTransition

Constructors

NameDescription
CrossFade (2 overloads)Initializes a new instance of the Avalonia.Animation.CrossFade class.

CrossFade overloads

CrossFade Constructor

Initializes a new instance of the Avalonia.Animation.CrossFade class.

public CrossFade()

CrossFade Constructor

Initializes a new instance of the Avalonia.Animation.CrossFade class.

public CrossFade(TimeSpan duration)
Parameters

duration TimeSpan

The duration of the animation.

Methods

NameDescription
StartNo summary available.

Start Method

public System.Threading.Tasks.Task Start(Avalonia.Visual from, Avalonia.Visual to, System.Threading.CancellationToken cancellationToken)

Parameters

from Avalonia.Visual

to Avalonia.Visual

cancellationToken System.Threading.CancellationToken

Returns

System.Threading.Tasks.Task

Properties

NameDescription
DurationGets the duration of the animation.
FadeInEasingGets or sets element entrance easing.
FadeOutEasingGets or sets element exit easing.
FillModeGets or sets the fill mode applied to both fade animations. Defaults to Avalonia.Animation.FillMode.Forward.

Duration Property

Gets the duration of the animation.

public TimeSpan Duration { get; set; }

FadeInEasing Property

Gets or sets element entrance easing.

public Avalonia.Animation.Easings.Easing FadeInEasing { get; set; }

FadeOutEasing Property

Gets or sets element exit easing.

public Avalonia.Animation.Easings.Easing FadeOutEasing { get; set; }

FillMode Property

Gets or sets the fill mode applied to both fade animations. Defaults to Avalonia.Animation.FillMode.Forward.

public Avalonia.Animation.FillMode FillMode { get; set; }