No, This is the sequence diagram if you will,
mainprogram -> create frame1 -> create panel with 2D graphics object
that get painted everytime it recives message from server.
mainprogram->create frame1->create frame2 ->create a textpanel which
updates the text in this box, everytime, it gets the message from the
server.
when the second part is not running the first one works like a charm
but when you enable the second frame, the first frame paint is painting
the frame 1 panel and underneth it paints frame 2 text box message. any
idea how to seperate them and not to paint over again and again?
Monique Y. Mudama - 21 Apr 2006 18:03 GMT
> No, This is the sequence diagram if you will,
>
[quoted text clipped - 10 lines]
> message. any idea how to seperate them and not to paint over again
> and again?
This sounds like a problem with forgetting to call super.paint() or
super.paintComponent() in your custom paint code (depending on whether
you're using AWT or Swing).

Signature
monique
Help us help you:
http://www.catb.org/~esr/faqs/smart-questions.html
DBC User - 21 Apr 2006 19:35 GMT
Yes I wasn't doing the super.paint, the reason is, I want to retain the
old graph and update only the new data. If I do super.paint I loose all
previously drawn graph. Now that i am thinking about it.
Can I generate a image and update the image and show it in a paint,
will it work?
Thanks for the answers.