HDTenEightyP/NetNews huggingface dataset:
From: jcav@quads.uchicago.edu (JohnC)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Toolbox init (was Re: What is a memory error -113 ?)
Date: 14 Aug 92 17:39:14 GMT
Reply-To: jcav@midway.uchicago.edu
Organization: The Royal Society for Putting Things on Top of Other Things

In article <1992Aug13.181036.10085@waikato.ac.nz> ldo@waikato.ac.nz (Lawrence D'Oliveiro, Waikato University) writes:
>In article <1992Aug13.031241.9631@gallant.apple.com>, dodd@apple.com (Mike Dodd) writes:
>>
>> void initToolbox(void)
>> {
>> 	MaxApplZone();
>> 	InitGraf(&qd.thePort);
>> 	InitFonts();
>
>Technically speaking, you're supposed to call InitFonts *before* InitGraf.
>Not that I've ever experienced any problems from doing it the other way
>round...

????????   Where is this documented?  All the source code I've ever seen
(Apple samples, etc) has _InitGraf as the first "Init" call.  I just looked
at the documentation for _InitFonts in IM-1 and it says "Call this procedure
once before all other Font Manager routines or any Toolbox routine that will
call the Font Manager."   Since Quickdraw does call the Font Manager, this
supports your contention, but if this is true, then why does everyone do it
the other way??

-- 
John Cavallino                  |  EMail: jcav@midway.uchicago.edu
University of Chicago Hospitals |         John_Cavallino@uchfm.bsd.uchicago.edu
Office of Facilities Management | USMail: 5841 S. Maryland Ave, MC 0953
B0 f++ c+ g++ k s++ e+ h- pv    |         Chicago, IL  60637
From: rich@grayhawk.rent.com (Richard Harms)
Newsgroups: comp.sys.mac.programmer
Subject: vblCount and Macintosh Programming Secrets
Date: 16 Aug 92 00:49:27 GMT
Organization: Des Moines, Iowa, Public Access Unix; 515/277-6753

On page 501 is the code for a subroutine called MySpinner...  In it, the
VBLTask field vblCount is reset to a non-zero value only if CrsrBusy is
equal to zero. My question is, if CrsrBusy is a non-zero value, and the
vblCount field isn't reset to something non-zero, won't that result in
the VBL task failing to ever execute again?

From MPW 411:
>The task must then reset vblCount, or its entry will be removed 
>from the queue after it has been executed.

Which would seem to indicate this is true...

-rh
-- 
Richard R. Harms            Internet: r-harms@grayhawk.rent.com 
1217 24th, Suite 49             UUCP: {...}!{rutgers!bobsbox}!grayhawk!rich
Des Moines, Iowa 50311       AOnline: Grayhawk             AppleLink: D2656 
                                 Fax: 515/884-2736       Unix: 515/277-6753
From: ses@cmns-moon.think.com (Simon Edward Spero)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Map (was: Australian Mac systems)
Date: 18 Aug 92 09:47:34
Organization: What's your clearance, citizen?
	<1992Aug12.165059.10056@waikato.ac.nz>
	<sold.54.713825579@kit.uni-kl.de>
	<hammett.714010980@sbsu1.aukuni.ac.nz>
	<1992Aug18.105506.8740@odin.diku.dk>
NNTP-Posting-Host: cmns.think.com
In-reply-to: klaus@diku.dk's message of 18 Aug 92 10:55:06 GMT

In article <1992Aug18.105506.8740@odin.diku.dk> klaus@diku.dk (Klaus Ole Kristiansen) writes:

   >This won't work for two reasons:

   >1. Most users don't bother to set their location in the Map control panel.

   I certainly haven't. Is there any advantage in doing so?

If you're using a powerbook, it really helps when you change back and forth 
between timezones; if only it supported daylight saving time..

Simon




--
-----
Guest account at TMC 	|	Just Another  WAIS Hacker | DOD# 0612
Newsgroups: comp.sys.mac.programmer
From: cmi@oracle.uucp (Eileen Riley)
Subject: Re: Dear Mr. Sculley
Organization: Oracle Corporation, Redwood Shores CA
Date: Thu, 13 Aug 1992 19:53:20 GMT
X-Disclaimer: This message was written by an unauthenticated user
              at Oracle Corporation.  The opinions expressed are those
              of the user and not necessarily those of Oracle.

In article <BswI6y.A60@jfwhome.FUNHOUSE.COM> jfw@jfwhome.FUNHOUSE.COM (John F. Woods) writes:
>In <keWEm9y00WBK41PWNq@andrew.cmu.edu> "George J. Baxter" <gb2a+@andrew.cmu.edu> writes:
[Stuff deleted]
>>gives me an article announcing the Quadra 950.  My response, of course,
>>was "AAAAAAAAAAARRRRRRRRRGGGGGGGGG!!!"
>
>I agree.  I'm sick and tired of Apple constantly coming out with newer and
>better machines.  Dammit, if the Mac 128K was good enough for Steve Jobs, it's
>good enough for me.

No, no, no. What we need is software-upgradable hardware. Just think: Upgrade
your old Mac Plus to a Quadra 950 just by going out and getting the
software upgrade. (Personally, I'm going to get the YMP upgrade package
for my IIfx just as soon as Cray releases it ;) )

Jon Barron
From: scott@mcl.ucsb.edu (Scott Bronson)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Dogcow Manager
Date: 22 Aug 92 01:17:00 GMT

In <sold.37.713389421@kit.uni-kl.de> sold@kit.uni-kl.de (Christoph Sold) writes:

>You forgot _FeedDogCow! They will starve without!

Actually, I'm surprised that the DogCow doesn't get *really* fat by all the
grazing going around here.  Doubt they need to be fed also...

	- Scott
Newsgroups: comp.sys.mac.programmer
From: jpugh@apple.com (Jon Pugh)
Subject: Re: FlushEvents necessary? (was: Re: Toolbox init)
Date: Mon, 17 Aug 1992 06:32:09 GMT
Organization: Apple Computer, Inc.
Followup-To: comp.sys.mac.programmer

In article <hammett.714004576@sbsu1.aukuni.ac.nz>,
hammett@sbsu1.aukuni.ac.nz (Tim Hammett) wrote:
> 
> ldo@waikato.ac.nz (Lawrence D'Oliveiro, Waikato University) writes:
> >> 	InitWindows();
> >> 	FlushEvents(0xffff,0);
> 
> >Personally I prefer to do a FlushEvents *after* all my program setup.
> 
> Is it necessary to do FlushEvents() at all these days? I notice that most
> of the DTS sample Apps don't. I would be interested in hearing the pros
> and cons of using FlushEvents at program startup.

Personally, I feel that you shouldn't need to call FlushEvents, but I can
see
situations where you should.

Most notable, the annoying splash screen (we've all made them).  Since some
of these things require a click to dismiss them, if you put one up you
should ALWAYS call FlushEvents afterwards so that the user's click doesn't
hit the desktop and switch him.  Accidentally switching out of a windowless
program is darned annoying.

Otherwise, don't flush and let the user start mousing ahead of you.

Jon
From: minow@Apple.COM (Martin Minow)
Newsgroups: comp.sys.mac.programmer
Subject: Re: THINK Debugger Question
Date: 14 Aug 92 16:18:14 GMT
Organization: Apple Computer Inc., Cupertino, CA


steve.herman%express@freedom.msfc.nasa.gov (Steve Herman) notes that
his application never gets an open document apple event when running
under the Think C debugger. When you run under the debugger, your
application does not have its own signature, but (if I remember correctly),
uses 'KAHL'. Frontier has a work-around for this. If I were you, I'd assume
that TCL handles the four required AppleEvents correctly, assuming, of course,
that you set the SIZE flags correctly in the project type dialog, and
make sure the rest of your program works correctly.

Also, don't forget to create a proper FREF/BNDL for all files your
application recognizes.

Martin Minow
minow@apple.com
From: reid@sunpix.East.Sun.COM (Reid Judd - Sun NC Development Center)
Newsgroups: comp.sys.mac.programmer
Subject: beta-testers/developers needed for Mac-RTrace
Date: 18 Aug 1992 15:31:28 GMT
Organization: Sun Microsystems, Inc., Vienna, VA. 
Distribution: world
Reply-To: reid@sunpix.East.Sun.COM
NNTP-Posting-Host: candy-apples.east.sun.com
Keywords: ThinkC, Raytrace, Macintosh, hardwork.


RTrace for the Mac will be released soon.

Beta testers are needed for a port of a full-featured raytracer for
the Macintosh.  This raytracer will be released into the public domain
next month.  Full source will be included with the release. 
 
To participate in the beta-test, you must have ThinkC-5.0.2 and be 
willing to help find, squash bugs, and give feedback (if not, please
wait until next month and get the tested/debugged version).  

RTrace supports the following concepts and primitives: point lights, 
directional lights, spot lights with fall-off, extended lights, 2 ways 
of defining surfaces, spheres, axis-aligned parallelipipeds, cylinders,
cones, bicubic patches, polygons, polygonal patches, 3D text with high 
quality, CSG operations, 4x4 matrix transformations, procedural textures,
depth of field, diffuse distribution, stereoscopic pair creation,...

RTrace has been written by Antonio Costa at INESC in Portugal. It 
currently works on Unix (Sun/HP/DG/..), Vax, Transputers, Dos, 
and (in the near future) Macintosh.   I am coordinating the port
to the Macintosh.  If you are interested in participating in the
beta-test/development for the Mac please contact:
 
                                                    
          reid.judd@East.Sun.com             
                                                   
--
From: kjh+@cs.cmu.edu (Kenneth Hughes)
Newsgroups: comp.sys.mac.programmer
Subject: Bids sought: init/cdev development
Summary: Seeking bids for code that'll intercept system event calls.
Keywords: WaitNextEvent, jGNEFilter, trap, patch
Date: 12 Aug 92 23:40:12 GMT
Organization: School of Computer Science, Carnegie Mellon


	I am willing to pay for source code for a combination init/cdev that
will allow WaitNextEvent, GetNextEvent, etc to work as normal except when
in "intercept mode".  Intercept mode can be turned on and off in the cdev.
In intercept mode, a window should be displayed when an application has
called one of the WaitNextEvent family of functions.  The window should allow
the event record to be edited.  An 'Ok' button will cause the edited event to
be the one that the calling application will receive.  A 'Cancel' button will 
allow the event to be passed through to the application as if nothing different
had happened. This must work without conflict with other applications and
utilities under Systems 6 and 7.  The source should be in Think C 5.0.

	There is a strong possibility for future work.  If you're interested,
please send me your lowested fixed bid and approximate completion time.
Also please include a description of your background.  I'm more interested
in getting decent code that works well than in being impressed with
resume-like prose, but I do need to know that the job will get done.
(If you really want to impress me, send me a binhexed executable that does
what I want instead of your background.  You'll have my attention, and
we'll talk about the source for me and the money for you.  :-)
Thank you.

Kenneth J. Hughes        (kjh@cs.cmu.edu)
President, Entelechy Corporation
Newsgroups: comp.sys.mac.programmer
From: Michael Brennan <mikeb@sam.amgen.com>
Subject: Re: C tutorial
Organization: Amgen
X-Useragent: Nuntius v1.1
     <1992Aug8.045808.11038@gallant.apple.com>
Date: Fri, 14 Aug 1992 18:30:52 GMT

In article <1992Aug7.143535.20974@das.harvard.edu> Venkatesh Reddy,
vreddy@das.harvard.edu writes:
>Also, for the Mac specifically, if you would like toolbox stuff, there is
>The Macintosh C Primer -- Programming in the Toolbox with THINK C
>by Mark Reed I believe...
>

Actually the authors are Dave Mark and Cartwright Reed.  It by far
(probably)
the best C tutorial on using the Mac toolbox.

In article <1992Aug7.143535.20974@das.harvard.edu> Venkatesh Reddy,
vreddy@das.harvard.edu writes:
>The C Programing Language (ANSI C) by Kernighan and Ritchie
>The best C reference book I have come across... 

In article <1992Aug7.183848.12556@kronos.arc.nasa.gov> Joshua
Rabinowitz-Summer-91, joshr@kronos.arc.nasa.gov writes:
>I think the best book on general C programming is Phol/Kelley's 
>_A Book On C_. (I may be biased, having studied under Al Kelley).

Kernighan and Ritchie is the best reference, but it can be quite terse. 
A Book on C
is probably a good place to start for first learning C.
From: gil@cse.ucsc.edu (Elmer Fudd)
Newsgroups: comp.sys.mac.programmer
Subject: what remains when the clothes fly off?
Date: 21 Aug 1992 01:00:06 GMT
Organization: University of California, Santa Cruz (CE/CIS Boards)
NNTP-Posting-Host: yahi.ucsc.edu
Keywords: ScrollRect()


Howdi net,

i am trying to uncover pictures, and get`something more intersting
to be unravelled underneeth then just plain ol' nothing...

i am using the routine ScrollRect() to move a boring picture to the
side, undeeeth it, i hope to reveal a surprize.  but so far all i get
is the default background pattern.  any experienced scrollers out there?
i sure could use some advise now

thanks
-gil  (gil@yahi.ucsc.edu)


Newsgroups: comp.sys.mac.programmer
From: smills@news.weeg.uiowa.edu (MuffinHead)
Subject: Re: Disabling Command-Q in a program; HELP
Keywords: Menus, File,Quit,Q 
Organization: University of Iowa, Iowa City, IA, USA
Distribution: usa
Date: Thu, 20 Aug 1992 06:47:50 GMT

aph@milton.u.washington.edu (Al Hallstrom) writes:

>I am using THINK C 5.0 on a Mac IIsi.
>I am writing a program and I want to disable the user from being able to
>press Command-Q to quit. Yes I know this is not a good idea, but you will
>just have to trust me.  I have been able to get is that if you pull down the 
>menu and select Quit nothing happens, but that is not what I want.  I have
>looked through ANSI and changed the InitConsole section where menus are 
>created. I have played with ResEdit and adding menus that way.  Even if I 
>can get rid of the menus Quit (along with the Edit commands) still have
>their command key equivalents.  Does anyone know of any way to diasble 
>the command key equivalents?  It would be a great help.

   First of all, menues should only respond to Command keys if it is in
the menu resource. If a program is written so it does otherwise, it's in
error. If you don't want the user to be able to quit, call DisableItem on
From: ezix@ucrengr.ucr.edu (edward j. zix)
Newsgroups: comp.sys.mac.programmer
Subject: TextEdit:  Breaking the 32K limit (MPW)
Date: 18 Aug 92 16:40:08 GMT
Organization: University of California, Riverside

Has anyone had any luck in breaking thehistorical limit of 32K of text in
TextEdit?  I really need a clue if there are any secret variables I could
acces or anything like that.  I'm kinda working on a deadline so if
anyone knows a way, please show me the light ASAP.

Thanks in advance.

	/  /  		Edward J. Zix
       /  /   		InterNet: ezix@ucrmath.ucr.edu
      /  /   		 BITnet:  ezix%ucrmath@Sdsc.BITnet
From: orpheus@reed.edu (P. Hawthorne)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Map (was: Australian Mac systems)
Date: 18 Aug 92 12:31:45 GMT
Article-I.D.: reed.1992Aug18.123145.24941
Organization: Reed College, Portland, OR


  hammett@sbsu1.aukuni.ac.nz (Tim Hammett) writes:
: Most users don't bother to set their location in the Map control panel.

  klaus@diku.dk (Klaus Ole Kristiansen) writes:
: I certainly haven't. Is there any advantage in doing so?

  This is the chicken and the egg problem. Nobody uses the map control panel
because nobody uses the map control panel. Lame.

  Maybe apps should check to see whether the location has been set. If not,
the app could ask them to set it somehow, either by providing a way to do
it within the app, by asking the user to do it with the control panel, or
if the control panel is not present, by offering to install it for them and
then let them do it.

  Theus (orpheus@reed.edu)
Newsgroups: comp.sys.mac.programmer
From: atkins@nosc.mil (Hugh T. Atkins)
Subject: serial port sample code wanted
Keywords: serial port,sample code,c
Organization: Naval Ocean Systems Center, San Diego, CA
Distribution: usa
Date: Thu, 13 Aug 1992 17:47:43 GMT

Can anyone direct me to sample code (THINK C prefferred) for reading
and writing via the serial port. BTW, the example in THINK Reference
is absolutely horrible.

Thanks for any tips,pointers etc.

Hugh
atkins@nosc.mil
Compuserve  71521,3606
From: chris@benton.prepress.com (Christopher Knox)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Link: Error: PC-relative edit, offset out of range.
Date: 14 Aug 92 16:06:48 GMT
Organization: Pre-Press Technologies, Inc.
X-Useragent: Nuntius v1.0


chris knox "Omne animal triste est post (or without) coitum"
From: iscjcw@uccvma.ucop.edu (Jerry Wilcox)
Newsgroups: comp.sys.mac.programmer
Subject: Re: THINK Reference
Followup-To: comp.sys.mac.programmer
Date: 21 Aug 1992 15:53:00 GMT
Organization: University of California, Office of the President
Distribution: world
NNTP-Posting-Host: ajax.ucop.edu

In article <1992Aug21.153430.6450@das.harvard.edu>, vreddy@das.harvard.edu
(Venkatesh Reddy) wrote:
> 
> I was wondering how I could get THINK Reference? I purchased THINK C 5.0,
> but I haven't registered it yet... do I et it when I register? Or is it
> shareware? or...? Thanks...
> 
> -- Venk --

It is a separately-marketed product, not included with any of the THINK
development environments (and it is well worth the cost, I might add)

-----------
Jerry Wilcox - iscjcw@uccvma.ucop.edu
All opinions expressed are MINE -- I'd have a different job if the
University wanted me to speak for it.
From: jean@biomac.univ-lyon1.fr (Jean Thioulouse)
Newsgroups: comp.sys.mac.programmer
Subject: Re: What is a sun raster file? can a pict file be converted?
Followup-To: comp.sys.mac.programmer
Date: 21 Aug 1992 12:57:19 GMT
Organization: Laboratoire de Biometrie - Universite Lyon 1
Distribution: world
NNTP-Posting-Host: macjt.univ-lyon1.fr

In article <mxmora-200892152011@css-mac2.sri.com>, mxmora@unix.sri.com
(Matthew Xavier Mora) wrote:
> 
> What is a sun raster file? is that like a pict file? is it 
> just a bitmap or is it opcodes like a pict file?

It is a bitmap with a special header. I wrote a program several
years ago which translates sun rasters to MacPaint files, but there
is a better one, called DispX_Rasters (I think it is in the info-mac
archive at sumex) which translates to PICT format.

Jean

Jean Thioulouse                              | e-mail:                    |
Universite Lyon 1 - Laboratoire de Biometrie | jean@biomac.univ-lyon1.fr  |
69622 Villeurbanne CEDEX - France.           | THIOULOU@FRCISM51.BITNET   |
From: ldo@waikato.ac.nz (Lawrence D'Oliveiro, Waikato University)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Map
Date: 19 Aug 92 10:07:06 +1200
Organization: University of Waikato, Hamilton, New Zealand

In article <SES.92Aug18094734@cmns-moon.think.com>, ses@cmns-moon.think.com (Simon Edward Spero) writes:
> In article <1992Aug18.105506.8740@odin.diku.dk> klaus@diku.dk (Klaus Ole Kristiansen) writes:
>
>    >This won't work for two reasons:
>
>    >1. Most users don't bother to set their location in the Map control panel.
>
>    I certainly haven't. Is there any advantage in doing so?
>
> If you're using a powerbook, it really helps when you change back and forth
> between timezones; if only it supported daylight saving time..

Here's another small tip: You can use Map to set your clock at the start and
end of daylight saving. Once you've set your timezone the first time with Map,
it will adjust your clock every time you change your timezone thereafter, so
GMT stays the same. The advantage with this, of course, is that starting/
stopping daylight saving doesn't throw the time off in other cities around the
world.

Lawrence D'Oliveiro                       fone: +64-7-856-2889
Computer Services Dept                     fax: +64-7-838-4066
University of Waikato            electric mail: ldo@waikato.ac.nz
Hamilton, New Zealand    37^ 47' 26" S, 175^ 19' 7" E, GMT+12:00
Newsgroups: comp.sys.mac.programmer
From: buckeye@spf.trw.com (John Wallace)
Subject: SCSI Driver/Formatter Source
Organization: TRW Data Systems Center, Redondo Beach, CA
Date: Fri, 14 Aug 92 23:24:45 GMT

I'm looking for the source code to a System 7 compatible SCSI driver
and formatter.  I was told that there are a couple of them floating
around.  Does anyone know where I can ftp them from?

(I just picked up a copy of Ephraim Vishniac's SCSI Formatter and
Installer (SF&I) from sumex-aim.stanford.edu.  It was submitted in
April 89, and is presumably not System 7 compatible.) 

Thanks!
John

Newsgroups: comp.sys.mac.programmer
From: ajcurtis@iat.holonet.net (Allen J. Curtis)
Subject: Reading Serial GPi line
Organization: HoloNet (BBS: 510-704-1058)
Date: Fri, 21 Aug 1992 13:13:11 GMT

	I am interfacing a piece of hardware to the MAC via the serial
port.  The hardware communicates back to the computer via the GPi line.

According the the documentation in the Hardware Technical reference manual
this line is connected to Data Carrier Detect (DCD) and can be polled with
software.  However, I can not find the method of polling this field in any
of the documentation or the header files which define the serial status
information.  

	Has anyone done this?  A simple description or sample code would
be greatly appreciated!

Thank for the Help in Advance....
From: daven@notable.com (Dave Newman)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Finding number of strings in a STR# resource
Date: Mon, 17 Aug 92 18:00:42 PST
Organization: Notable Technologies, Inc.
Reply-To: daven@notable.com
X-Mailer: uAccess LITE - Macintosh Release: 1.5v4


In article <1992Aug16.180425.1@tesla.njit.edu> (comp.sys.mac.programmer), erh0362@tesla.njit.edu (Elliotte Rusty Harold) writes:
| 
| I know the first two bytes of a STR# resource contain the number of
| strings in the resource, but is there a Toolbox call to read that 
| information?  Alternately can anyone suggest a hack for getting at that 
| info?  Should I just call GetResource and cast the resulting handle to 
| (short **)? 


That's they way I'd do it.

--Dave

-----------------------------------------------------------
Dave Newman                 |  AOL:      AFC Tinman
Artillery Spotter           |  ALink:    TINMAN
Notable Technologies, Inc.  |  CIS:      70743,3323
Voice:    510.208.4449      |  internet: daven@notable.com
FAX:      510.444.4493      |  
-----------------------------------------------------------
Newsgroups: comp.sys.mac.programmer
From: janee@world.std.com (Jane Eisenstein)
Subject: WSE classes for TCL 1.1.2?
Organization: The World Public Access UNIX, Brookline, MA
Distribution: na
Date: Tue, 18 Aug 1992 22:41:49 GMT

I got a copy of Ned Horvath's TCL 1.0 text classes that were adapted
to use Word Solution Engine instead of TextEdit.  Before I try to
update them to work with the current TCL, I'd like to know if this
work has already been done and is available.  How about it?

Jane Eisenstein
janee@world.std.com
Newsgroups: comp.sys.mac.programmer
From: Michael Brennan <mikeb@sam.amgen.com>
Subject: Re: HINT on upgrading from THINK C 4.0 to 5.0.2
Organization: Amgen
X-Useragent: Nuntius v1.1
     <PHILS.92Aug7094944@chaos.cs.brandeis.edu>
Date: Fri, 14 Aug 1992 18:21:09 GMT

In article <1992Aug5.193816.27403@hobbes.kzoo.edu> Jamie R. McCarthy,
k044477@hobbes.kzoo.edu writes:
>Does anyone else have any problems (known or rumored) with any of the
>optimizations?

I encountered quite a few very nasty bugs with optimization in 5.0.
Mostly with the global
optimizations.  In one instance, it took an expression within a loop
(whose value was
incrementing in the loop), and decided to use a temporary value for the
expression
whose value was defined before entering the loop. The code in the loop
therefore failed.
In another instance, it decided two variables were never used at the same
time,
so it assigned them the same memory space. In fact, the two variables
WERE used
at the same time in a number of places, so the optimization wreaked havoc
with
the code.

I haven't encountered any such problems with 5.0.2 so far, but I am leary
of the
optimizations nonetheless.