Table of Contents

Class Setter

Namespace
Avalonia.Styling
Assembly
Avalonia.Base.dll

A setter for a Style.

public class Setter : SetterBase, ISetterInstance, IAnimationSetter
Inheritance
Setter
Implements
Inherited Members

Remarks

A Setter is used to set a AvaloniaProperty value on a AvaloniaObject depending on a condition.

Constructors

Setter()

Initializes a new instance of the Setter class.

public Setter()

Setter(AvaloniaProperty, object?)

Initializes a new instance of the Setter class.

public Setter(AvaloniaProperty property, object? value)

Parameters

property AvaloniaProperty

The property to set.

value object

The property value.

Properties

Property

Gets or sets the property to set.

public AvaloniaProperty? Property { get; set; }

Property Value

AvaloniaProperty

Value

Gets or sets the property value.

[Content]
[AssignBinding]
[DependsOn("Property")]
public object? Value { get; set; }

Property Value

object

Methods

ToString()

public override string ToString()

Returns

string