Skip to main content

Loading Fonts

To load fonts such as ttf, etc., OSGL uses its own external tool. The tool is bundled with OSGL on the github releases page, here. Pick the one for your OS. If you don't know which to pick, feel free to ask us!

note

You can get help with the exe by running it in the command-prompt, with the -h flag! e.g:

> font-converter -h

You can load fonts into OSGL with the Font.from function, which takes the font generated by the font-converter:

local OSGL = require(path.to.osgl)
local Font = OSGL.Font

local fnt = Font.from(script.ModuleThatReturnsFont)
-- "fnt" now contains the loaded font