AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |
Back to Blog
Abstract windows toolkit8/27/2023 ![]() ![]() Peers are provided by the operating system in the form of widgets themselves. There is one peer for each control and one peer for the dialogue. Java Swing is mainly referred to as Java Foundation Classes (JFC). Java AWT stands for Abstract Window Toolkit. ![]() Java Swing provides a greater number of components than AWT, such as list, scroll panes, tables, color choosers, etc. ![]() The Java AWT provides a smaller number of components in comparison to Swing. The Swing Components are configurable and mainly support pluggable look and feel. It generally depends on the operating system's look and feels. The Appearance of AWT Components is mainly not configurable. The Swing Components are built on the top of AWT. The Swing is mostly lightweight since it doesn't need any Operating system object for processing. The AWT is heavyweight since it uses the resources of the operating system. The Components used in Swing are not dependent on the operating system. The Components used in AWT are mainly dependent on the operating system. The Swing component classes are provided by the javax.swing package. The AWT Component classes are provided by the java.awt package. The main differences between AWT and Swing are given in the following table. Also, the Swing's components are lightweight. The components of Swing are platform-independent, i.e., swing doesn't depend on the operating system to show the components. The javax.swing API provides all the component classes like JButton, JTextField, JCheckbox, JMenu, etc. On the other hand, Swing is the part of JFC (Java Foundation Classes) built on the top of AWT and written entirely in Java. All these classes are part of the Java.awt package. Awt is an abstract window toolkit that provides various component classes like Label, Button, TextField, etc., to show window components on the screen. AWT and Swing are used to develop window-based applications in Java. ![]()
0 Comments
Read More
Leave a Reply. |