FontDescribes a font with render options such as letter spacing, line height, and capitalization. To load a font and render text, pass a Font to getFontFromURL which returns a FontRenderer. const font = Font( "https://fonts.gstatic.com/s/pacifico/v22/FwZY7-Qmy14u9lezJ96A4sijpFu_.ttf", { connect: "dots and letters", lineHeight: 0.8 }, ); const fontRenderer = getFontFromURL(font); const result = fontRenderer.renderLine("boop"); return result.geometry; ConstructorsFont(font,renderOptions)→Fontfont(string | Font)renderOptionsPartial{}Properties.urlstringThe URL of the font file to load (e.g. a .ttf from Google Fonts)..renderOptionsPartialOptions that control how text is rendered, such as letter spacing, line height, and capitalization.
Describes a font with render options such as letter spacing, line height, and capitalization.
To load a font and render text, pass a
FonttogetFontFromURLwhich returns aFontRenderer.