Vital.sandbox
Font

self:set_antialiasing

Client

Sets the antialiasing state of the font


Syntax

local status = self:set_antialiasing(enabled)

Parameters

TypeNameDescription
boolenabledDetermines the antialiasing state:
• When true - enables grayscale antialiasing for smoother glyph edges
• When false - disables antialiasing, rendering glyphs as 1-bit bitmaps

Returns

TypeNameDescription
boolstatustrue on successful execution, or false on failure

Examples

Set the antialiasing state of a font
local fontface = font.create("fonts/Roboto-Regular.ttf")

--Enable antialiasing
fontface:set_antialiasing(true)

On this page