PeachDrawing.Text

PeachDrawing.Text.FontSet

FontSet.TryGetFontData(string, ReadOnlyMemory<byte>) Method

Reads the data of an installed or added font by the font’s own name.

public bool TryGetFontData(string fontName, out System.ReadOnlyMemory<byte> data);

Parameters

fontName System.String

The name of the font.

data System.ReadOnlyMemory<System.Byte>

The bytes of the font, as a standalone font file. They are the set’s own, shared with every reader of that font, and are handed out read-only.

Returns

System.Boolean
false when the set has no font of that name.

Remarks

This is how a CSS src: local(...) reference is served: the name is the one the font file gives itself, the full name of a face rather than the name of its family.