I want to put text ( must be formatted with HTML, so I can't use drawString in PaintComponent) inside Circle. Problem is that "paintComponent" is called after drawing label, so it covers my text.
How to draw oval at the beginning and then draw my String?
class Circle extends JLabel
{
public Circle(String string) { super(string); }
@Override
public void paintComponent( Graphics g )
{
super.paintComponent(g);
g.setColor(Color.yellow);
g.fillOval(0,0, 70, 70);
g.setColor(Color.blue);
g.drawOval(0,0, 70, 70);
}
}
