main.java

来自「JAVA编的聊天和文件发送程序」· Java 代码 · 共 39 行

JAVA
39
字号
/*
 * Main.java
 *
 * Created on 2007年10月15日, 下午1:33
 *
 * To change this template, choose Tools | Template Manager
 * and open the template in the editor.
 */

package chat;
import chat.Chat;
import javax.swing.SwingUtilities;
import javax.swing.UIManager;
import javax.swing.UnsupportedLookAndFeelException;
import org.omg.CORBA.COMM_FAILURE;

/** Creates a new instance of Main */
public class Main
{
    
    public static void main(String[] args)
    {
       
        javax.swing.LookAndFeel laf=new com.sun.java.swing.plaf.windows.WindowsLookAndFeel();
        try
        {
            javax.swing.UIManager.setLookAndFeel(laf);
            Chat f=new Chat();
            javax.swing.SwingUtilities.updateComponentTreeUI(f);
            f.setLocationRelativeTo(null);
            f.setVisible(true);
        }
        catch(UnsupportedLookAndFeelException ex)
        {
            ex.printStackTrace();
        }
    }
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?