ThemeVariant Class
Specifies a UI theme variant that should be used for the Control and Application types.
Definition
Namespace: Avalonia.Styling
Assembly: Avalonia.Base (in Avalonia.Base.dll)
- C#
- VB
- F#
[TypeConverterAttribute(typeof(ThemeVariantTypeConverter))]
public sealed class ThemeVariant : IEquatable<ThemeVariant>
<TypeConverterAttribute(GetType(ThemeVariantTypeConverter))>
Public NotInheritable Class ThemeVariant
Implements IEquatable(Of ThemeVariant)
[<SealedAttribute>]
[<TypeConverterAttribute(typeof(ThemeVariantTypeConverter))>]
type ThemeVariant =
class
interface IEquatable<ThemeVariant>
end
Inheritance | Object → ThemeVariant |
Implements | IEquatable(ThemeVariant) |
Constructors
ThemeVariant(Object, ThemeVariant) | Creates a new instance of the ThemeVariant |
Properties
Dark | Use the Dark theme variant. |
Default | Inherit theme variant from the parent. If set on Application, system theme is inherited. Using Default as the ResourceDictionary.Key marks this dictionary as a fallback in case the theme variant or resource key is not found in other theme dictionaries. |
InheritVariant | Reference to a theme variant which should be used, if resource wasn't found for the requested variant. |
Key | Key of the theme variant by which variants are compared. |
Light | Use the Light theme variant. |
Methods
Equals(ThemeVariant) | |
GetHashCode() | (Overrides Object.GetHashCode()) |
GetType() | Gets the Type of the current instance. (Inherited from Object) |
ToString() | (Overrides Object.ToString()) |
Operators
Explicit(PlatformThemeVariant to ThemeVariant) | |
Explicit(ThemeVariant to Nullable(PlatformThemeVariant)) |