GWT Context2d - drawing text - fontsize

1,716 views
Skip to first unread message

ghost23

unread,
Jun 20, 2011, 11:32:32 AM6/20/11
to Google Web Toolkit
Hi,

i am struggling to find documentation and/or examples on the text
related things for GWT canvas (note: the stuff, that's in GWT itself,
not external libraries).
For instance, i would like to set the size of my font, but i cannot
find out, how.

Does somebody know this?

Thanks

Thomas Broyer

unread,
Jun 20, 2011, 11:58:32 AM6/20/11
to google-we...@googlegroups.com
See http://diveintohtml5.org/canvas.html#text
Which translates in GWT into: context2d.setFont("bold 12px sans-serif");

ghost23

unread,
Jun 21, 2011, 3:46:45 AM6/21/11
to Google Web Toolkit
Works! :o)
Thanks

On 20 Jun., 17:58, Thomas Broyer <t.bro...@gmail.com> wrote:
> Seehttp://diveintohtml5.org/canvas.html#text
Reply all
Reply to author
Forward
0 new messages