1 posts in topic
Flat View  Flat View

Posted By:   Rohit_Vadera
Posted On:   Tuesday, December 2, 2003 05:05 AM

WHY is AWT called heavy weight and platform dependent


Posted By:   Stephen_McConnell  
Posted On:   Thursday, December 4, 2003 05:16 AM

There's a lot of history in that......

They were called "heavy" weight about the time that Swing first came out. We didn't have Swing when Java first came out (I started with Java 1.0.1). All you had was AWT. Swing didn't become an "external" package (javax) until Java 1.1; and didn't get most of the bugs out until Java 1.1.7.

When Swing came along, they were called "light weight" components (this was explained to me) because of their "light" dependence upon the OS they were running on. They just called the basic line and fill routines from the OS. The rest of the component is drawn by Java....

AWT on the other hand was "heavy weight" because they relied heavily upon the OS to create the button, dropdown, lable, checkboxes etc components. They VM directly calls the OS to generate these components. You can't change the Look and Feel of those components through your java program...

This became a confusing part of Java-ology. Swing is not a rich featured Desktop/Applet (albeit not perfect) GUI part of Java...

Stephen McConnell

About | Sitemap | Contact