# Beginning Mac Programming 2001 — source transcripts, page 1

[Canonical transcript page](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/1)

## Transcribed source material

Machine transcriptions and image descriptions; uncertain copy may be marked [illegible]. Verify against the linked originals. Historical rights remain with the original owners.

These are transcribed excerpts, not the full publications. Open the originals for remaining pages.

### Image 1

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/1#scan-05fd390cfc9eb646e61b04ed5f60cc78a408882725272175ab9a4817580f963e)

Beginning Mac PROGRAMMING

Transcribed text:

Beginning Mac® Programming

For Classic Mac® OS and Mac® OS X

Kevin Spencer and Jeff Thompson

CD Included

Premier Press

Image description: A glowing green power button sits above large orange-red serif title text, with the word PROGRAMMING spelled across black keyboard keys, a Premier Press logo at lower left, and a CD graphic at lower right on a white cover.

Reading notes: The title is split across lines as 'Beginning' and 'Mac' with 'PROGRAMMING' on black keys; reading order follows the visual layout. The CD label text is very small and only partially legible; it appears to read 'Beginning Mac Programming' with additional fine print that is illegible. The small fine print on the CD and the lower-left logo area was not fully legible.

Printed product names: Beginning Mac Programming · Classic Mac OS · Mac OS X

Languages: English

