Effective Tcl/Tk Programming: Writing Better Programs in Tcl and Tk | 拾書所

Effective Tcl/Tk Programming: Writing Better Programs in Tcl and Tk

$ 1,829 元 原價 1,829

 

Description

 

The Tcl scripting language and the Tk toolkit together create a programming environment for creating graphical user interfaces. There is increasing interest in using Tcl/Tk in university classes in order to free students to concentrate on algorithms, etc., rather than spending lots of time on implementation in a lower level language. Anyone who has read Ousterhout's definitive description of the language and wants to learn more about Tcl/Tk will find this book the perfect next step. Based on the authors' extensive experience building and deploying mission-critical Tcl software and teaching others to do the same, this book offers a wealth of practical information on how to exploit the full potential of this remarkable programming environment. Using real programs as examples, the book demonstrates Tcl and Tk concepts. It shows readers how to build Tcl applications effectively and efficiently through plenty of real-world advice, offers valuable design strategies, and points out pitfalls that readers should avoid. It clarifies the more confusing aspects of Tcl/Tk and thoroughly explains Tcl features that have no counterpart in conventional programming languages. Preface.
1. Building Tcl/Tk Applications.

Application-Building Process.
A Small Application.
Designing the Application.
Designing the Screen.
Prototyping the Screen.
Library Analysis.
Adding Behavior to the Program.
Adding Finishing Touches.
Testing the Program.
Packaging the Program.


2. Packing, Gridding, and Placing Windows.

 

Using the Pack Command.
Cavity-Based Model.
Packing Options.
Packing Order.
Hierarchical Packing.
Compressing Windows.
Enlarging Windows.
Unpacking Widgets.
Using the Grid Command.
Grid-Based Model.
Gridding Options.
Resizing Windows.
Mixing Grid and Pack.
Using the Place Command.
Coordinate-Based Model.
Custom Geometry Managers.


3. Handling Events.

 

 

The Event Loop.
Keyboard Focus.
Forcing Updates.
Handling Long-Running Bindings.
Execution Scope.
Quoting and the Event Loop.
Simple Examples Using Bind.
Selecting an Item from a Listbox.
Automatic Button Help.
Class Bindings.
Syntax of the Bind Command.
The Event Specification.
Percent Substitutions.
More Complex Events.
Click, Drag, Drop.
Customizing Widget Behavior.
Binding Tags.
Default Binding Tags.
Using Break to Interrupt Event Processing.
Inventing Binding Tags for Groups of Bindings.
Binding to a Toplevel Widget.
Debugging Bindings.
Displaying Bindings.
Monitoring Events.
Animation.
Animating Items on a Canvas.
Debugging After Events.
Library Procedures for Animation.


4. Using the Canvas Widget.

 

 

Understanding the Canvas Widget.
Scrolling.
Display List Model.
Using Tags.
Canvas Bindings.
Scrollable Form.
Progress Gauge.
HSB Color Editor.
Tabbed Notebook.
Calendar.
Handling Size Changes.
Sensors and Callbacks.
Monitoring Variables.
Simple Drawing Package.
Drawing Items.
Selecting Items.
Moving and Deleting Items.
Configuring Items.
Resizing Items.
Entering Text.
Printing a Drawing.
Saving a Drawing.
Loading a Drawing.


5. Using the Text Widget.

 

 

Understanding the Text Widget.
Indexing Model.
Scrolling.
Using Tags.
Text Bindings.
Using Marks.
Wrap Modes.
Tab Stops.
Simple Text Editor.
Read-Only Text Display.
Appointment Editor.
Using Tags to Apply Styles.
Embedded Windows.
Changing Text Bindings.
Retrieving Appointments.
Hierarchical Browser.
Hierarchical Data.
Creating the Hierarchical Browser.
Using Tags and Marks.


6. Top-level Windows.

 

 

Toplevel Widgets.
Setting the Widget Class.
Communicating with the Window Manager.
Window Placement.
Window Size.
Simple Dialogs.
Modal Dialogs.
Controlling Access to Dialogs.
Create/Destroy Strategy.
Help from the Window Manager.
Show/Hide Strategy.
Unmanaged Windows.
Introductory Placard.
Balloon Help.


7. Interacting with Other Programs.

 

 

Executing other Programs.
Execution Pipelines.
Building Commands and Handling Errors.
Collecting Output from Long-Running Programs.
Driving other Programs without Temporary Files.
Working Around Buffering Problems.
Seeing the Problem.
Fixi

Brand Slider