5
INTRODUCTION TO AWT AND SWING (CONT.)
Different OS platforms have different UI styles, e.g. Windows, Motif. Swing-based programs can be given a specific “look and feel”. Sun developed a platform-neutral look and feel called “Metal”.
2
INTRODUCTION TO AWT AND SWING
AWT: Abstract Window Toolkit. The way the basic AWT library deals with UI elements is to delegate their creation and behavior to the native GUI toolkit on each target OS platform (Windows, Solaris, Macintosh, and so on). This peer-based approach has many drawbacks: (1) UI elements on different OS have subtle differences (2) Some UI elements don’t exist on all platforms. Thus, has to choose “lowest common denominator” approach.
6
DEMO- LOOK AND FEEL DEMO
Java PlafTest
7
CREATING A FRAME