Struct XFontStretch
Describes the degree to which a font has been stretched compared to the normal aspect ratio of that font.
public readonly struct XFontStretch : IFormattable
- Implements
- Inherited Members
Methods
Compare(XFontStretch, XFontStretch)
Compares two instances of System.Windows.XFontStretch objects.
public static int Compare(XFontStretch left, XFontStretch right)
Parameters
left
XFontStretchThe first System.Windows.XFontStretch object to compare.
right
XFontStretchThe second System.Windows.XFontStretch object to compare.
Returns
- int
An int value that represents the relationship between the two instances of System.Windows.XFontStretch.
Equals(XFontStretch)
Compares a System.Windows.XFontStretch object with the current System.Windows.XFontStretch object.
public bool Equals(XFontStretch obj)
Parameters
obj
XFontStretchThe instance of the System.Windows.XFontStretch object to compare for equality.
Returns
Equals(object?)
Compares a object with the current System.Windows.XFontStretch object.
public override bool Equals(object? obj)
Parameters
Returns
FromOpenTypeStretch(int)
Creates a new instance of System.Windows.XFontStretch that corresponds to the OpenType usStretchClass value.
public static XFontStretch FromOpenTypeStretch(int stretchValue)
Parameters
stretchValue
intAn integer value between one and nine that corresponds to the usStretchValue definition in the OpenType specification.
Returns
- XFontStretch
A new instance of System.Windows.XFontStretch.
GetHashCode()
Retrieves the hash code for this object.
public override int GetHashCode()
Returns
ToOpenTypeStretch()
Returns a value that represents the OpenType usStretchClass for this System.Windows.XFontStretch object.
public int ToOpenTypeStretch()
Returns
- int
An integer value between 1 and 999 that corresponds to the usStretchClass definition in the OpenType specification.
ToString()
Creates a string representation of the current System.Windows.XFontStretch object based on the current culture.
public override string ToString()
Returns
Operators
operator ==(XFontStretch, XFontStretch)
Compares two instances of System.Windows.XFontStretch for equality.
public static bool operator ==(XFontStretch left, XFontStretch right)
Parameters
left
XFontStretchFirst instance of System.Windows.XFontStretch to compare.
right
XFontStretchSecond instance of System.Windows.XFontStretch to compare.
Returns
operator >(XFontStretch, XFontStretch)
Evaluates two instances of System.Windows.XFontStretch to determine if one instance is greater than the other.
public static bool operator >(XFontStretch left, XFontStretch right)
Parameters
left
XFontStretchFirst instance of System.Windows.XFontStretch to compare.
right
XFontStretchSecond instance of System.Windows.XFontStretch to compare.
Returns
operator >=(XFontStretch, XFontStretch)
Evaluates two instances of System.Windows.XFontStretch to determine whether one instance is greater than or equal to the other.
public static bool operator >=(XFontStretch left, XFontStretch right)
Parameters
left
XFontStretchThe first instance of System.Windows.XFontStretch to compare.
right
XFontStretchThe second instance of System.Windows.XFontStretch to compare.
Returns
operator !=(XFontStretch, XFontStretch)
Evaluates two instances of System.Windows.XFontStretch to determine inequality.
public static bool operator !=(XFontStretch left, XFontStretch right)
Parameters
left
XFontStretchThe first instance of System.Windows.XFontStretch to compare.
right
XFontStretchThe second instance of System.Windows.XFontStretch to compare.
Returns
operator <(XFontStretch, XFontStretch)
Evaluates two instances of System.Windows.XFontStretch to determine whether one instance is less than the other.
public static bool operator <(XFontStretch left, XFontStretch right)
Parameters
left
XFontStretchThe first instance of System.Windows.XFontStretch to compare.
right
XFontStretchThe second instance of System.Windows.XFontStretch to compare.
Returns
operator <=(XFontStretch, XFontStretch)
Evaluates two instances of System.Windows.XFontStretch to determine whether one instance is less than or equal to the other.
public static bool operator <=(XFontStretch left, XFontStretch right)
Parameters
left
XFontStretchThe first instance of System.Windows.XFontStretch to compare.
right
XFontStretchThe second instance of System.Windows.XFontStretch to compare.