使用 text() 函数设置字体。
第一个参数font设置字体。 "textFont() 识别一个 p5.Font 对象或一个带有系统字体名称的字符串。例如,'Courier New'。
第二个参数size是可选的。它以以像素为单位来设置字体大小。 这与调用 textSize() 具有相同的效果。
注意:WebGL 模式仅支持加载 loadFont() 的字体。
示例
语法
textFont()
textFont(font, [size])
返回值
对象: 当前字体或 p5 对象。
This page is generated from the comments in src/typography/loading_displaying.js . Please feel free to edit it and submit a pull request!