logo
  • 教程列表
  • SO官方文檔
  • 使用 Swing 進行圖形使用者介面
    • 建立一個空視窗(JFrame)
    • 新增元件
    • 設定元件的引數
    • 通用元件
    • 製作互動式使用者介面
    • 組織元件佈局
  1. StackOverflow 文件
  2. swing 教程
  3. 使用 Swing 進行圖形使用者介面

使用 Swing 進行圖形使用者介面

Created: November-22, 2018

在視窗關閉時退出應用程式

視窗關閉時很容易忘記退出應用程式。請記住新增以下行。

frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE); //Quit the application when the JFrame is closed
  • 建立一個空視窗(JFrame)

Copyright © 2018. All right reserved

tastones.com 备案号:鲁ICP备18045372号-1

  • 關於本站
  • 免責聲明