Skip to content

addWindowsFont

Adds a font from the Windows Fonts directory.

Syntax

lua
Ham.addWindowsFont(fontName, size)

Parameters

NameTypeDescription
fontNamestringFont filename (e.g., "arial.ttf")
sizenumberFont size in pixels

Returns

  • userdata|nil - Font handle or nil on failure

Example

lua
local arialFont = Ham.addWindowsFont("arial.ttf", 16)

See Also

Released under the ISC License.