Mastering Perl/Tk

by ;
Format: Paperback
Pub. Date: 2002-01-01
Publisher(s): Oreilly & Associates Inc
List Price: $49.99

Buy New

Usually Ships in 5-7 Business Days
$49.94

Rent Textbook

Select for Price
There was a problem. Please try again later.

Rent Digital

Rent Digital Options
Online:1825 Days access
Downloadable:Lifetime Access
$47.99
*To support the delivery of the digital material to you, a digital delivery fee of $3.99 will be charged on each digital item.
$47.99*

Used Textbook

We're Sorry
Sold Out

How Marketplace Works:

  • This item is offered by an independent seller and not shipped from our warehouse
  • Item details like edition and cover design may differ from our description; see seller's comments before ordering.
  • Sellers much confirm and ship within two business days; otherwise, the order will be cancelled and refunded.
  • Marketplace purchases cannot be returned to eCampus.com. Contact the seller directly for inquiries; if no response within two days, contact customer service.
  • Additional shipping costs apply to Marketplace purchases. Review shipping costs at checkout.

Summary

Perl is a powerful programming language used primarily for system administration, web programming, and database manipulation. Perl/Tk is the marriage of Perl with the Tk toolkit, which allows Perl programs to be built with attractive, intuitive GUIs. Mastering Perl/Tk is the "Bible" of Perl/Tk: the one and only book needed not only to get started with Perl/Tk, but also to learn the techniques of experienced Perl/Tk programmers. The first half of the book contains the basics on how to use Perl/Tk, with coverage of all the basic widgets and a thorough tutorial of the geometry managers that determine how each widget is laid out. Mastering Perl/Tk then branches out into advanced applications of Perl/Tk, with a series of extensive program examples. The result is a book that is not only accessible for novices, but will also take experienced programmers to the next step in learning how to program elegantly and effectively in Perl/Tk. The book also includes a complete quick reference for each standard widget and listings of all the extended examples in the book. Book jacket.

Author Biography

Steve Lidie has spent decades consulting, programming and administering systems from Apple, CDC, DEC, HP, IBM, Microsoft and SGI. Author of the Perl/Tk Pocket Reference and graduate of Lehigh University, he currently manages the University's large-scale scientific computing complex, and occasionally writes Tk articles for The Perl Journal and PerlMonth.

Nancy Walsh has been involved with Perl (and Perl/Tk) since 1996. She received a Computer Science degree from the University of Arizona in 1993, and currently works as a Principal Consultant for XOR, Inc. doing J2EE and Java work on various projects. Nancy has taught several Perl/Tk Tutorials at the O'Reilly Open Source Conference and is also the author of Learning Perl/Tk.

Table of Contents

