Py5Graphics.text_size()

Sets the current font size.

Description

Sets the current font size. This size will be used in all subsequent calls to the Py5Graphics.text() function. Font size is measured in units of pixels.

This method is the same as text_size() but linked to a Py5Graphics object. To see example code for how it can be used, see text_size().

Underlying Java method: PGraphics.textSize

Syntax

text_size(size: float, /) -> None

Parameters

  • size: float - the size of the letters in units of pixels

Updated on September 11, 2021 16:51:34pm UTC