Java Desktop GUI Library

Source: Internet
Author: User

I feel that it is very common to develop Web apps using Java. There are many tools and libraries. If Java is used to develop a common desktop application, which GUI Libraries are available?

I. AWT

Abstract Window Toolkit is the earliest GUI library introduced in Java. It is an encapsulation of native system, and real window rendering is provided by the operating system function, this makes the UI written with AWT display different on different systems-all in the style of the target system.

AWT provides two levels of Java APIs: one is encapsulation of native system windows, events, and other basic mechanisms; the other is the provision of ready-made controls such as buttons and checkbox.

AWT is part of jfc [1]

Ii. Swing

AWT and swing are both components of javase, but swing provides richer functions and controls, such as tabbed panel, scroll panes, trees, tables, and lists.

Besides, swing uses java2d to implement allCodeAll are Java and do not depend on native system. Therefore, its look and feel can be consistent in different systems-but you can also adjust it to display it in the native system style, it can be said that it is more flexible.

Swing adopts the MVC Architecture.

Iii. SWT

Standard Widget Toolkit, developed by ECLIPSE, is the same as AWT, SWT also uses JNI to access native system API implementation, using SWTProgramIs cross-platform, but the implementation of SWT itself needs to be implemented for each platform.

SWT integrates some features of swing and AWT: it calls the native function like AWT, which is highly efficient and maintains the native look & feel, however, it also provides the same powerful functions and rich controls as swing.

Although SWT itself does not support the MVC Architecture, eclipse provides another SWT-based high-level Library: jface and jface not only support the MVC Architecture, but also provide high-level controls and UI mechanisms, such as viewer, wizard, action, etc.

Iv. QT Jambi

This is a Java encapsulation of the famous C ++ GUI library QT. If you are familiar with QT, it should be considerate to use it.

However, QT Jambi was abandoned by Nokia in 10 years, while QT was abandoned by Nokia recently (around And). It is supported by the strength of the test opensource, the future needs to be considered.

V. javafx

Javafx is a high-level GUI framework that can be used to build UIS such as Internet, desktop, mobile, and game console. Its competitors include Ajax, Flash, and Silverlight.

This may not be a good choice for a simple Java Desktop Application.

 

GUI designer

Developing a GUI program without a UI Designer is very inefficient. myeclipse provides a swing GUI designer 10.6 For swing [2], however, at present, most links pointing to it on the network cannot be accessed. It is said that myeclipse has stopped developing it, so the value is not very high. However, Google once again provides the Java GUI Design Artifact: windowsbuilder, which supports swing and SWT and is quite powerful.

 

Therefore, when developing a desktop program in Java, I will select swing (powerful and lightweight, without the need to call native call), with windowsbuilder.

 

[1] jfc = Java fundation classes (similar to MFC ?) It includes AWT, swing, and java2d.

[2] matisse4myeclipse. Its prototype is the UI Designer Matisse in netbean.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.