I have a JApplet with some controls and i would like to draw a
string of text on the applet when an event occurs.
Here is the pseudo for what i would like, but i dont know the
correct way to write this, the only time i have used graphics is
with awt when i call paint;
public void paint(Graphics g) {
g.drawString("ABC", 10, 40);
}
I can use
public void paint(java.awt.Graphics g) {
...
}
but this just draws a white box over all the swing controls.
Even so, i want to use drawString when a certain event happens. I am
new to swing. I hope this isnt as weird to do as JTable!