Prefacep. xiii
Hello, Perl/Tkp. 1
Perl/Tk Conceptsp. 2
Some Perl/Tk Historyp. 2
Getting Started with Perl/Tkp. 6
Hello World Examplep. 12
Unsolicited Advicep. 13
Debugging and Prototyping Perl/Tk Programsp. 16
Geometry Managementp. 19
The pack Geometry Managerp. 20
The grid Geometry Managerp. 41
The place Geometry Managerp. 54
The form Geometry Managerp. 61
Geometry Management Summaryp. 70
Fontsp. 71
Experimenting with Fontsp. 71
Dissecting a Fontp. 73
Using Fontsp. 74
Using Fonts Dynamicallyp. 76
Font Manipulation Methodsp. 77
Button, Checkbutton, and Radiobutton Widgetsp. 81
Creating Button Widgetsp. 83
Standard Options for Each Button Typep. 83
Table of Options for Button-Type Widgetsp. 84
Displaying Text on Buttonsp. 87
Displaying an Image or Bitmapp. 88
Checkbutton and Radiobutton Indicator Statusp. 90
On and Off Values for a Checkbuttonp. 92
Radiobutton Valuesp. 92
The -command Optionp. 93
Disabling a Buttonp. 95
Text Manipulationp. 97
Altering the Button's Stylep. 99
Changing the Size of a Buttonp. 101
Adding a Keyboard Mappingp. 103
Color Optionsp. 104
Indicator Colorsp. 106
Hiding the Indicatorp. 106
Focus Optionsp. 107
Altering the Highlight Rectanglep. 107
Configuring a Buttonp. 108
Flashing the Buttonp. 109
Invoking the Buttonp. 110
Turning a Checkbutton/Radiobutton On and Offp. 110
Label and Entry Widgetsp. 111
The Label Widgetp. 111
The Entry Widgetp. 117
The Perl/Tk LabEntry Mega-Widgetp. 132
The Scrollbar Widgetp. 133
Defining Scrollbar Partsp. 133
The Scrolled Methodp. 135
The Scrollbar Widgetp. 137
Examplesp. 145
The Listbox Widgetp. 149
Creating and Filling a Listboxp. 150
Listbox Optionsp. 150
Selection Modesp. 152
Colorsp. 153
Listbox Stylep. 153
Configuring a Listboxp. 154
Inserting Itemsp. 155
Deleting Itemsp. 155
Retrieving Elementsp. 156
Selection Methodsp. 156
Moving to a Specific Indexp. 157
Translating Indexesp. 158
Counting Itemsp. 158
Active Versus Selectedp. 158
Bounding Boxp. 158
Finding an Index by y Coordinatep. 159
Scrolling Methodsp. 159
Listbox Virtual Eventsp. 159
Listbox Examplep. 160
The Text, TextUndo, and ROText Widgetsp. 162
Creating and Using a Text Widgetp. 162
Text Widget Optionsp. 163
A Short Break for a Simple Examplep. 168
Text Indexesp. 169
Text Tagsp. 171
Inserting Textp. 179
Deleting Textp. 180
Retrieving Textp. 181
Translating Index Valuesp. 181
Comparing Index Valuesp. 181
Showing an Indexp. 182
Getting the Size of a Characterp. 182
Getting Line Informationp. 182
Searching the Contents of a Text Widgetp. 182
Scrollingp. 183
Marksp. 183
Embedding Widgetsp. 185
Internal Debug Flagp. 187
The Perl/Tk Text Widget Extended Methodsp. 188
The TextUndo Widgetp. 191
The ROText Widgetp. 193
The Canvas Widgetp. 194
Creating a Canvasp. 194
The Canvas Coordinate Systemp. 195
The Scrollable Regionp. 196
Using bind with a Canvasp. 196
Canvas Optionsp. 197
Creating Items in a Canvasp. 201
Configuring the Canvas Widgetp. 213
Configuring Items in the Canvas Widgetp. 213
Tagsp. 214
Retrieving Bounding Box Coordinatesp. 216
Translating Coordinatesp. 217
Moving Items Aroundp. 217
Changing the Display Listp. 218
Deleting Itemsp. 218
Deleting Tagsp. 218
Determining Item Typep. 219
Setting Keyboard Focusp. 219
Rendering the Canvas as PostScriptp. 219
Scaling the Canvasp. 220
Scanningp. 221
A Drawing Program Examplep. 221
The Scale Widgetp. 224
Creating a Scalep. 224
Assigning a Callbackp. 227
Orientationp. 227
Minimum and Maximum Valuesp. 227
Displayed Versus Stored Valuep. 227
Adding a Labelp. 228
Displaying Value Incrementsp. 228
Changing the Size of the Scalep. 229
Options You'll Probably Never Needp. 229
Configuring a Scalep. 229
Getting the Value of a Scalep. 230
Setting the Value of a Scalep. 230
Determining Coordinatesp. 230
Identifying Parts of a Scalep. 230
Frame, MainWindow, and Toplevel Widgetsp. 231
Creating a Framep. 232
Creating a Toplevel Widgetp. 233
Optionsp. 233
Frame Methodsp. 238
Toplevel Methodsp. 238
Creating Multiple Main Windowsp. 247
Putting Two Main Windows to Workp. 249
The Menu Systemp. 253
Menu System Componentsp. 253
Menubars and Pulldown Menusp. 259
The Win32 System Menu Itemp. 266
Classical Menubarsp. 266
Popup Menusp. 270
Option Menusp. 275
Menu Virtual Eventsp. 279
Pie Menusp. 279
Miscellaneous Perl/Tk Methodsp. 284
Managing Widgets with configure and cgetp. 284
Building a Family Treep. 287
Widget's IDp. 288
Color-Related Methodsp. 289
The Application's Namep. 290
Widget Existencep. 290
Is the Widget Mapped?p. 291
Converting Screen Distancesp. 291
Size of Widgetp. 291
Widget Positionp. 292
Screen Informationp. 294
Atom Methodsp. 296
Ringing a Bellp. 296
Clipboard and Selection Methodsp. 296
Destroying a Widgetp. 299
Focus Methodsp. 299
Grab Methodsp. 302
Marking a Widget Busy and Unbusyp. 302
Widget Mapping and Layeringp. 303
Interapplication Communicationp. 304
Waiting for Events to Happenp. 304
Time Delaysp. 305
Parsing Command-Line Optionsp. 306
Really Miscellaneous Methodsp. 306
Creating Custom Widgets in Pure Perl/Tkp. 308
A Mega-Widget Quick-Startp. 308
The Perl/Tk Class Hierarchyp. 316
Mega-Widget Implementation Detailsp. 319
Composite Mega-Widgetsp. 330
Derived Mega-Widgetsp. 335
Packaging a Mega-Widget for Public Distributionp. 351
Anatomy of the MainLoopp. 356
Creating a Callbackp. 358
Binding to Eventsp. 361
The bindtags Commandp. 372
Executing Nonblocking System Commandsp. 378
Tracing Perl/Tk Variablesp. 388
Nonblocking Wait Activitiesp. 391
Splash Screensp. 394
Synthesizing Virtual Eventsp. 399
Coexisting with Other GUI Main Loopsp. 401
User Customizationp. 406
Using the Command Linep. 407
Using the Option Databasep. 410
Images and Animationsp. 417
An Overview of Perl/Tk Image Typesp. 417
Methods Common to All Image Typesp. 419
Bitmap Primitivesp. 420
DefineBitmapp. 422
The Bitmap Image Typep. 422
The Pixmap Image Typep. 426
The Photo Image Typep. 427
The Compound Image Typep. 439
Tk::Animationp. 440
tkneko--Animating the Neko on a Canvasp. 441
Tile and Transparent Imagesp. 444
Miscellaneous Image Methodsp. 447
Simple Photo Rotationsp. 447
A Tk Interface Extension Tourp. 451
Display Itemsp. 452
Item Stylesp. 454
The TList Widgetp. 457
The HList Family of Widgetsp. 459
Tix Imagesp. 471
Interprocess Communication with Pipes and Socketsp. 472
Handling Unsolicited Media Changesp. 473
IPADM Design Considerationsp. 476
The Perl/Tk IPADM Client, ipadmp. 478
The IPADM Helper, ipadmhp. 486
The IPADM Daemon, ipadmdp. 487
Polling Win32 Socketsp. 492
IPC with sendp. 494
Security and Inter-Language Considerationsp. 494
Computing [pi] with Parallel Message Passingp. 497
TclRobotsp. 503
C Widget Internalsp. 510
The Tk::Square Widgetp. 510
Interfacing tkSquare.c with Perl/Tkp. 523
Building and Testing Tk::Squarep. 528
How Not to Port Tk::Squarep. 529
Perl/Tk and the Webp. 531
Library for WWW Access in Perlp. 531
The PerlPlus Browser Plug-inp. 554
Plethora of pTk Potpourrip. 558
pTk Special Variables and Exporter Symbolsp. 558
Manipulating the Cursorp. 560
Dialog Boxesp. 563
The Adjuster Widgetp. 569
The Balloon Widgetp. 571
The BrowseEntry Widgetp. 572
The LabFrame Widgetp. 575
The NoteBook Widgetp. 576
The Pane Widgetp. 580
The ProgressBar Widgetp. 581
Widgets Not in the Perl/Tk Distributionp. 583
Installing Perl/Tkp. 585
Options and Default Values for Each Widgetp. 587
Complete Program Listingsp. 646
Indexp. 717
Table of Contents provided by Syndetics. All Rights Reserved.

An electronic version of this book is available through VitalSource.

This book is viewable on PC, Mac, iPhone, iPad, iPod Touch, and most smartphones.

By purchasing, you will be able to view this book online, as well as download it, for the chosen number of days.

Digital License

You are licensing a digital product for a set duration. Durations are set forth in the product description, with "Lifetime" typically meaning five (5) years of online access and permanent download to a supported device. All licenses are non-transferable.

More details can be found here.

A downloadable version of this book is available through the eCampus Reader or compatible Adobe readers.

Applications are available on iOS, Android, PC, Mac, and Windows Mobile platforms.

Please view the compatibility matrix prior to purchase.