drawText method
Draw a text at position (x
,y
).
Implementation
@override
void drawText(String text, num x, num y, PFont font, PStyle style) {
x = transform.x(x);
y = transform.y(y);
x = canvasX(x);
y = canvasY(y);
_setFont(font);
_setFillStyle(style);
_ctx.textBaseline = 'top';
_ctx.fillText(text, x, y);
}