CS 121 Lecture Notes - Lecture 17: Abstract Window Toolkit
Document Summary
Command-line applications: interact w/ the user only through simple text prompts. Gui component: an object that represents a screen element that"s used to display info or to allow user to interact w the program in a certain way: includes labels, buttons, text fields, scroll bars & menus. Java components & other gui-related classes are defined primary in two packages: java. awt, javax. swing. Container: a special type of component that is used to hold & organize other components. Containers are classified as either heavyweight or lightweight. Heavyweight container: (frame) managed by the underlying operating system on which program is run. Lightweight container: (panel) managed by a java program: heavyweight components are more complex than lightweight, ex: a frame has multiple panes, which are responsible for various characteristics of the frame window. Containers are generally not useful unless they can help us organize & display other components.