void paint(Graphics g) Invoked by Swing to draw components. void paintComponent(Graphics g) Calls the UI delegate's paint method, if the UI delegate is non-null.
void paint(Graphics g) Invoked by Swing to draw components. void paintComponent(Graphics g) Calls the UI delegate's paint method, if the UI delegate is non-null. ----------------------------------------------------------------------------------- 可不可以再详细说一下,我有点不太明白。如果有例子程序,就更好了:),谢谢!
Invoked by Swing to draw components. void paintComponent(Graphics g)
Calls the UI delegate's paint method, if the UI delegate is non-null.
-------------------------------------------
在组件上画的时候
awt中使用paint()
swing中使用paintComponent()
Invoked by Swing to draw components.
void paintComponent(Graphics g)
Calls the UI delegate's paint method, if the UI delegate is non-null.
-----------------------------------------------------------------------------------
可不可以再详细说一下,我有点不太明白。如果有例子程序,就更好了:),谢谢!