| Author |
drawing circle with label inside
|
Fano Hery
Greenhorn
Joined: Jul 13, 2010
Posts: 2
|
|
|
i want to draw filled circle with label inside it for example "A" inside the circle. Anyone can help me?
|
 |
Maneesh Godbole
Saloon Keeper
Joined: Jul 26, 2007
Posts: 8430
|
|
Welcome to the Ranch.
What have you got so far, and where are you stuck?
Usually, one would
1) Override the paintComponent method
2) Use the reference to Graphics g and invoke the required method on the "g" instance. e.g. http://faq.javaranch.com/java/BackgroundImageOnJPanel
|
[Donate a pint, save a life!] [How to ask questions] [Onff-turn it on!]
|
 |
Rob Spoor
Sheriff
Joined: Oct 27, 2005
Posts: 19216
|
|
|
You forgot step 1a) call super.paintComponent(g).
|
SCJP 1.4 - SCJP 6 - SCWCD 5
How To Ask Questions How To Answer Questions
|
 |
 |
|
|
subject: drawing circle with label inside
|
|
|