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.