




|
Advanced Java 1.1 AWT
Numerous AWT advancements were introduced in Java 1.1. In addition to a
new way of handling events, several new components, new classes, and techniques
were added.
-
A new package, java.awt.datatransfer, allows data to be cut and pasted between applications.
(In Java 2, the JFC's "Drag and Drop" capability uses this java.awt.datatransfer
package.)
- Applications and applets can find out what the desktop color scheme is
and change their colors so that they fit in with the color scheme
-
Components can now be printed. A new class java.awt.PrintGraphics is a
subclass of java.awt.Graphics. When a user issues a print request, a PrintGraphics
is created and is passed to the component's paint() method.
-
Numerous improvements to graphics and images processing were added.
-
Panels with built-in scrolling ability have been added.
-
A popup menu component (java.awt.PopupMenu) was added
-
Mouseless operation support to keyboard focus traversal and menu shortcuts.
-
With the AWT 1.0, if you wanted to create your own component, you would extend
from either Canvas or Panel. With AWT 1.1, you can now create a "lightweight" component
(a component that has no peer), by subclassing from either Component or
Container. A brief overview of how to subclass Component or Container is given in
this section. (If you need to create a component, please
consider adding our
Custom Components module which provides full coverage
of the topic.)
This section covers the above enhancements. Demonstrations of each of the above
are given. Each exercise focuses on one of the above topics.
Objectives
Learn how to use the AWT 1.1 enhancements, including:
- data transfer/clipboard
- desktop colors
- printing
- graphics and images
- scrolling pane
- popup menu
- mouseless operation
- lightweight UI framework
Specifications
- Duration (total): 2
- Duration of Exercises: 45 minutes
- Duration of Lecture: 1 hour - 1.25 hours
Pre-requisites
If you are building a custom course, you will need to cover these topics before this topic can be presented:
In addition, material covered in this section requires attendees to know the following:
- An understanding of GUI Layout and basic components. You should be able to use the following:
- Layout managers - FlowLayout, BorderLayout, GridLayout
- Components - Button, TextArea, TextField, TextComponent, Label, and Menus
- Containers - Panel, Window, Frame, and Container
- The ability to nest layout managers
- Basic Java knowledge is assumed, including exception handling, threads,
full use of all the language constructs, and familiarity with the core Java 1.1 APIs.
-
Those without these pre-requisites should consider one of
our Ultimate Java Programming Workshops.
A table of contents of this module is available upon request.
Return to the Custom Order Page.
Copyright ©2007 by Petronio Technology Group, Inc. All
rights reserved. Petronio, "Targeted Technology Training", "T3"
and "Turning new technologies into your competitive advantage"
are trademarks of Petronio Technology Group. All other trademarks are the
properties of their respective companies.
|