• Post Reply Bookmark Topic Watch Topic
  • New Topic

Double buffering in JPanel  RSS feed

Doug Gschwind
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Has anyone found the threshold that when exceeded forces you to require the use of double buffering in a JPanel? Since double buffering increases memory usage, I would like to only use it when certain hardware resources are lacking and thus induce "flickering" within single buffered JPanel instances.
Also, if a JPanel instance is a nested component within a higher level JPanel instance, should the double buffering policy be set consistently at all levels? e.g.
JPanel parent = new JPanel(true);
JPanel child = new JPanel(true);
Do we care about the double buffering policy of internal JPanels if the top level JPanel's double buffering policy governs all internal panels as well?
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!