PeachBrackets

PeachBrackets.FontDefaults

FontDefaults.ToAxisSettings(string, double) Method

Turns an encoded font-variation-settings value, as the engine hands it to a RenderContext, into the axis settings to request from a font set.

public static System.Collections.Generic.IReadOnlyList<PeachDrawing.Text.AxisSetting> ToAxisSettings(string? encoded, double sizeInPixels);

Parameters

encoded System.String

The encoded settings, or null for none.

sizeInPixels System.Double

The font size in CSS pixels, used for the automatic optical size.

Returns

System.Collections.Generic.IReadOnlyList<AxisSetting>
The axis settings to apply, optical size first.