谢谢各位!

解决方案 »

  1.   

    不可能的。
    窗口大小变化后会调用repaint(),repaint()又会调用paint()
      

  2.   

    WaterSpinach (江波) 代码帖出来瞧瞧
      

  3.   

    其实可以这样做。
    因为调整大小是一定会调用paint和repaint的。
    但是楼主可以在继承jframe的时候,同时重写paint和repaint,并在里面什么也不写。
    这样就可以达到不调用paint和repaint的效果了
      

  4.   

    thanks everyone.I have got this problem when I compile my source code under jdk version 5.0when I comile the same source code under jdk 1.4.2, it worked fine.I wondered what make things go like this.PS. BTW, because I use linux without chinese input, I can only write in english.Best regards.