We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 872594f commit a28ad4eCopy full SHA for a28ad4e
src/typography/p5.Font.js
@@ -15,6 +15,26 @@ import * as constants from '../core/constants';
15
* @class p5.Font
16
* @constructor
17
* @param {p5} [pInst] pointer to p5 instance.
18
+ * @example
19
+ * <div>
20
+ * <code>
21
+ * let font;
22
+ *
23
+ * function preload() {
24
+ * // Creates a p5.Font object.
25
+ * font = loadFont('assets/inconsolata.otf');
26
+ * }
27
28
+ * function setup() {
29
+ * fill('deeppink');
30
+ * textFont(font);
31
+ * textSize(36);
32
+ * text('p5*js', 10, 50);
33
34
+ * describe('The text "p5*js" written in pink on a white background.');
35
36
+ * </code>
37
+ * </div>
38
*/
39
p5.Font = class {
40
constructor(p){
0 commit comments