V
VideoProcessor
Does anyone have a solution for painting in components without overwriting
the paint-Method?
I can access a component'g Graphics-Object by
Component abc;
....
Graphics g = abc.getGraphics();
Then I'm able to paint in it:
g.drawRect(10, 10, 20, 20);
.... and paint it in the component:
abc.paint(g);
The problem to solve is that after updating the component, the rect is not
visible, because it's not in the component graphics. Is there any way to do
this without overwriting the component? Or a way to send a notice that the
component graphic was updated so that I can repaint the rect immediately?
the paint-Method?
I can access a component'g Graphics-Object by
Component abc;
....
Graphics g = abc.getGraphics();
Then I'm able to paint in it:
g.drawRect(10, 10, 20, 20);
.... and paint it in the component:
abc.paint(g);
The problem to solve is that after updating the component, the rect is not
visible, because it's not in the component graphics. Is there any way to do
this without overwriting the component? Or a way to send a notice that the
component graphic was updated so that I can repaint the rect immediately?