What Are Heavy Weight And Light Weight Components In Java?

1 Answers

Muddassar Memon Profile
Muddassar Memon answered
Quite a few subjects connected to the combining of AWT and Swing components are connected to the mixing of the heavyweight and lightweight components. A heavyweight component is the one which related to its own native screen resource. Where as a lightweight component is the one which "borrows" the screen reserve of an ancestor.

There are quite a few vital differences among lightweight and heavyweight components, because all the AWT components are heavyweight and nearly all the Swing component are lightweight, these dissimilarities turn evident when you start putting together Swing components along with AWT components.

A lightweight component may have translucent pixels, where as a heavyweight ones are generally opaque. A lightweight component may seem to come into view as non-rectangular normally because of their aptitude to set translucent areas, where as a heavyweight is restricted to be rectangular.

Answer Question

Anonymous