Skip to main content

Classes Property

Gets or sets the styled element's classes.

Definition

Namespace: Avalonia
Assembly: Avalonia.Base (in Avalonia.Base.dll)

public Classes Classes { get; }

Property Value

Classes

Remarks

Classes can be used to apply user-defined styling to styled elements, or to allow styled elements that share a common purpose to be easily selected.

Even though this property can be set, the setter is only intended for use in object initializers. Assigning to this property does not change the underlying collection, it simply clears the existing collection and adds the contents of the assigned collection.

See Also

Reference

StyledElement Class
Avalonia Namespace