-
Chapter 1 Getting Started
-
Downloading the SWT Library
-
Configuring Eclipse for SWT Development
-
Supplying the SWT Package to the Java Compiler
-
Specifying the Location of the Native Library
-
Using swt.jar in Multiple Projects
-
-
Chapter 2 SWT Shells
-
Creating a Simple Shell
-
Executing the Example
-
Working with Shell Styles
-
Creating a Shell Styles Example
-
Creating Child Shells
-
Creating Multiple Child Windows
-
Opening True Dialogs
-
Setting the Shell Title Text
-
Setting the Shell Icon
-
-
Chapter 3 SWT Menus
-
Creating the Menu Bar
-
Adding Drop-Down Menus
-
Adding Separator Bars
-
Creating a Complete Menu System
-
Adding Cascading Submenus
-
Making Menus Perform the Intended Action
-
Working with Other Menu Item Styles
-
Determining the State of CHECK and RADIO Menu Items
-
Adding Keyboard Shortcuts
-
Creating Pop-Up Menus
-
-
Chapter 4 SWT Toolbars
-
Creating the Toolbar
-
Creating Toolbar Buttons
-
Creating a Complete Toolbar Example
-
Making the Buttons Work—Adding Listeners
-
Adding Separators to Your Toolbar
-
Adding Check and Radio ToolItems
-
Determining Whether a Check or Radio Button Is Selected
-
Using Tool Tips
-
-
Chapter 5 SWT Text Fields
-
Adding Text Fields to a Shell
-
Adding a Border to a Text Field
-
Positioning the Text Field
-
Setting the Tab Order
-
Setting the Text Size Limit
-
Interacting with the Text in the Text Widget
-
Populating Text Fields from a Database
-
Appending Text to a Text Field's Contents
-
Creating Multiline Text Fields
-
Wrapping Text
-
Adding Scrollbars
-
Reacting to Text Events
-
Performing Field Validation
-
Creating Display-Only Text Fields
-
Creating Password Fields
-
-
Chapter 6 SWT Buttons
-
Creating Push-Style Buttons
-
Responding to Button Clicks
-
Creating Check Buttons
-
Determining CHECK Button Status
-
Adding Listeners to CHECK Buttons
-
Using Radio-Style Buttons
-
Causing No Radio Button to be Selected
-
Creating Toggle Buttons
-
Determining the State of a Toggle Button
-
Creating Arrow Buttons
-
Using Images with Buttons
-
Setting Tool-Tip Text
-
Enabling and Disabling Buttons
-
-
Chapter 7 SWT Lists
-
Creating a List
-
Adding Items to a List
-
Inserting Items in the Middle of a List
-
Populating a List from a Database
-
Removing Items from a List
-
Determining the Selected Items
-
Determining the Selected Item with Multiple Selections
-
Causing an Item to Appear Selected
-
Changing an Item's Text Value
-
Adding Scrollbars to a List
-
-
Chapter 8 The SWT Combo
-
Creating a Combo List
-
Adding Items to a Combo List
-
Creating a Working Combo List
-
Getting the Value of the Selected Item
-
Programmatically Selecting an Item
-
Removing Items from a Combo List
-
Adding Events to Combo Widgets
-
Allowing Additions to the Combo List
-
Getting and Setting Text in the Text Portion of the Combo
-
Setting the Maximum Length for Entries
-
Deselecting Text
-
Responding to Item Changes in the Combo
-
Using the SIMPLE Style
-
-
Chapter 9 SWT Layouts
-
What Are the SWT Layouts?
-
Attaching a Layout to a Container
-
Filling the Entire Container with Widgets
-
Changing Widget Placement in FillLayouts
-
Lining Up Widgets Using RowLayout
-
Controlling Wrapping of Widgets with RowLayout
-
Controlling Sizing of Widgets with RowLayout
-
Creating Vertical Rows
-
Creating a GridLayout
-
Creating Column Headings
-
Controlling Widget Sizing and Alignment
-
Forcing Widgets to Span Multiple Cells
-
The SWT FormLayout
-
Creating a Simple Password Entry Form
-
-
Chapter 10 SWT Composites and Groups
-
Subclassing the Composite Class
-
Using the TextPaneComposite Class on a Shell
-
Using Composite Class Styles
-
Using the Group Class
-
Creating Multiple Instances of a Composite Subclass
-
Using Composites to Achieve Complex Designs
-
An Alternate Approach
-
-
Chapter 11 SWT Tabbed Folders
-
Creating an Instance of TabFolder
-
Creating the Individual Tabs
-
Adding Widgets to the Tabs
-
Creating a Complete Tabbed Folder Example
-
Setting a Default Tab
-
-
Chapter 12 SWT Tables
-
Creating a Simple Table
-
Highlighting Rows upon Selection
-
Allowing Multiple-Row Selection
-
Selecting Items Programmatically
-
Changing the Background Color
-
Creating a Searchable Table
-
Setting the Background of a Single Cell
-
Adding Find-and-Replace Functionality
-
-
Chapter 13 SWT Trees
-
Creating the Tree
-
Adding Items to the Tree
-
Adding Items to Other Items
-
Creating a Full Tree Example
-
Using Images with TreeItem
-
Changing the Image When the Item Is Expanded
-
Using Trees with Other Widgets
-
Working with Other Tree Styles
-
Determining the Checked Item(s)
-
-
Chapter 14 Other SWT Listeners
-
Using KeyListener
-
Using MouseListener
-
Working with the MouseEvent Class
-
Responding to Shift-Click Events
-
Working with the MouseMoveListener
-
Using the MouseTrackListener
-
-
Chapter 15 SWT CoolBars
-
Creating a CoolBar
-
Using Events with CoolBars
-
Adding Widgets Other Than Buttons to the CoolBar
-
Preventing the User from Rearranging the CoolBar
-
Using ToolBars with CoolBars
-
-
Chapter 16 SWT Slider and ProgressBar
-
The SWT Slider Class
-
Using the SWT ProgressBar Class
-
Creating a Moving Progress Bar
-
-
Chapter 17 SWT Standard Dialogs
-
Using the SWT MessageBox Class
-
Using the SWT FileDialog Class
-
Using the SWT FileDialog Class
-
Using the SWT FileDialog Class
-
The SWT ColorDialog Class
-
Using the SWT FontDialog Class
-
Using the SWT PrintDialog Class
-
-
Chapter 18 A Complete SWT Application
-
Designing the Application
-
Developing the Application
-
The End of the SWT Road
-
-
Colophon
- Title:
- SWT: A Developer's Notebook
- By:
- Tim Hatton
- Publisher:
- O'Reilly Media
- Formats:
-
- Safari Books Online
- Print Release:
- October 2004
- Pages:
- 320
- Print ISBN:
- 978-0-596-00838-3
- | ISBN 10:
- 0-596-00838-4
Our look is the result of reader comments, our own experimentation, and feedback from distribution channels. Distinctive covers complement our distinctive approach to technical topics, breathing personality and life into potentially dry subjects. The Developer's Notebook series is modeled on the tradition of laboratory notebooks. Laboratory notebooks are an invaluable tool for researchers and their successors.
The purpose of a laboratory notebook is to facilitate the recording of data and conclusions as the work is being conducted, creating a faithful and immediate history. The notebook begins with a title page that includes the owner's name and the subject of research. The pages of the notebook should be numbered and prefaced with a table of contents. Entries must be clear, easy to read, and accurately dated; they should use simple, direct language to indicate the name of the experiment and the steps taken. Calculations are written out carefully and relevant thoughts and ideas recorded. Each experiment is introduced and summarized as it is added to the notebook. The goal is to produce comprehensive, clearly organized notes that can be used as a reference. Careful documentation creates a valuable record and provides a practical guide for future developers. Jamie Peppard was the production editor and the proofreader for SWT: A Developer's Notebook. Audrey Doyle was the copyeditor. Mary Agner provided production assistance. Sarah Sherman and Claire Cloutier provided quality control. Ellen Troutman wrote the index.
Edie Freedman designed the cover of this book. Clay Fernald produced the cover layout with QuarkXPress 4.1 using the Officina Sans and JuniorHandwriting fonts.
David Futato designed the interior layout, with contributions from Edie Freedman. This book was converted by Julie Hawks to FrameMaker 5.5.6 with a format conversion tool created by Erik Ray, Jason McIntosh, Neil Walls, and Mike Sierra that uses Perl and XML technologies.
The text font is Adobe Boton; the heading font is ITC Officina Sans; the code font is LucasFont's TheSans Mono Condensed, and the handwriting font is a modified version of JuniorHandwriting made by Tepid Monkey Foundry and modified by O'Reilly. The illustrations that appear in the book were produced by Robert Romano and Jessamyn Read using Macromedia FreeHand 9 and Adobe Photoshop 6. This colophon was written by Colleen Gorman.
