FontSourceRef.matchText

Result!(FontMatch, TextError) matchText(in FontDescription desc, const(dchar)[] text, out size_t covered) @safe nothrow;

The face that covers the start of a piece of text, and how much of it: the engine's fallback step.

Parameters

descas for match.
textthe text to cover; must not be empty.
coveredreceives how many leading code points of text the match covers (at least 1 for non-empty text, so callers always advance).

Returns

The match covering the first covered code points, or

INVALID_INPUT for empty text, NO_MATCH when nothing matches at all; backend failures as errors.