Java Swing

Course:  SWING
Duration:  5 Days
Level:  I
Course Summary

This course will give students a complete introduction to the Swing component set. They will learn how to use all of the components: how to display them on the screen, register for events, and get information from them. This course will also go into detail about the model-delegate architecture behind the components and discuss all of the data models because understanding the models is essential for applications that require something significantly different from the components' default behavior.

« Hide The Details
Topics Covered In This Course

Introducing Swing

  • What Is Swing?
  • Swing Features
  • Swing Packages and Classes
  • The Model-View-Controller Architecture
  • Working with Swing

Jump-Starting a Swing Application

  • Upgrading AWT Programs
  • A Simple AWT Application
  • Including First Swing Component
  • Beyond Buttons
  • What Is an Internal Frame?
  • A Bigger Application

Swing Component Basics

  • Understanding Actions
  • Graphical Interface Events
  • Graphics Environments
  • Sending Change Events in Swing
  • The JComponent Class
  • Responding to Keyboard Input

Labels and Icons

  • Labels
  • Working with Images
  • Support for HTML
  • Icons
  • Implementing Custom Icons
  • Dynamic Icons
  • The ImageIcon Class

Buttons

  • The ButtonModel Interface
  • The DefaultButtonModel Class
  • The AbstractButton Class
  • The JButton Class
  • The JToggleButton Class
  • The JToggleButton.ToggleButtonModel Class
  • The JCheckBox Class
  • The JRadioButton Class
  • The ButtonGroup Class

Bounded-Range Components

  • The Bounded-Range Model
  • The JScrollBar Class
  • The JSlider Class
  • The JProgressBar Class
  • Monitoring Progress

Lists, Combo Boxes, and Spinners

  • Lists
  • Representing List Data
  • Handling Selections
  • Displaying Cell Elements
  • The JList Class
  • Combo Boxes
  • The JComboBox Class
  • Spinners
  • Spinner Models
  • Spinner Editors

Swing Containers

  • A Simple Container
  • The Root Pane
  • Basic RootPaneContainers
  • The JFrame Class
  • The JWindow Class
  • The JApplet Class

Internal Frames

  • Simulating a Desktop
  • The JInternalFrame Class
  • The JDesktopPane Class
  • The DesktopManager Interface
  • Building a Desktop

Swing Dialogs

  • The JDialog Class
  • The JOptionPane Class
  • Using JOptionPane
  • Simple Examples
  • Getting the Results
  • A Comparison: Constructors vs. Static Methods
  • Using Internal Frame Dialogs with JDesktopPane

Specialty Panes and Layout Managers

  • The JSplitPane Class
  • The JScrollPane Class
  • The JTabbedPane Class
  • Layout Managers
  • The SpringLayout Class
  • Other Panes

Chooser Dialogs

  • The JFileChooser Class
  • The File Chooser Package
  • The Color Chooser
  • The JColorChooser Class
  • Developing a Custom Chooser Panel
  • Developing a Custom Preview Panel
  • Developing a Custom Dialog

Borders

  • Introducing Borders
  • Painting Borders Correctly
  • Swing Borders
  • Creating a Custom Border

Menus and Toolbars

  • Introducing Swing Menus
  • Menu Bar Selection Models
  • The JMenuBar Class
  • The JMenuItem Class
  • The JPopupMenu Class
  • The JMenu Class
  • Selectable Menu Items
  • Toolbars

Tables

  • The JTable Class
  • Implementing a Column Model
  • Table Data
  • Selecting Table Entries
  • Rendering Cells
  • Editing Cells

Advanced Table Examples

  • A Table with Row Headers
  • Large Tables with Paging
  • A Table with Custom Editing and Rendering
  • Charting Data with a TableModel

Trees

  • A Simple Tree
  • Tree Models
  • The JTree Class
  • Tree Nodes and Paths
  • Tree Selections
  • Tree Events
  • Rendering and Editing

Undo

  • The Swing Undo Facility
  • The UndoManager Class
  • Extending UndoManager

Text Basics

  • The Swing Text Components
  • The JTextComponent Class
  • The JTextField Class
  • A Simple Form
  • The JPasswordField Class
  • The JTextArea Class

Formatted Text Fields

  • The JFormattedTextField Class
  • Handling Numerics
  • The DefaultFormatter Class
  • The MaskFormatter Class
  • The InternationalFormatter Class
  • The DateFormatter Class
  • The NumberFormatter Class
  • The DefaultFormatterFactory Class
  • Formatting with Regular Expressions
  • The InputVerifier Class

Carets, Highlighters, and Keymaps

  • Carets
  • Highlighters
  • Keymaps

Styled Text Panes

  • The JTextPane Class
  • AttributeSets and Styles
  • The Document Model
  • Document Events
  • Views
  • The DocumentFilter Class
  • The NavigationFilter Class

Editor Panes and Editor Kits

  • The JEditorPane Class
  • Overview of the Editor Kits
  • HTML and JEditorPane
  • Hyperlink Events
  • The HTMLEditorKit Class
  • Extending HTMLEditorKit
  • Editing HTML
  • Writing HTML
  • Reading HTML
  • A Custom EditorKit

Drag and Drop

  • What Is Drag and Drop?
  • The Drop API
  • The Drag Gesture API
  • The Drag API
  • Rearranging Trees
  • Finishing Touches

Programming with Accessibility

  • How Accessibility Works
  • The Accessibility Package
  • Other Accessible Objects
  • Types of Accessibility
  • The Accessibility Utility Classes
  • Interfacing with Accessibility

Look and Feel

  • How Does It Work?
  • Key Look-and-Feel Classes and Interfaces
  • The MultiLookAndFeel
  • Auditory Cues
  • Look-and-Feel Customization
  • Creation of a Custom Look-and-Feel

Swing Utilities

  • Utility Classes
  • The Timer Class
  • Tooltips
  • Rendering Odds and Ends
  • Event Utilities

Swing Under the Hood

  • Working with Focus
  • Multithreading Issues in Swing
  • Lightweight vs. Heavyweight Components
  • Painting and Repainting
  • Creating a Custom Component
What You Can Expect

At the end of this course, students will be able to:

  • Build applications using Swing components.
  • Understand typical Swing components in business applications
  • Work with Swing containers.
  • Understand layout managers.
  • Format text fields.
  • Use drag-and-drop.
  • Adjust an applications look-and-feel.
Who Should Take This Course

This course is designed for Java Developers and Programmers.

Recommended Prerequisites

Java programming experience is required. Experience with the AWT is helpful, but not required.

Training Style

Instructor led with 50% lecture and 50% lab.

« Hide The Details
Related Courses
Code Course Title Duration Level
JAVA101
Java Development for Mainframe Programmers
5 Days
I
Details
JAVAF
Fundamentals of Java Development
5 Days
I
Details

Every student attending a Verhoef Training class will receive a certificate good for $100 toward their next public class taken within a year.

You can also buy "Verhoef Vouchers" to get a discounted rate for a single student in any of our public or web-based classes. Contact your account manager or our sales office for details.

Schedule For This Course
There are currently no public sessions scheduled for this course. We can schedule a private class for your organization just a couple of weeks from now. Or we can let you know the next time we do schedule a public session.
Notify me the next time this course is confirmed!
Can't find the course you want?
Call us at 800.533.3893, or
email us at [email protected]