Basics of Java GUI user interface programming

Source: Internet
Author: User

Java GUI programming (graphic user interface) is implemented in its Abstract Window Toolkit (AWT), Java. AWT is a tool library of AWT, which supports a wide range of graphics, user interface components, and layout manager.

GUI is mainly used in two places:

◆ Application;

◆ Applet.

1) Gui:

In Java GUIProgramA control panel that contains menus, controls (or components), containers, and responses to user events.

There are various Windows systems. Different Windows systems provide different libraries for programming. For example, Windows-based sdks and Windows-based xlib.

To enable the program to run in different window systems, Java puts forward the concept of "Abstract Window System" and provides AWT (Abstract Window Toolbox ), this allows Java to run in different window systems.

2) GUI implementation in Java:

AWT (Abstract Window tool set) makes Java GUI suitable for different OS environments and creates a multi-system user interface.

Features:

① The specific implementation is explained by the OS on the target platform, as a result, the Java GUI may have different running effects on different platforms (the display effects of the window appearance and font will change ).

② Components should not adopt absolute positioning during design, but should adopt layout manager to achieve relative positioning, so as to be unrelated to the platform and equipment.

3) added Java swing GUI Components

AWT components and event responses are not as rich as Microsoft's sdks (because some OS platforms do not have Microsoft's Windows Components), Sun added the swing GUI component in Java2. However, AWT is relatively simple, and its functions can also meet the needs of most user interfaces, especially in Java Applet design. At the same time, this discussion laid a solid foundation for us to further study the swing GUI components.

96 stack Software Programming Network, http://www.96dz.com, rich C language, C ++ programming, VC ++ programming, Java programming, C # programming, net programming, Linux programming, Web Programming Tutorial resources.

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.