avocado-old/packages/graphics/text.js

18 lines
296 B
JavaScript
Raw Normal View History

2019-11-03 10:41:40 -06:00
import {Text as PIXIText} from '@pixi/text';
import {Renderable} from './renderable';
export class Text extends Renderable {
constructor(text, style) {
super();
this.text = new PIXIText(text, style);
this.anchor = [0.5, 0.5];
}
get internal() {
return this.text;
}
}