# NodeBox

Create visual output with Python programming code
Home Download Reference Tutorial Library Gallery About

# Reference | font()

Syntax |
    font(fontname, fontsize=None)
Description | Sets the current font. The first parameter is the valid name of a font installed on the system. The valid name is the name as it appears in the Font Book application as "Postscript Name". The second parameter is optional and specifies the font size, in the same way as when calling the fontsize() command. All text() commands following the font() command will be drawn in this font.
Returns | the name of the current font
Example |
    font("Helvetica")
    text("Ni!", 10, 10)