WaitIndicator Class

Represents a WaitIndicator templated control.

Definition

Namespace: BeeMobile.WaitIndicator
Assembly: BeeMobile.WaitIndicator.AVA.NET6 (in BeeMobile.WaitIndicator.AVA.NET6.dll) Version: 11.0.0.2+61664b59c11b5cd181e5b626b36868b08d174693
C#
public class WaitIndicator : TemplatedControl
Inheritance
Object    AvaloniaObject    Animatable    StyledElement    Visual    Layoutable    Interactive    InputElement    Control    TemplatedControl    WaitIndicator

Remarks

A WaitIndicator is a piece of Graphical User Interface, which provides visual information to the user typically about a lengthy background operation taking place. Informing the user about such operation is important so that the user knows that the application is responsive.

WaitIndicator is based on Avalonia TemplatedControl and therefore the entire implementation of its behavior is part of ControlTemplate which is part of its IResourceDictionary stored under DefaultControlTemplate key.

When delivering its graphical output, WaitIndicator takes values of following properties into consideration:

  • Foreground
  • Background
  • BorderBrush
  • BorderThickness
  • VerticalAlignment
  • HorizontalAlignment
  • Text
  • Padding
  • font related properties

As soon as you make an instance of WaitIndicator visible by setting its IsVisible property to True (which is the default), it will start animating. Once you make WaitIndicator invisible, the animation will also stop. Therefore, it is not necessary to remove it from visual tree, if you plan to show it again later.

Recommended approach to using WaitIndicator is to position it to center of your window/view/screen (container, that is) and make sure it appears on top of any other components. You should also set Width/Height properties to some reasonable values (depending on size of its parent container). To achieve this, make sure that it is the last control added to your container and set its IsVisible property to False. You may optionally set its Text property to some text. Then simply change its visibility, whenever needed.

Constructors

WaitIndicator Initializes a new instance of WaitIndicator class.

Properties

Text Gets or sets text which appears under wait indicator animated graphics.

Methods

InitializeComponent Wires up the controls and optionally loads XAML markup and attaches dev tools (if Avalonia.Diagnostics package is referenced).

Fields

TextProperty Defines the Text property.

See Also