开发者

graphics.setcolor - what parameter?

im using the Graphics.setColor() to set the color of an arc im drawing. what im tr开发者_如何学Going to figure out is what color format do i stick into the brackets. its not RGB because i cant use letters


You need to pass in a Color object.

The documentation is quite clear - didn't you check it?


You can do the following:

g.setColor(new Color(255, 255, 0);

Where g is an object of type Graphics.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