[Original Image 1](https://www.vintageapple.net/files/4dd8a0a3aa894f74f20f5d115174ac9baddef79a545fd44f9506909ed9c8c605/e428258d490c45ac2a1159e6.webp)

### PDF page 1

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/1#scan-00cf6c417dce6052bdb3438d8b35b543e55a0454c57986063e065baeb4a05974)

Transcribed text:

1111111111111111   1111
For   Classic Mac® OS   and   Mac® OS   X
Premier
P r e s s   KEVIN   SPENCER   AND JEFF   THOMPSON   CD Included

Reading notes: No image was supplied, so layout, reading order and visual hierarchy are unverified. No headline is clearly identifiable; 'Premier' may be a headline or a product name but this is uncertain. The leading line of repeated '1' characters may be a scan artifact or a non-textual element rather than printed copy. 'Classic Mac® OS' and 'Mac® OS X' are platform references and were not treated as advertised products. 'Premier Press', 'KEVIN SPENCER AND JEFF THOMPSON' and 'CD Included' are not treated as products or prices because their advertising role is unclear.

Languages: English

[Original PDF page 1](https://www.vintageapple.net/files/53371a6aca13e0b71f95f4e762e8dffacf7730d9d0b85b23b5bcece63e43c8b0/Beginning_Mac_Programming_2001.pdf#page=1)

### PDF page 2

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/1#scan-5a9e00839d40b4ef285435bec120b1059c28e28486f3b8247926aebb184701e9)

Beginning Mac Programming

Transcribed text:

Beginning
Mac
PROGRAMMING
For Classic Mac OS and Mac OS X

Image description: A book-cover style title page on a striped background, with 'Beginning' in dark serif type above a large metallic 'Mac' and a row of dark keyboard-style keys spelling PROGRAMMING, with a subtitle beneath.

Reading notes: Letters on the keyboard-key graphics are stylized and faint, read as PROGRAMMING from key shapes; the spacing of the key letters is approximate.

Languages: English

[Original PDF page 2](https://www.vintageapple.net/files/53371a6aca13e0b71f95f4e762e8dffacf7730d9d0b85b23b5bcece63e43c8b0/Beginning_Mac_Programming_2001.pdf#page=2)

### PDF page 3

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/1#scan-a350dd6ae43772e49d285d52be9c1724f3a5a91b9a66338f02aed8f87fe67d0a)

Image description: A plain blank white page with no artwork, layout elements, or printed content visible.

Reading notes: The image appears entirely blank white with no visible text, so no transcription or fields could be extracted.

[Original PDF page 3](https://www.vintageapple.net/files/53371a6aca13e0b71f95f4e762e8dffacf7730d9d0b85b23b5bcece63e43c8b0/Beginning_Mac_Programming_2001.pdf#page=3)

### PDF page 4

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/1#scan-365b76e9e1dbe22341af5a96a5a3b06cf4a0b0ba1cbcc4afad793478663e4a15)

Beginning Mac

Transcribed text:

Beginning
Mac
PROGRAMMING
For Classic Mac OS and Mac OS X
KEVIN SPENCER AND JEFF THOMPSON
Premier
Press

Image description: Book title page with a large serif title 'Beginning Mac' in gray, keyboard-key style tiles spelling 'PROGRAMMING' across the middle, a subtitle line, author names in small caps, and a Premier Press logo at the bottom over a faint striped background.

Reading notes: Faint background text and ruled stripes behind the title are not transcribed; the keyboard tiles are partially shaded so letters are lightly rendered but read as P R O G R A M M I N G.

Languages: English

[Original PDF page 4](https://www.vintageapple.net/files/53371a6aca13e0b71f95f4e762e8dffacf7730d9d0b85b23b5bcece63e43c8b0/Beginning_Mac_Programming_2001.pdf#page=4)

### PDF page 5

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/1#scan-9793eaecdebe4a113654f153747272adee300f7d2a5a79540327e1602eb02846)

Transcribed text:

©   2001   by Premier   Press,   Inc. All rights reserved. No part of this book may be reproduced or transmitted in any
form or by any means, electronic or mechanical, including photocopying, recording, or by any information storage or
retrieval system without written permission from Premier Press, Inc., except for the inclusion of brief quotations ina
review.
I P r e s s   Premier Press is a registered trademark of Premier Press, Inc.
Publisher:   Stacy   L. Hiquet
Associate Marketing Manager: Heather Buzzingham
Managing Editor:   Sandy   Doell
Acquisitions Editors: Jawahara K. Saidullah, Kevin Harreld
Project   Editor: Brian Thomasson
Technical Editors: Geoff Perlman, Dan P.   Sydow
Copy Editor: Kate Welsh
Interior Layout: Marian Hartsough
Cover Design: Mike Tanamachi
Indexer: Katherine   Stimson
Apple, Apple   logo,,A,pple)Y<;>tks,Balloon   Help, Charcoal,   Chicag9,   Claiis)Y9rks,   <::;olorSync,   EictensionsManager,
Finder, iMac, ImageWriter, iMovie,   "keyboard"   Apple logo, LaserWriter, LocalTalk, Mac, Macintosh, Mac   logo,
"Moof"   and Dogcowlogo, QuickTime, Sherlock, Think different, TrueType,VideoSync, ViewEdit, are trademarks
or registered traderriarks of Apple Computer, Inc.   "AOL"   and the   AOL   triangle   logo   are registered trademarks of
America   Online,   Inc. All rights reserved. EarthLink and EarthLink logo are trademarks of EarthLink Network, Inc.
Internet Explorer logo, Microsoft, Outlook, are trademarks or registered trademarks of   Microsoft Corporation.
Netscape and Netscape Navigator are trademarks orregistered trademarks of Netscape Communications Corpora-
tion. Quicken is a registered trademark oflntuit, Inc. Acrobat, the Acrobat logo, Adobe, and the Adobe logo are
trademarks or registered trademarks of Adobe Systems, Inc.   Stuffit   and   Stuffit   Expander are trademarks or registered
trademarks of Aladdin Systems, Inc. REALbasic isa copyright of REAL Software, Inc. All tights reserved.
Important: Ifyou have problems running REALbasic, go to REAL Software's Web site at
http://www.realsott\Vare.com.   Premier Press, Inc. cannot provide software support.
Premier   Press,   Inc. and the author have attempted throughout this book to distinguish proprietary trademarks from
descriptive terms by following the capitalization style used by the manufacturer.
Information contained in this book has been obtained by Premier Press, Inc. from sources believed to be reliable.
However, because of the possibility of human or mechanical error by our sources, Premier Press, Inc., or others, the
Publisher does not guarantee the accuracy, adequacy, or completeness of any information and is not   i:esponsil:ili:   for
any errors or omissions or the results obtained   from   use of such information. Readers should be particularly   aware   of
the fact that the Internet is an ever-changing entity.   Some   facts may have changed since this bookwentto press.
ISBN:   1-931841-00-4
Library of Congress· Catalog Card Number:   00-110736
Printed in the   United   States   of America
00   01   02   03   04   II   10   9 8 7 6   5   4 3 2 1

Reading notes: Some trademark list text is garbled by OCR-like character errors (e.g., 'Claiis)Y9rks', 'Chicag9', 'Dogcowlogo'), so product names may be imperfectly spelled. Reading order of the publisher and trademark sections is uncertain and may be disordered.

Printed product names: REALbasic · Apple · Acrobat · Stuffit · Stuffit Expander · Quicken · Netscape Navigator · Internet Explorer · Outlook · Sherlock · QuickTime · iMovie · iMac · LaserWriter · LocalTalk · TrueType · ImageWriter · Macintosh · EarthLink · Mac

Printed dates: 2001 · 00 · 00-110736 · 1-931841-00-4

Languages: English

[Original PDF page 5](https://www.vintageapple.net/files/53371a6aca13e0b71f95f4e762e8dffacf7730d9d0b85b23b5bcece63e43c8b0/Beginning_Mac_Programming_2001.pdf#page=5)

### PDF page 6

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/1#scan-788d29f89dbfb0fa152687a04faacef8fb5ef9fab382adc477ebd0f4e25cd024)

Transcribed text:

Acknowledgments
A ll my thanks go to my co-author, Jeff, who spearheaded the code writ- ing for this book.   Your   dedication is a rare find. Many thanks also to
Brian, Kate, Kevin H, and the crew at Premier   Press,   Inc., who provided a
solid base in times of trouble. Many thanks to Geoff Perlman and the folks at
REAL Software for their excellent help with technical corrections and sug-
gestions. A special thanks to Marta Justak, for her guidance. And a very spe-
cial thank you to my wife, Rebecca, who suffered for agonizing hours as she
watched over   150   satellite television channels while I worked.
-KS
My thanks go out to those that Kevin has already thanked, along with thanks
to Kevin as well.   Your   experiences and talents as a writer, not to mention your
assistance along the way, are much appreciated.   Special   thanks go to my High
School   computer-programming instructor, G. Ross Buckman, for convincing
me that a career in computer programming is right where I belong. Very spe-
cial thanks go to my wife, Kathie, and my children, Neil and Samantha, for
their encouragement and patience. Lastly I'm sure Kevin would like to join me
in thanking   all   of our friends, whose support was very important to us.
-JT

Languages: English

[Original PDF page 6](https://www.vintageapple.net/files/53371a6aca13e0b71f95f4e762e8dffacf7730d9d0b85b23b5bcece63e43c8b0/Beginning_Mac_Programming_2001.pdf#page=6)

### PDF page 7

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/1#scan-a945c6eb7499c5ebe2186b8e7c51cccd0d49f61bc6fdf8295282f9c8860cb868)

Transcribed text:

·About   th.e   Authors
KEVIN   SPENCER is a certified Apple Service Technician, computer hobbyist,
and writer. Kevin has worked with some of the earliest personal computers of
the late 1970's and still thinks the   BASIC   computer language was a pretty
nifty idea. When not bicycling or wading in weeds while working in the yard,
he spends his time with his wife, two sons, and two computer-illiterate cats in
Indianapolis.

Reading notes: Heading reads 'About the Authors' with spacing irregularities; treated as no primary headline.

Printed product names: Apple

Printed dates: 1970's

Languages: English

[Original PDF page 7](https://www.vintageapple.net/files/53371a6aca13e0b71f95f4e762e8dffacf7730d9d0b85b23b5bcece63e43c8b0/Beginning_Mac_Programming_2001.pdf#page=7)

### PDF page 8

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/1#scan-c520a1f80c5fdf175f7d33a92ca54a35e7d9f881ca42bb67ef90483261bb7034)

Transcribed text:

Working as a software developer since 1985, JEFF   THOMPSON   has written
applications in various languages such as BASIC,   Z-80   Assembler,   6502
Assembler, DBL,   8088   Assembler, C and C++. Jeff worked with and devel-
oped applications on various platforms from the good old days of the   TRS-
80,   Apple II, DEC minicomputers, IBM PC's, and the Macintosh Plus   all
the way up to today's latest Pentium PC's and Macintosh PowerPC systems.
Jeff's computer career also includes a couple of years work as a computer
technician, salesman and a short stint where he taught classes on the BASIC
programming language. Jeff also had a passing acquaintance with HTML,
Java, and Perl. Jeff has developed a wide variety of applications including,
payroll, accounting, shareware entertainment, billing systems, and billing
analysis tools. He's currently employed by CTI Billing Solutions as Senior
Software Engineer and Technical Lead on one of the highest rated billing
analysis software applications in the country. Jeff is currently listed as an
inventor on a software patent used in CTI Billing Solutions' billing analysis
software, Smart   Bill™.   The patent is also licensed for use by more than half
of the long distance and local telephone carriers in the   United   States. Jeff cur-
rently resides in Indianapolis, Indiana with his wife, two children, two dogs,
four cats and an indeterminate number of ducks which have taken up perma-
nent residence in his pond. He also has an ever-increasing collection of Mac-
intosh computers, which require a lot less care and feeding than the other
members of his family.

Reading notes: The source text has irregular spacing around some names and product labels, possibly from extraction.

Printed product names: Smart Bill™

Printed dates: 1985

Languages: English

[Original PDF page 8](https://www.vintageapple.net/files/53371a6aca13e0b71f95f4e762e8dffacf7730d9d0b85b23b5bcece63e43c8b0/Beginning_Mac_Programming_2001.pdf#page=8)

### PDF page 9

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/1#scan-baa1ac25817681287fbcb03a917abbc0d28332df6a2e96f50680480201759861)

Transcribed text:

Contents at a Glance
Part   I
Getting Your Feet Wet   1
Chapter 1   Getting Acquainted with REALbasic   3
Chapter   2   Programming's Big Picture   19
Chapter 3   The Parts of a Mac Program   31
Chapter 4   Under   Your   Command   39
Chapter 5   Variables, Operations, and Constants   49
Chapter 6   Making   Your   Program Flow   61
Chapter   7   And   Still   More on Program Flow   79
Chapters   Subroutines, Functions, and Recursion   89
Chapter   9   Object-Oriented   Programming   101
Part   II
Developing   Your First Mac Program   117
Chapter 10   Making My Paint   119
Chapter 11   Adding   Simple   Drawing Commands   127
Chapter 12   Adding More Drawing Commands   141
Chapter 13   File Operations   169
Chapter 14   Editing Operations   191
Chapter 15   Tool Palettes and Cursors   219
Chapter 16   Finishing Touches   227

Reading notes: Some words in the table of contents are split by irregular spacing (e.g., 'Part   I', 'Chapters   Subroutines'), which may affect reading order.

Printed product names: REALbasic

Languages: English

[Original PDF page 9](https://www.vintageapple.net/files/53371a6aca13e0b71f95f4e762e8dffacf7730d9d0b85b23b5bcece63e43c8b0/Beginning_Mac_Programming_2001.pdf#page=9)

### PDF page 10

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/1#scan-79be1ea5f851bc9bd40208f72534543260265ab1c3e7f581d9927a41ddf99429)

The Age of Mac OS X

Transcribed text:

Part   Ill
The Age of Mac   OS   X   245
Chapter 17
Chapter 18
Chapter   19
Chapter   20
Chapter 21
Part   IV
Enter the World of Aqua   247
The Classic Environment   265
The Carbon Environment   279
The Cocoa Environment   289
UNIX:   AShell Surrounding a Tasty Kernel
Advanced Things to Do   315
299
Chapter 22
Chapter 23
Porting Applications to Microsoft Windows   317
AWord about Advanced Programming   333
Part   V
Appendixes 349
Appendix   A
AppendixB
REALbasic Resources
How to   Use   the   CD-ROM
Index   361
350
357

Languages: English

[Original PDF page 10](https://www.vintageapple.net/files/53371a6aca13e0b71f95f4e762e8dffacf7730d9d0b85b23b5bcece63e43c8b0/Beginning_Mac_Programming_2001.pdf#page=10)

### PDF page 11

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/1#scan-4f9bd9d208d40dabac9e4e9233879ccb7ea822245c12ae9de0ea5bd0fb83312c)

Transcribed text:

Contents
Part   I
Getting   Your   Feet Wet   1
Chapter 1   Getting Acquainted with REALbasic   3
What's on the CD-ROM   4
Installing REALbasic   7
What REALbasic Looks Like   8
Making Your First Application   9
Chapter   2   Programming's Big   Picture   19
The   Phases   of   Programming   20
Defining Requirements   22
Design   22
Programming   23
Testing and Debugging   24
Implementation   24
Releasing a Retail Product   25
Releasing a Shareware Product   25
Releasing Freeware   26
Releasing an Open-Source Program   26
Support   27
Sprecken sie   REALbasic?   27
Review   29

Reading notes: The phrase 'Sprecken sie REALbasic?' contains a German-style fragment whose intended spelling may be uncertain.

Printed product names: REALbasic

Languages: English

[Original PDF page 11](https://www.vintageapple.net/files/53371a6aca13e0b71f95f4e762e8dffacf7730d9d0b85b23b5bcece63e43c8b0/Beginning_Mac_Programming_2001.pdf#page=11)

[Next transcribed scans](https://www.vintageapple.net/transcripts/media/va-beginning-mac-programming-2001-dd1496/2.md)
