SkinValue

References
public readonly struct SkinValue : IEquatable<SkinValue>
The value of a skin property: a colour, a number, a filter or a dash pattern, never more than one.

Properties

Colour

#
public Colour Colour { get; }

Dash

#
public float[] Dash { get; }
The dash and gap lengths of a dash value, empty for solid. Null for other kinds.

Filter

#
public Modifier[] Filter { get; }
The modifiers of a filter value, in order of application. Null for other kinds.

Kind

#
public PropertyType Kind { get; }

Number

#
public double Number { get; }

Methods

Equals

#
public override bool Equals(object obj)
obj (object)
ValueType.Equals

Equals

#
public bool Equals(SkinValue other)
other (SkinValue)

From

#
public static SkinValue From(Color colour)
colour (Color)

From

#
public static SkinValue From(Colour colour)
colour (Colour)

From

#
public static SkinValue From(double number)
number (double)

From

#
public static SkinValue From(float[] dash)
A dash value: alternating dash and gap lengths in multiples of the stroke width. Empty, or null, is a solid stroke. Lengths may not be negative and cannot all be zero.
dash (float[])

From

#
public static SkinValue From(Modifier[] filter)
A filter value: a stack of colour modifiers, possibly empty. Null counts as empty.
filter (Modifier[])

GetHashCode

#
public override int GetHashCode()

ToEto

#
public Color ToEto()
Gets the colour as an Eto colour, clipped to the sRGB gamut.

ToString

#
public override string ToString()