API Reference
FontVariationSettings
Immutable, case-sensitive OpenType axis coordinates in the font's design units. Unknown axes are ignored by a face; supported values are clamped to its declared range.
Inheritance
- Object
- FontVariationSettings
Usage
Explore 4 API references to this type
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by 4
- Property FontSpec.Variations
- Method FontVariationSettings.WithAxis
- Property FontVariationSettings.Default
- Property TextStyleOverride.Variations
Constructors
public FontVariationSettings() #Creates the default instance.
public FontVariationSettings(IEnumerable<KeyValuePair<String, Double>> axes) #Copies axis coordinates. Tags contain exactly four ASCII letters or digits; values must be finite. A specification can contain at most 32 axes.
Parameters
- axes System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<System.String, System.Double>>
Methods
public Boolean ContainsKey(String key) #BooleanTests whether an axis is explicitly selected.
Parameters
- key System.String
public IEnumerator<KeyValuePair<String, Double>> GetEnumerator() #IEnumerator<KeyValuePair<String, Double>>Enumerates selected coordinates in tag order.
public Boolean TryGetValue(String key, out Double value) #BooleanReads an explicitly selected design coordinate.
Parameters
- key System.String
- value System.Double
public FontVariationSettings WithAxis(String tag, Double value) #FontVariationSettingsReturns an independent selection with one axis set or replaced.
Parameters
- tag System.String
- value System.Double
Inherited Methods
public virtual Boolean Equals(Object? obj) #BooleanParameters
- obj Object?
Properties
public static FontVariationSettings Default { get; } #The font's default instance, without explicit axis coordinates.
public Int32 Count { get; } #The number of explicitly selected axes.
public IEnumerable<String> Keys { get; } #The selected axis tags.
public IEnumerable<Double> Values { get; } #The selected design coordinates.
public Double this[String key] { get; } #Gets a selected design coordinate.
Parameters
- key System.String