• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to avoid flickering  RSS feed

 
shalini gnana
Ranch Hand
Posts: 189
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i'm doing program in swing Applet...While displaying the applet is flickering..i'm not using any images,using only drawing...How to avoid flickering
 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In general there there shouldn't be any flickering, since Swing uses double-buffering internally, which should eliminate it. How is your code handling the painting?

I'll move this to the AWT/Swing/GUI forum, since there seems to be nothing applet-specific about it.
 
Campbell Ritchie
Sheriff
Posts: 53774
128
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It is worth checking about double-buffering; go through the constructors of any Components you are using, particularly the JPanel you are drawing on, and see whether they support double-buffering. If there is "boolean double-buffered" in any constructors, try passing "true". See whether that helps.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!