# develop-15 9309 September 1993 — source transcripts, page 1

[Canonical transcript page](https://www.vintageapple.net/transcripts/media/va-develop-15-9309-september-1993-16659a/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-develop-15-9309-september-1993-16659a/1#scan-3ead3d3eb85e12316177a870e055f8b1c18fcf624f5a56da3c5366726b5f4712)

Transcribed text:

develop
The Apple Technical Journal

GETTING STARTED WITH QUICKDRAW GX

DEVELOPING QUICKDRAW GX PRINTING EXTENSIONS

QUICKDRAW GX FOR POSTSCRIPT PROGRAMMERS

MANAGING COMPONENT REGISTRATION

DYNAMIC CUSTOMIZATION OF COMPONENTS

FLOATING WINDOWS: KEEPING AFLOAT IN THE WINDOW MANAGER

WORKING IN THE THIRD DIMENSION

KON & BAL'S PUZZLE PAGE

MACINTOSH Q & A

Issue 15 September 1993

Image description: A magazine cover with a colorful collage of a stylized script GX letterform, green paisley shapes, magenta and blue triangles, and an autumn foliage photo, with a column of article titles on the right and an Apple logo above the issue line.

Reading notes: The 'develop' masthead and subtitle 'The Apple Technical Journal' are stylized and spaced; spacing of the subtitle letters is approximate. Article titles are listed in a right-hand column and read top to bottom in that order.

Printed dates: September 1993

Languages: English

[Original Image 1](https://www.vintageapple.net/files/afc54abc64c31bca3b42d135766a077d2fe9341d170650baf2e11c2b044df849/db758e8f71f58430f7ab3bcd.webp)

### PDF page 1

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-develop-15-9309-september-1993-16659a/1#scan-3e15d96a9587a89dd76df65bd0256a8399b645c9703abaa0af3223b4cb30bf4c)

Transcribed text:

develop
The Apple Technical Journal
GETTING STARTED WITH QUICKDRAW GX
DEVELOPING QUICKDRAW GX PRINTING EXTENSIONS
QUICKDRAW GX FOR POSTSCRIPT PROGRAMMERS
MANAGING COMPONENT REGISTRATION
DYNAMIC CUSTOMIZATION OF COMPONENTS
FLOATING WINDOWS: KEEPING AFLOAT IN THE WINDOW MANAGER
WORKING IN THE THIRD DIMENSION
KON & BAL'S PUZZLE PAGE
MACINTOSH Q & A
Issue 15 September 1993

Image description: The magazine cover shows a colorful collage of a stylized script "QG" monogram in teal and green on a dark panel, with yellow dotted stitching, paisley shapes, a magenta triangle, and autumn foliage letterforms over a blue background, with a list of article titles down the right side and an Apple logo at the bottom.

Reading notes: The masthead 'develop' is in a stylized wide-spaced typeface and the tagline 'The Apple Technical Journal' is small and spaced out; spacing may be approximate. Several article titles in the right column are grey-shaded or faded, so exact rendering of some lines is slightly uncertain. The large script letters on the artwork are decorative and were not transcribed as text.

Printed product names: develop · The Apple Technical Journal

Printed dates: September 1993

Languages: English

[Original PDF page 1](https://www.vintageapple.net/files/3ceb0e843cd5bd3641e15cf58b3ea4e52ed4e850e000fd23aaf0eb7055319430/develop-15_9309_September_1993.pdf#page=1)

### PDF page 2

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-develop-15-9309-september-1993-16659a/1#scan-1136f03adeb3477857370c4610123dfff6bc9c7677beb51b89e13a7fbbe61be8)

Transcribed text:

E D I T O R I A L   S T A F F
Editor-in-Cheek   Caroline Rose
Technical Buckstopper   Dave Johnson
Our Boss   Greg Joswiak
His Boss   Dennis Matthews
Review Board   Pete (“Luke”) Alexander, Neil Day,
C. K. Haun, Jim Reekes, Bryan K. (“Beaker”)
Ressler, Larry Rosenstein, Andy Shebanow,
Gregg Williams
Managing Editor   Cynthia Jasper
Contributing Editors   Lorraine Anderson, Philip
Borenstein, Robin Cowan, Toni Haskell, Judy
Helfand, Rebecca Pepper, Rilla Reynolds
Indexer   Ira Kleinberg
A R T   &   P R O D U C T I O N
Production/Art Director   Diane Wilcox
Technical Illustration   Dave Olmos, John Ryan
Formatting   Forbes Mill Press
Printing   Wolfer Printing Company, Inc.
Film Preparation   Aptos Post, Inc.
Production   PrePress Assembly
Photography   Sharon Beals
Online Production   Cassi Carpenter
develop, The Apple Technical Journal,   a
quarterly publication of Apple Computer’s
Developer Press group, is published in
March, June, September, and December.
Lindsay Marshall of Rucker Huggins
illustrated several QuickDraw GX features
for this cover. The three   g ’s are from the
“GX-ready” typeface, Columbine,
developed by David Siegel.
The   develop Bookmark   CD (or the
Developer CD Series   disc, Reference
Library edition) for September 1993 or
later contains this issue and all back issues
of   develop   along with the code that the
articles describe. The   develop   issues and
code are also available on AppleLink and
via anonymous ftp on ftp.apple.com.

Reading notes: No printed headline is evident in the supplied copy, so headline is null. Column and line layout is inferred from the supplied text, including the two-column staff listings, and may not match the printed reading order exactly. Quoted nicknames and typeface names ("Luke", "Beaker", "GX-ready", Columbine) are preserved as they appear in the supplied copy. Printed months are listed as March, June, September, and December; only September 1993 is a complete date with a year.

Printed product names: develop, The Apple Technical Journal · develop Bookmark CD · Developer CD Series

Printed dates: September 1993 · March, June, September, and December

Languages: English

[Original PDF page 2](https://www.vintageapple.net/files/3ceb0e843cd5bd3641e15cf58b3ea4e52ed4e850e000fd23aaf0eb7055319430/develop-15_9309_September_1993.pdf#page=2)

### PDF page 3

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-develop-15-9309-september-1993-16659a/1#scan-42a897824b38aec117f631f707f6b3e0b7b69cab950b4e20aa30289dc083c319)

Transcribed text:

CONTENTS   September 1993
1
© 1993 Apple Computer, Inc. All rights reserved.
Apple, the Apple logo, APDA, AppleLink, AppleShare, AppleTalk, ImageWriter, LaserWriter, LocalTalk, MacApp,
Macintosh, MPW, and MultiFinder are trademarks of Apple Computer, Inc., registered in the U.S. and other countries.
AppleScript, ColorSync, develop, Finder, KanjiTalk, Macintosh Quadra, MoviePlayer, QuickDraw, QuickTime, Sound
Manager, System 7, TrueType, and WorldScript are trademarks of Apple Computer, Inc. HyperCard, HyperTalk, and
MacDraw are registered trademarks of Claris Corporation. PostScript is a trademark of Adobe Systems Incorporated,
which may be registered in certain jurisdictions. Helvetica is a registered trademark of Linotype Company. UNIX is a
registered trademark of UNIX System Laboratories, Inc. All other trademarks are the property of their respective
owners.
Another award for   develop ! And changes made at your request.   2
Letters from you, plus more from us on asynchronous routines.   3
Getting Started With QuickDraw GX   by Pete (“Luke”) Alexander
A brief introduction to QuickDraw GX, and a simple GX-aware sample.   6
Developing QuickDraw GX Printing Extensions   by Sam Weiss   All
about these nifty new add-ons to QuickDraw GX printing.   34
QuickDraw GX for PostScript Programmers   by Daniel Lipton   The two
graphics models are compared, along with useful code snippets for each.   51
Managing Component Registration   by Gary Woodcock   For those cases
where you may need to manage the component registration process, here’s how.   74
Floating Windows: Keeping Afloat in the Window Manager   by
Dean Yu   A way to implement floating windows without patching traps, and a
library you can use in your own application.   89
Working in the Third Dimension   by Jamie Osborne and Deanna Thomas
This article shows off a nice 3-D interface and presents a set of MacApp objects you
can use to create your own such interface.   103
The Veteran Neophyte: Through the Looking Glass   by Dave Johnson
Dave explores the mathematics of symmetry and finds some surprises.   71
Somewhere in QuickTime: Dynamic Customization of Components
by Bill Guschwan   A sample derived media handler that “speaks” the text track in
a movie.   84
View From the Ledge   by Tao Jones   An office survival guide for the socially
and politically inept.   115
KON & BAL’s Puzzle Page: I’m Here to Serve   by Konstantin Othmer
and Bruce Leak   Try your skill (or is it luck?) on yet another puzzle from those
masters of Macintosh machinations, KON and BAL.   132
Macintosh Q & A   Apple’s Developer Support Center answers your product
development questions.   117
137 I N D E X
Q   &   A
C O L U M N S
A R T I C L E S
L E T T E R S
E D I T O R I A L

Reading notes: Table of contents entries are listed in non-sequential page order, so reading order may not match page sequence.

Printed product names: develop · QuickDraw GX · QuickDraw GX printing extensions · Macintosh · MacApp · QuickTime · HyperCard · HyperTalk · MacDraw · PostScript · AppleScript · ColorSync · MoviePlayer · QuickDraw · Sound Manager · System 7 · TrueType · WorldScript · AppleShare · AppleTalk · ImageWriter · LaserWriter · LocalTalk · MultiFinder · MPW · KanjiTalk · Macintosh Quadra · Finder · APDA · AppleLink · Helvetica · UNIX

Printed dates: September 1993 · © 1993

Languages: English

[Original PDF page 3](https://www.vintageapple.net/files/3ceb0e843cd5bd3641e15cf58b3ea4e52ed4e850e000fd23aaf0eb7055319430/develop-15_9309_September_1993.pdf#page=3)

### PDF page 4

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-develop-15-9309-september-1993-16659a/1#scan-7005c80e386d16b4bc3b8f6369899bd6c29e75f358d361118423cda86919ec29)

Transcribed text:

Dear Readers,
develop   does it again! We’re thrilled to announce that we’ve won another Excellence
award, this time in the 1993 International Technical Publications Competition,
sponsored by the Society for Technical Communication.
Some things that are worth noting in this issue:
•   We’re very happy to finally have a female author. Welcome to
Deanna Thomas; may she be the first in a long line.
•   We’ve added a strange new column called “View From the Ledge”;
please let us know what you think of this irreverent (or is that
“irrelevant”?) addition.
•   We’re temporarily without a Print Hints or Graphical Truffles
column. But there’s a lot of information about printing and
graphics in our three QuickDraw GX articles.
Finally, here are two changes that have happened as a result of your feedback:
•   Tech Notes are numbered again, this time within each category of
Note. References in   develop   will include the new number after the
category; for example, we might refer you to the Macintosh
Technical Note “Fond of FONDs” (Text 21). With this issue we
finally stop giving the former number of a Tech Note, as in
“(formerly #91)”; those old numbers are long gone.
•   New   Inside Macintosh   is now on the   develop Bookmark   CD. It was
painfully missing from Issue 14’s CD, but we have seen the error of
our ways and have quickly rectified the situation.
Please keep letting us know what you want; it pays!
Caroline Rose
Editor
d e v e l o p   Issue 15
CAROLINE ROSE   (AppleLink CROSE) has
written and edited more technical documentation
than she cares to remember. In past work lives,
she was also a programmer and (gasp!) a
manager. She’s worked for Tymshare, Apple,
NeXT, and Apple, in that order. But no previous
job compares to the variety and fun she enjoys as
editor of
develop. Caroline is still raving about the
great time she had at the Worldwide Developers
Conference in May. We suspect the highlight was
when a developer asked her to sign his copy of
develop — or was it when she took the Karaoke
dare at the WWDC party? Recent delights
outside of work include singing like a wannabe
Bonnie Raitt at jam sessions with her friends and
listening to tapes of John Prine and Richard
Thompson from an incredible music festival she
attended in a mountain meadow.•
2
CAROLINE ROSE

Reading notes: Possible line-break artifacts in 'develop' and 'Caroline Rose' OCR text; the author-bio paragraph has an unclear reading-order boundary between columns.

Printed product names: develop · Inside Macintosh · develop Bookmark · QuickDraw GX · Macintosh Technical Note

Printed dates: 1993 · May · Issue 14 · Issue 15 · #91

Languages: English

[Original PDF page 4](https://www.vintageapple.net/files/3ceb0e843cd5bd3641e15cf58b3ea4e52ed4e850e000fd23aaf0eb7055319430/develop-15_9309_September_1993.pdf#page=4)

### PDF page 5

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-develop-15-9309-september-1993-16659a/1#scan-3b7485d1dc972f83d75227c87e9cf1f8e7e18fb1fc744eca6b131307652d4111)

Transcribed text:

NEW TECH NOTE NUMBERS
In   develop   Issue 14 Peter Fink complains
about the loss of Tech Note numbering.
In your answer you write: “We’re always
open to suggestion, but so far you’re the
only one to mention this. If others
reading this reply have similar feedback,
I hope they’ll let us know.”
Actually, I and others have complained
about the loss of Tech Note numbers
for quite some time, but sometimes
talking about these things is like
complaining about the weather. I
suspect most people just grumble along
and don’t complain in writing.
— Johan G. E. Strandberg
Good news: Numbers are back; see the
editorial on page 2 and the Tech Notes on
this issue’s CD. It’s too bad when people
grumble without writing; the latter is much
more effective, and we really appreciate the
effort. Thanks!
— Caroline Rose
DEBUGGING LESSON FLUB
There seems to be a problem with the
point made in the “Debugging Lesson”
letter in the Letters section of   develop
Issue 14. According to the source listed,
there would be no problem even if
memory moved when FillWithData was
called. Since the handle is being passed
as a handle (that is, not dereferenced),
and handles are 4-byte pointers (which
get pushed onto the stack as is),
FillWithData would always get a valid
handle, which it can dereference
internally to its heart’s content.
Unfortunately, there seems to be a lot of
confusion (and a great deal of paranoia)
over the usage of handles. As long as
you pass handles as handles (and watch
your dereferencing), you’ll be OK.
—Charlie Reading
Um, oops. (Imagine, if you will, me
standing gaping and red-faced, astonished
at my own carelessness and idiocy.)
You’re right, of course; the danger is only in
passing   dereferenced   handles to routines in
other segments, and the code in the letter
passes the handle itself. I guess I just read
the text and didn’t really look closely at the
code before replying. Obviously, it was only
intended as an example, and the writer’s
point is still valid: passing dereferenced
handles to routines in other segments is
dangerous. You should either pass the handle
itself (as the example code did!) or lock the
handle first.
Sorry about the confusion.
—Dave Johnson
BABBLING ON
I enjoyed reading Dave Johnson’s
column in   develop   Issue 13 (“Tower of
Babble”). While reading his discussion
of natural versus programming
languages, I think I was able to put my
finger on what has bugged me about
HyperTalk ®  for years. Natural
languages imply a fluidity of meaning,
giving its users great flexibility for
nuances, emphasis, and brevity.
HyperTalk   looks   like a natural language,
but it possesses none of that fluidity of
meaning. In HyperCard ® , SET has but
one meaning. But in my Oxford
dictionary, “set” has 194 definitions! In
other words, HyperCard looks so much
like English, one winds up assuming
that all kinds of structures could be used
LETTERS   September 1993
3
WE HATE IT WHEN YOU DON’T WRITE
We welcome timely letters to the editors,
especially from readers reacting to articles that
we publish in
develop. Letters should be
addressed to Caroline Rose (or, if technical
develop-related questions, to Dave Johnson) at
Apple Computer, Inc., 20525 Mariani Avenue,
M/S 303-4DP, Cupertino, CA 95014 (AppleLink
CROSE or JOHNSON.DK). All letters should
include your name and company name as well
as your address and phone number. Letters may
be excerpted or edited for clarity (or to make
them say what we wish they did).•
LETTERS

Reading notes: Column header and some running text are split by line breaks; reading order of letters may be ambiguous.

Printed product names: HyperTalk · HyperCard · develop

Printed dates: September 1993 · Issue 14 · Issue 13

Languages: English

[Original PDF page 5](https://www.vintageapple.net/files/3ceb0e843cd5bd3641e15cf58b3ea4e52ed4e850e000fd23aaf0eb7055319430/develop-15_9309_September_1993.pdf#page=5)

### PDF page 6

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-develop-15-9309-september-1993-16659a/1#scan-e21224350c3ed1ccffa1183e34e9e70f96660119ba13c1d5f15ff2b44a4922fa)

Transcribed text:

d e v e l o p   Issue 15
SUBSCRIPTION INFORMATION
Subscriptions to
develop are available through
APDA (see inside back cover for APDA
information), or you can use the subscription
card in the back of this issue. Please address all
subscription-related inquiries to
develop, Apple
Computer, Inc., P.O. Box 531, Mt. Morris, IL
61054 (or AppleLink DEV.SUBS).•
BACK ISSUES
For information about back issues of
develop
and how to obtain them, see the last page of this
issue. Back issues are also on the
develop
Bookmark CD and the
Developer CD Series disc
(Reference Library edition).•
4
as long as they make sense in English
(for example, “set me to true”).
Allow me to submit a suggestion, which
you may wish to pass along to the
software gods. Since Apple has now all
but declared that C and C++ are the
only computer languages the human
race will ever need, maybe it would be
great to have a HyperTalk-to-C
translator. Why? Well, C is a write-only
language (no one ever can figure out
what’s happening in someone else’s C
listing) and HyperTalk is a read-only
language (it’s a cinch to understand,
but impossible to code in). With a
translator, we could write code that still
could be understood, just like when we
used to code in Pascal. (Yes, this is a
joke, from a die-hard Pascal enthusiast.)
Thanks again for a nifty column!
—Kevin Killion
I’m glad you liked the column. Your
comment about HyperTalk is very well
taken! I think that’s what always bothered
me about it, too, though it was just a sort of
vague unease. Unfortunately, I think people
who didn’t learn “regular” programming
languages first may have a distinct
disadvantage: we “real” programmers
know up front how limited and terse and
strict programming languages are, and we
don’t expect anything more. But power
users who learn HyperTalk (or, more likely
now, AppleScript) as their very first
programming language may be in for a
struggle if they don’t keep reminding
themselves that it’s   not   a natural language.
As a die-hard C enthusiast, I’ll graciously
ignore your slams against my favorite
language, and assume that since you’re
obviously an intelligent person, sooner or
later you’ll realize the error of your ways
and come around to the truth, bemoaning
the years you’ve spent in bondage to an
uptight compiler.
—Dave Johnson
ASYNCH SUPPORT ON A/UX
After reading through Jim Luther’s
Asynchronous Routines article in
develop   Issue 13, I spiffed up my
application to make all my file handling
asynchronous, anticipating the glorious
day when all the drivers on my
Macintosh support asynchronous calls.
But since the SCSI Manager isn’t
asynchronous yet, there’s no apparent
difference to the user of my code (or to
me, the hard-working programmer who
wants payoff for my labors).
Is there any platform or configuration I
can test my application on and see the
results of my effort?
—Tony Amaretto
Try your code on A/UX 3.0.1 (the
operating system for the Apple Workgroup
Server 95); it features an enhanced File
Manager that supports asynchronous calls to
UNIX ®   file systems simply by using the
techniques in Jim Luther’s article.
AppleShare Pro takes advantage of this
capability on AWS 95 to get performance
up to four times better than AppleShare
3.0’s under System 7 (your mileage, as
always, will vary).
For more information related to the
Asynchronus Routines article, see the box on
the next page.
Have fun!
—Dave Johnson

Reading notes: Spelling 'Asynchronus' appears in the reference to the Asynchronous Routines article. Sections are joined by reader letters and replies, so reading order follows the column layout.

Printed product names: develop · APDA · Bookmark CD · Developer CD Series · A/UX 3.0.1 · Apple Workgroup Server 95 · AppleShare Pro · AppleShare 3.0 · System 7 · HyperTalk · AppleScript · Pascal · AppleLink DEV.SUBS · Macintosh · SCSI Manager

Printed dates: Issue 15 · Issue 13

Languages: English

[Original PDF page 6](https://www.vintageapple.net/files/3ceb0e843cd5bd3641e15cf58b3ea4e52ed4e850e000fd23aaf0eb7055319430/develop-15_9309_September_1993.pdf#page=6)

### PDF page 7

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-develop-15-9309-september-1993-16659a/1#scan-61ba1b47730e0976d8664fb8acd05895d2e8d8f969adc4b98f9f47d76f1873ff)

Transcribed text:

LETTERS   September 1993
5
Thanks   to François Grieu and Lawrence
D’Oliveiro for providing some of this
information.•
For developers interested in the “Asynchronous Routines
on the Macintosh” article in
develop Issue 13, here’s
some new information that has surfaced since then.
StackSpace.   Contrary to the advice on page 28 of the
article, you should not call StackSpace at interrupt time,
because the Memory Manager might not be in a
consistent state. Furthermore, StackSpace clears MemErr,
which may have an adverse effect on the current
process’s handling of Memory Manager errors.
PPC polling.   Unlike the Device Manager and File
Manager, the PPC Toolbox stuffs the result of an
asynchronous routine into ioResult
before it’s really done
with the parameter block. If your interrupt code — such
as a VBL task — polls ioResult periodically to check for
completion and reuses the parameter block to make
another call, the system can crash because one or more
system queues will be corrupted.
Context switching.   The System 7 Process Manager
(and MultiFinder under System 6) will wait until all
currently active asynchronous requests to the File
Manager have completed before performing a context
switch. This check was added for compatibility reasons to
prevent system crashes caused by a few applications that
accessed program globals within File Manager
completion routines without restoring their A5 world.
What this means to you is that if your application makes
an asynchronous File Manager call and then calls
WaitNextEvent or GetNextEvent, the system may wait for
your call to complete. If the asynchronous File Manager
call takes a long time to complete, it will appear to the
user that the system isn’t responding.
Synchronous drivers.   Although you can execute low-
level file access routines asynchronously, a volume’s
underlying device driver may not support asynchronous
operations. Once the File Manager passes a request to a
synchronous driver, that driver doesn’t give up control
until it has completed the task. Synchronous drivers (such
as those using the current SCSI Manager) affect programs
using asynchronous File Manager calls in two ways:
unexpected pauses and unsightly stack frame buildup.
•   When calling the File Manager asynchronously, your
program passes control to the File Manager and the
request is placed in a queue or, if the queue is empty,
the request is handled immediately. Either way, once a
synchronous driver gets the request, it retains control
until it has responded to the request. If the request
takes a long time to complete, the user may think the
system isn’t responding. If your program is a
background task, these pauses will affect the
performance of the current foreground application. To
keep this to a minimum, avoid time-consuming
asynchronous File Manager requests.
•   Chaining asynchronous File Manager calls will work
on volumes controlled by synchronous drivers, but
watch out: When the driver is synchronous, the stack
frames from the system and your completion routines
will keep building up on the current stack until the last
asynchronous call in the chain completes, or until the
stack overwrites the current heap. You’ll need to break
the asynchronous File Manager call chain every few
completion routines. A simple way to do this is to start
a Time Manager or VBL task from your File Manager
call’s completion routine, and let the task start the next
asynchronous File Manager call in the chain.
File Sharing and AppleShare.   Chained
asynchronous File Manager calls can fail when either the
Macintosh File Sharing or AppleShare 3.0 (not 3.0.1) file
server is running. The file server software intercepts
almost all calls made to the File Manager. Due to how the
file server keeps track of what requests it has or hasn’t
seen, there are a few situations where the file server can
do the wrong thing with chained asynchronous File
Manager calls. To make sure the file server sees and
handles all chained asynchronous File Manager calls
correctly, use two parameter blocks for the chained calls
and switch parameter blocks at every completion routine.
MORE ON ASYNCHRONOUS ROUTINES IN ISSUE 13

Reading notes: Some words are split across lines with hyphenation, so reading order around line breaks may need checking.

Printed product names: StackSpace · MemErr · PPC Toolbox · ioResult · System 7 Process Manager · MultiFinder · System 6 · File Manager · WaitNextEvent · GetNextEvent · SCSI Manager · Macintosh File Sharing · AppleShare 3.0 · Time Manager · VBL task · Device Manager · develop Issue 13

Printed dates: September 1993

Languages: English

[Original PDF page 7](https://www.vintageapple.net/files/3ceb0e843cd5bd3641e15cf58b3ea4e52ed4e850e000fd23aaf0eb7055319430/develop-15_9309_September_1993.pdf#page=7)

### PDF page 8

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-develop-15-9309-september-1993-16659a/1#scan-16f2899bed8328eb7d3635d9fd7d59151212ced1912aa92d630aff12a5a4168f)

GETTING STARTED WITH QUICKDRAW GX

Transcribed text:

A beta version of QuickDraw GX comes to you on this issue’s CD. As
you contemplate the vast scope of it all, you may wonder how you’re
ever going to get your arms around this new imaging technology. Not
to worry — this article will get you started. It walks you through the
steps to getting QuickDraw GX up and drawing and presents a simple
“GX-hip” application shell that incorporates the basics for you to
experiment with.
QuickDraw GX offers developers a totally new and markedly improved way of
imaging on the Macintosh. Yes, you’ll have to learn the new system, but look at what
you get: The API is simpler and the human interface is better. The amount of control
your application can exercise over text and graphics has been greatly increased. Your
application will be able to produce consistent output no matter what the output
device. And extensive support for color is built in throughout the system.
With the beta version of QuickDraw GX in hand, you’re no doubt eager to create a
QuickDraw GX application and start drawing. This article covers just about
everything you need to know to get started: initializing QuickDraw GX, using
windows, creating and manipulating QuickDraw GX shapes, printing, and
debugging. By way of illustration, we discuss the QuickDraw GX shell that you’ll
find on this issue’s CD. But before we do that, let’s take a quick look under the hood
at the major features of QuickDraw GX and how it fits into the Macintosh
architecture.
QUICKDRAW GX: A QUICK LOOK UNDER THE HOOD
QuickDraw GX coexists happily with QuickDraw, thank goodness. It doesn’t replace
QuickDraw, but instead “moves in next door,” so you still live with a Macintosh
Toolbox based on QuickDraw. You can run QuickDraw-based applications on a
QuickDraw GX system. These applications won’t even notice that QuickDraw GX is
installed, but they’ll be able to take advantage of some of the QuickDraw GX
d e v e l o p   Issue 15
PETE (“LUKE”) ALEXANDER   started out as a
meteorology major in college and to this day is
great at forecasting the weather. He’d be happy
to see nothing but blue skies, and in all kinds of
weather he strives to incorporate something blue
in his attire. He loves raw carrots, despises
cooked ones. He hates waiting in lines and
wearing a wristwatch. Sometimes when he’s
driving down the street and spots someone sitting
at a bus stop, he’ll honk his horn to wake them
from their dazed stupor. And when he sees
bicyclists sitting in their bike seats while riding up
hills, he’s been known to yell out the window,
“Stand up, you weenie!”•
6
PETE (“LUKE”) ALEXANDER
GETTING
STARTED
WITH
QUICKDRAW
GX

Reading notes: Page header and author bio text appear interleaved with article body; reading order may be uncertain.

Printed product names: QuickDraw GX · QuickDraw · Macintosh · Macintosh Toolbox

Languages: English

[Original PDF page 8](https://www.vintageapple.net/files/3ceb0e843cd5bd3641e15cf58b3ea4e52ed4e850e000fd23aaf0eb7055319430/develop-15_9309_September_1993.pdf#page=8)

### PDF page 9

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-develop-15-9309-september-1993-16659a/1#scan-f3253e4ed5c66d0353eb7c97bfcd9d10a173aca88aca7b037b4c5579e817ee56)

Transcribed text:

printing features, including improved background printing to all devices, desktop
printers, print job queuing, and better type management.
QuickDraw GX has three major pieces: graphics, typography, and printing. You can
visualize the relationship of these three different pieces to each other and to
QuickDraw as shown in Figure 1.
GRAPHICS
The basic building block of QuickDraw GX graphics is the   shape . A shape is an object
that contains, among other things, a geometry of some type and a fill property that
specifies how the geometry should be interpreted when drawn (such as framed or
filled).
There are four basic types of shapes, classified by the nature of the geometry they
contain: geometric shapes, typographic shapes, bitmap shapes, and pictures.
•   A   geometric shape   contains a primitive geometry: a point, a line, a
curve, a rectangle, a polygon (a series of points connected by
straight lines), or a path (a series of points connected by straight or
curved lines). In addition, there are two other special geometric
shape types: empty (no geometry at all) and full (covers the entire
coordinate system).
•   A   typographic shape   contains text, glyphs (renditions of individual
characters or character combinations over which your application
has direct control), or layouts (pieces of text for which QuickDraw
GX automatically chooses and positions glyphs, given certain
information by the application).
GETTING STARTED WITH QUICKDRAW GX   September 1993
7
If you’re a PostScript language whiz
making the transition to QuickDraw GX, you’ll
find the article “QuickDraw GX for PostScript
Programmers” in this issue helpful.•
QuickDraw
QuickDraw GX
Printing Architecture
QuickDraw GX
Typography
QuickDraw GX Graphics Engine
System 7.1
Figure 1
QuickDraw and the Pieces of QuickDraw GX

Printed product names: QuickDraw GX · QuickDraw · System 7.1

Printed dates: September 1993

Languages: English

[Original PDF page 9](https://www.vintageapple.net/files/3ceb0e843cd5bd3641e15cf58b3ea4e52ed4e850e000fd23aaf0eb7055319430/develop-15_9309_September_1993.pdf#page=9)

### PDF page 10

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-develop-15-9309-september-1993-16659a/1#scan-6b05ad4a03b2390dd4864dce05f67e971becaacae1732423485d91c9e3dc05a2)

Transcribed text:

•   A   bitmap shape   contains a reference to a block of memory
containing a bit image, as well as information on how to interpret
the bits: the pixel size, color space, color set, and color profile.
•   A   picture   contains a list of other shapes. The shapes in the list can
be other pictures, so that a picture is actually a hierarchical
database of shapes.
Besides containing a geometry, a shape contains references to three other objects that
describe how it should be rendered. These objects are the style, the transform, and
the ink.
•   The   style   defines the pen thickness, the place where the pen draws
(inside, outside, or on the geometry), the kind of start and end cap
(such as round, pointy, or square), and ways to dash, join, and
pattern shapes. For a text shape, the style also defines the font,
size, variation, and text face.
•   The   transform   controls the skew, scale, perspective, and clipping of
the geometry. It also specifies where to draw it and how to hit-test
it.
•   The   ink   tells the system which color to draw the geometry in. Ink
also includes information about the color matching and transfer
mode.
Some of these objects in turn contain references to other objects. For example, a
transform points to a list of   view port   objects that describe where to draw the
geometry. A view port is like a QuickDraw grafPort in that it defines an area of local
space as a drawing environment. Unlike a grafPort, though, a view port doesn’t
contain state information about the drawing environment (pen, color, transfer mode,
and so on). A view port contains the mapping used to convert from the view port’s
local space to a global space described by a   view group . A view port object points in
turn to a list of   view device   objects, which describe the clip shape, mapping, and
bitmap associated with a physical device such as a monitor.
A shape can also have one or more   attributes , which modify the shape’s behavior.
These attributes enable your application to specify how a shape is edited or how
QuickDraw GX stores the shape. For example, if you set the shape attribute
gxMapTransformShape, this tells QuickDraw GX that you want it to manipulate the
transform referenced by the shape, instead of directly manipulating the data
contained within the geometry of the shape.
Figure 2 depicts the shape object and what it references. The owner count is the
number of other objects within the application that reference that object. The tag list
is a list of tag objects, which are simply containers for any data the application
associates with the owning object.
d e v e l o p   Issue 15
Shapes are completely resolution
independent,   which enables accurate
representation at any size to the screen or
printer.•
8

Reading notes: Page number and running header 'develop Issue 15' appear in the source text; their exact placement in the reading order is uncertain.

Languages: English

[Original PDF page 10](https://www.vintageapple.net/files/3ceb0e843cd5bd3641e15cf58b3ea4e52ed4e850e000fd23aaf0eb7055319430/develop-15_9309_September_1993.pdf#page=10)

### PDF page 11

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-develop-15-9309-september-1993-16659a/1#scan-3c923159b2d33becd02a2a63298f82f02802fea0f3d565b353bd3a573b4cd005)

Transcribed text:

GETTING STARTED WITH QUICKDRAW GX   September 1993
9
Color set
Color profile
Clip shape
Mapping
Bitmap
Attributes
Tag list
Clip shape
Mapping
Dither
Halftone
(Parent view port)
(Child view port list)
(View device list)
Attributes
Owner count
Tag list
View port object
View device object
Transform object
Clip shape
Mapping
(View port list)
Attributes
Owner count
Tag list
Pen size
Cap
Join
Dash
Pattern
Curve error
Attributes
Owner count
Tag list
Style object
Font
Text face
Text size
Justification
Font variations
Platform
Color set
Color profile
View group object
Type
Geometry
Fill
(Style object)
(Ink object)
(Transform object)
Attributes
Owner count
Tag list
Shape object
Transfer mode
Color
Attributes
Owner count
Tag list
Ink object
Figure 2
The Shape Object and What It References

Reading notes: Diagram labels are listed without clear reading order, so the relationships between object boxes are uncertain.

Printed dates: September 1993

Languages: English

[Original PDF page 11](https://www.vintageapple.net/files/3ceb0e843cd5bd3641e15cf58b3ea4e52ed4e850e000fd23aaf0eb7055319430/develop-15_9309_September_1993.pdf#page=11)

[Next transcribed scans](https://www.vintageapple.net/transcripts/media/va-develop-15-9309-september-1993-16659a/2.md)
