Skip to main content

ColorChangedEventArgs Class

Definition​

Assembly:Avalonia.Controls.ColorPicker
Package:Avalonia.Controls.ColorPicker

Holds the details of a ColorChanged event.

public class ColorChangedEventArgs

Inheritance: EventArgs -> ColorChangedEventArgs

Remarks​

HSV color information is intentionally not provided. Use Avalonia.Media.Color.ToHsv to obtain it.

Constructors​

NameDescription
ColorChangedEventArgsInitializes a new instance of the Avalonia.Controls.ColorChangedEventArgs class.

ColorChangedEventArgs Constructor​

Initializes a new instance of the Avalonia.Controls.ColorChangedEventArgs class.

public ColorChangedEventArgs(Avalonia.Media.Color oldColor, Avalonia.Media.Color newColor)

Parameters​

oldColor Avalonia.Media.Color

The old/original color from before the change event.

newColor Avalonia.Media.Color

The new/updated color that triggered the change event.

Properties​

NameDescription
NewColorGets the new/updated color that triggered the change event.
OldColorGets the old/original color from before the change event.

NewColor Property​

Gets the new/updated color that triggered the change event.

public Avalonia.Media.Color NewColor { get; set; }

OldColor Property​

Gets the old/original color from before the change event.

public Avalonia.Media.Color OldColor { get; set; }