setBounds(int x,int y,int width,int height)可以设置组件位置,但是要注意把容器的布局管理设置为null 即
容器对象.setLayout(null);
否则容器默认的布局会对你设置的组件位置产生干扰。
setBounds(int x,int y,int width,int height)可以设置组件位置,但是要注意把容器的布局管理设置为null 即
容器对象.setLayout(null);
否则容器默认的布局会对你设置的组件位置产生干扰。