klyn.gui.windows.Font.parse
method
public static parse(description as String) as Font:
Description

Parses the font description consumed by Painter and KSS.

This bridge is useful for components that receive a CSS-like font setting from configuration. New widget code should normally construct a Font directly.

Parameters
ParameterDescription
descriptionDescription such as "bold 15px Cascadia Code".
Returns

Parsed immutable font.

Example
font = Font.parse("italic 18px Noto Serif")
assert font.family == "Noto Serif"