开发者

Is it possible to "Draw" a string to a canvas?

I've largely been using drawable resources to a canvas using a method similar to this:

image.setBounds(x, y, ( x + 100 ), ( y + 100));
image.draw(c);

I want to do the same thing with a string, or more开发者_如何学Python specifically an integer. Point is, I need to be able to display dynamically changeable characters on the canvas. Is there an easy method to do this similar to the drawable method above?


Try the Canvas.drawText(...) method


Use Graphics.drawString.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