文档

Java™ 教程-Java Tutorials 中文版
使用其他 Swing 功能
Trail: Creating a GUI With JFC/Swing

课程:使用其他 Swing 功能

Examples Index

This lesson contains a collection of how-to pages to help you use miscellaneous Swing features.

如何与桌面类集成

With the Desktop class you can enable your Java application to interact with default applications associated with specific file types on the host platform.

如何创建半透明和形状的 Windows

As of the Java Platform, Standard Edition 6 Update 10 release, you can add translucent and shaped windows to your Swing applications. This lesson shows you how.

How to Decorate Components with JLayer

JLayer is a flexible and powerful decorator for Swing components. It enables you to draw on components and respond to component events without modifying the underlying component directly.

如何使用动作

With Action objects, you can coordinate the state and event handling of two or more components that generate action events. For example, you can use a single Action to create and coordinate a tool-bar button and a menu item that perform the same function.

如何使用 Swing 计时器

With the Swing Timer class, you can implement a thread that performs an action after a delay, and optionally continues to repeat the action. The action executes in the event dispatch thread.

如何支持辅助技术

Swing components have built-in support for assistive technologies. Your program can provide even better support by following a few rules.

如何使用焦点子系统

Some programs need to manipulate focus — for example, to validate input, or change the tab-order of components. This section describes some techniques you can use to customize focus in your program.

如何使用键绑定

With key bindings, you can specify how components react to user typing.

如何在对话框中使用模态

This section describes a new modality model emerged in the Java™ SE version 6 and enables you to apply different modality types to dialog boxes.

如何打印表格

This section describes the printing capabilities for tables and explains how to add printing support to your programs.

如何打印文本

This section describes the printing capabilities for text components and explains how to add printing support to your programs.

如何创建启动画面

With the SplashScreen class you can close the splash screen, change the splash-screen image, obtain the image position or size, and paint in the splash screen.

如何使用系统托盘

This section describes how to add a tray icon to the system tray and apply a text tooltip, a pop-up menu, ballon messages, and a set of listeners associated with it.

使用其他 Swing 特性解决常见问题

This section tells you how to fix problems you might encounter while trying to use the information in this lesson.

If you are interested in using JavaFX to create your GUI, see Using JavaFX Properties and Binding, Creating Visual Effects in JavaFX, Applying Transformations in JavaFX and Creating Transitions and Timeline Animations in JavaFX.


Previous page: Previous Lesson
Next page: How to Integrate with the Desktop Class