📄 ballanim.java
字号:
/* * To change this template, choose Tools | Templates * and open the template in the editor. */package ballanim;import java.awt.BorderLayout;import java.awt.Color;import java.awt.Container;import javax.swing.JFrame;/** * * @author Administrator */public class BallAnim extends JFrame{ Container con; Sport ss; public BallAnim(){ super("滚动的小球"); this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); ss = new Sport(); con = this.getContentPane(); con.setLayout(new BorderLayout()); con.setBackground(Color.WHITE); con.add(ss,BorderLayout.CENTER); this.setSize(300, 300); this.setLocationRelativeTo(null); this.setVisible(true); } /** * @param args the command line arguments */ public static void main(String[] args) { // TODO code application logic here BallAnim app = new BallAnim(); }}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -