From: d88-jwa@dront.nada.kth.se (Jon Wtte)
Subject: Re: Win 3.1 vs. Mac Toolbox Messaging (Question)
Organization: Royal Institute of Technology, Stockholm, Sweden
Date: Fri, 8 Jan 1993 17:41:34 GMT

In <93008.105210REE700A@MAINE.MAINE.EDU> <REE700A@MAINE.MAINE.EDU> writes:

>  I have just deceided to migrate from the University owned 386 to my SE/30
>for some software development.  I have ordered Think C 5.0...

That's nice for single use. If you're used to Borland, you'll
feel right at home.

>  I have been reading some of the Mac revealed series (Mac Plus edition)
>and was aghast at the lack of API calls that Win 3.x supports.  Then it

Well, I do both, and the difference is actually not as large,
since Win 3.x doesn't support a lot of stuff that Mac 4.1 does...
There's just a difference between emphasis.

>   So, my question is:  Does system 7.x provide a more complete degree of
>support.  Specifically - are there more than 16 Event classes?

Why would there be? (Well, yes, there's an additional class now,
called kHighLevelEvent)

The OS messages are user interaction message primitives, and these
are by definition simple and few. However, with HighLevelEvents, you
can compose and send any kind of events to any process - yourself,
another program, or even something completely different half a world
away. Instant easy networking! There's also a comprehensive suite
of protocols to be used. Note that the AE calls are made very easy for
the programmer, you talk about tags and data associated with the tags;
the rest is done by the Toolbox.

>                       - does 7.x handle most scroll-bar and other controls
>                         itself now?

Not more than 4.1 (or 1.0 for that matter) If you use the dialog
manager, it's quite easy. Even better, Think C comes with a class
library that's better than OWL or MFC for windows; that library
makes such things trivially easy.

>                       - Am I still responsible for updating parts of a
>                         window that actually belong to the system?

I suppose you're talking of the size box? However, that's something
YOU put there; you don't have to draw it if you don't want to.
Same thing goes for controls etc. You draw them if you want them,
and that's only one call (DrawControls, DrawGrayRgn or whatever)

Again, the Think Class Library does a lot for you if all you want
is the basic run-of-the-mill application functinoality.

>Oh yeah,  What is the largest array (mem alloc) I can have?  I heard in some
>Mac vs. PC fight that the Mac had a 64K data block limit, but even system 4
>used longint's for the alloc size...

Yes, the Mac has always had a limit of available memory for
memory allocations. However, for resources, there was a 32K
limit, but it's long since gone. Mac resources are also much
more flexible than Windows resources; you can dynamically create
and read/write them, both in your own application (discouraged)
and in data files. Simple but not fast "database."

The way you should write a new-spiffy Mac application is take
in the user action events, do the graphical UI stuff, then
create an AppleEvent specifying that operation and send it
to yourself, and let the AppleEvent handler do the actual
data manipulation; this will make your application recordable,
scriptable, and generally very spiffy.

-- 
 -- Jon W{tte, h+@nada.kth.se, Mac Hacker Deluxe --

   There's no sex act that can't be made better with Yell-O.