HDTenEightyP/NetNews huggingface dataset:
From: mxmora@unix.sri.com (Matthew Xavier Mora)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Amateur Programming? [Re: Is IM going to be repackaged?]
Date: 12 Oct 92 16:58:20 GMT
Followup-To: comp.sys.mac.programmer
Organization: SRI International

In article <1992Oct9.153607.22030@hobbes.kzoo.edu>, k044477@hobbes.kzoo.edu
(Jamie R. McCarthy) wrote:
> I have no idea about the others, but--in deference to Bill Atkinson's
> prodigious talent--it took a lot more than two or three people to bring
> out HyperCard.  (And, from the about box, it looks like developers
> turned out in droves to hack on version 2.)  If I remember correctly
> from the interview in Danny Goodman's book, Bill didn't write any of
> the printing code, or even HyperTalk...

But all the magic (the stuff that forever changed the way Mac Programs look
and feel. ie Tear off menus, floating pallets, Special effects, abuse of
the HIG :^) ) of Hypercard was done by Bill. The printing code was pretty
dismal
in the first version if I recall correctly. HyperTalk was neat though.





--
----------------------------------------------------------------------
Matthew Xavier Mora                                mxmora@unix.sri.com
SRI International                                       (415) 859-5011
----------------------------------------------------------------------
Newsgroups: comp.sys.mac.programmer
From: currie@teal.csn.org (Andrew Currie)
Subject: $$$Question for Debug Wizard on Cool Interactive Kiosk$$$
Followup-To: Andrew Currie (currie@csn.org 303-938-8650)
Organization: Colorado SuperNet, Inc.
Distribution: usa
Date: Wed, 7 Oct 1992 15:09:29 GMT

Very Cool Interactive Media Mac System having Very Un-Cool 
Problems I'm having a serious problem tracking a strange Mac system bug in
an interactive media kiosk and i'm soliciting comments & suggestions.

I'm having random bus errors on a Mac Quadra 900 running
w/36MB RAM (32 bit mode of course), VM off, 600MB Fujitusu,
150MB PLI Floptical, Dove/Marathon multi-serialport board (for 
laserdisk, laser printer, modem), System 7.0.1 (Tune-up removed), 
768K RAM cache, SuperMac ColorCard/8 video board, and 
MacNTouch Touch screen.

Foreground app at time of bus error is MacroMind Projector 3.1 
	some Lingo scripting nothing hairy, ususally just looping
Background app at time of bus error is HyperCard 2.1
	some Hypertalk scripting nothing hairy, should be inert
Extensions include PowerKeys and QuickKeys and ATM
Debug extensions include EvenBetterBusError and DoubleTrouble

Symptom: Random bus errors (and occasional CPU halt i.e no 
MacsBug available) NOTE THAT AS OF YET THERE IS NO WAY TO 
FORCE BUS ERROR, current approach is to "wait for it".

Data: Always seems to drop into MacsBug at _StripAdress + 0470
trying to TST.B (A0) with A0=FFFFFFFC. 
Sys Heap is OK, App Heap is OK. Stack is NOT OK.

Problem: I cannot back thru the stack cuz there is no valid stack 
chain. (tried SC6,SC7, and SC) Actually MacsBug usually says the
stack is bad.

Question: WHAT NEXT?!? I believe something is "setting a land mine" 
by stomping low memory but i cannot figure out how to "back up" 
and track who set the land mine!!!! Any suggestion as to:
1. What could be causing the problem?
2. How to back track to the source of the problem?

$$$ Money for correct answers or suggestions leading to fix $$$

andrew currie
currie@csn.org
303-938-8650 (leave msg)



-- 
+++++++++++++++++++++++
currie@csn.org
+++++++++++++++++++++++
From: mxmora@unix.sri.com (Matthew Xavier Mora)
Newsgroups: comp.sys.mac.programmer
Subject: Re: mac CBeautifier?
Date: 12 Oct 92 17:01:31 GMT
Followup-To: comp.sys.mac.programmer
Organization: SRI International

In article <1992Oct9.165903.24305@hobbes.kzoo.edu>, k044477@hobbes.kzoo.edu
(Jamie R. McCarthy) wrote:

> I can't find cdent on "ROM With a View."  Are you sure it made it on the
> final version?

its in :":Development Platforms:C++ Related:C++ Source Code Formatter:"



--
----------------------------------------------------------------------
Matthew Xavier Mora                                mxmora@unix.sri.com
SRI International                                       (415) 859-5011
----------------------------------------------------------------------
From: Daryl_Spitzer@mindlink.bc.ca (Daryl Spitzer)
Newsgroups: comp.sys.mac.programmer
Subject: PowerBook Traps?
Date: 11 Oct 92 14:31:23 GMT
Organization: MIND LINK! - British Columbia, Canada
Distribution: world

Are there any traps (or other techniques) for switching between the internal
and external modem on a PowerBook?  (And while I'm asking, what about turning
on/off Rest Mode, PowerSaver mode, changing the screen brightness...)

I haven't been able to find any technical notes on the subject.  It must be
possible, since 3rd party utilities are beginning to appear for the
PowerBooks.  I'd like to take a stab at writing my own though (and perhaps
learn something in the process).

(I don't have a CD-ROM, but I can access ftp through a mail server if I know
the exact path, and I do have an AppleLink account.)

--
-------------------------------------------------------------------
 Daryl_Spitzer@mindlink.bc.ca     "Life isn't just, life just is."
         a2251@mindlink.bc.ca              -- Me  (I think.)
-------------------------------------------------------------------
Newsgroups: comp.sys.mac.programmer
From: yates@engr.latech.edu (Donald W. Yates)
Subject: Need idiot-level asm help v1.1
Organization: Louisiana Tech University
X-Newsreader: TIN [version 1.1 PL6]
Date: Thu, 15 Oct 1992 19:55:19 GMT

Just found out the my mailer (and me) have the wrong address. This one
should work. Therefore:

Could someone please send me a barebones assembly language program that
will print out a string on a Mac.  I am using a CDS assembler.  Someone
has misplaced (stolen?) our documentation and I am in kinda a hurry.

I need a program that works like "Hello World" that most programming texts
use.

Thanks in advance again.

yates@engr.latech.edu  (I hope)
From: stepan@natinst.com (Stepan Riha)
Newsgroups: comp.sys.mac.programmer
Subject: Re: THINK C bug AGAIN
Date: 14 Oct 1992 14:59:24 -0500
Organization: National Instruments, Austin, TX
NNTP-Posting-Host: falcon.natinst.com

This was a discussion on why the following code failed in THINK C 5.0.3:

>>	while (*index != CR && i < 9)
>>		posString[i++] = *index++;
>>	posString[i]=0;

In article <Bw4DGs.Gyz@news.cso.uiuc.edu> swofford@uxh.cso.uiuc.edu (David Swofford ) writes:
>
>This is scary.  I switched to 5.0.3 primarily because of the Debugger
>fixes.  Now I'm wondering if I too should go back.  The problem is that
>in a very large application, bugs like this go easily go unnoticed for
>a long time.
>
>Does THINK know about this?  Will there be a 3.0.4 soon?

I've been using TC 5.0.3 on a large project (over 1 Meg of compiled code) and
haven't noticed these problems.  I also tried the two loops described and
THINK C generated correct code (I added proper initialization of index and i).
Personally I won't panic unless I find wrong code generated from MY source.

	- Stepan
-- 
   Stepan Riha -- stepan@natinst.com

Newsgroups: comp.sys.mac.programmer
From: rmf@chopin.cs.columbia.edu (Robert M. Fuhrer)
Subject: Re: scanf equivalent calls that does not use global variables?
Organization: Computer Science Dept., Columbia Univ.
Distribution: usa
Date: Wed, 7 Oct 1992 21:45:15 GMT

Perhaps you can use the format-specific individual calls, such as atoi(),
atof(), and so on? They're also part of the ANSI C standard library.
--

-- Bob
Newsgroups: comp.sys.mac.programmer
From: mkelly@mystix.cs.uoregon.edu (Michael A. Kelly)
Subject: Re: Telling the Finder to update a file's type & creator
Organization: University of Oregon Computer and Information Sciences Dept.
Date: Mon, 12 Oct 1992 22:40:28 GMT

In article <D2150035.ftnmvb@outpost.SF-Bay.org> peirce@outpost.SF-Bay.org (Michael Peirce) writes:
>
>In article <1992Oct12.065332.4638@cs.uoregon.edu> (comp.sys.mac.programmer), mkelly@mystix.cs.uoregon.edu (Michael A. Kelly) writes:
>> like to tell the Finder to immediately update the file's icon and/or Kind
>> when I change the type and/or creator.  I know it's possible, because
>
>You need to set the modify date of the parent directory.  Use something
>like this:
>
>    stat = PBSetCatInfo(&aCPB,false);
>								
>    aCPB.hFileInfo.ioCompletion	= nil;
>    aCPB.hFileInfo.ioNamePtr	= nil;
>    aCPB.hFileInfo.ioVRefNum	= outReply.sfFile.vRefNum;
>    aCPB.hFileInfo.ioDirID		= outReply.sfFile.parID;
>    aCPB.hFileInfo.ioFDirIndex	= -1;
>								
>    GetDateTime(&now);
>    aCPB.dirInfo.ioDrMdDat = now;
>								
>    stat = PBSetCatInfo(&aCPB,false);

Thanks to all who responded by email, as well as those who responded here.
And special thanks to Michael Peirce and Anders Sundin, who sent code!  Here
is Anders Sundin's code, slightly modified:

OSErr TouchDir(
    short   vRefNum,
    long    dirID )
{

    CInfoPBRec   info;
    Str255       name;
    OSErr        theErr;

    info.dirInfo.ioDrDirID = dirID;
    info.dirInfo.ioVRefNum = vRefNum;
    info.dirInfo.ioNamePtr = name;
    info.dirInfo.ioFDirIndex = -1;

    theErr = PBGetCatInfo( &info, 0 );

    if ( ! theErr ) {

        info.dirInfo.ioCompletion = 0;
        info.dirInfo.ioDrDirID = info.dirInfo.ioDrParID;
        info.dirInfo.ioFDirIndex = 0;
        GetDateTime( &info.dirInfo.ioDrMdDat );

        theErr = PBSetCatInfo( &info, 0 );

    }

    return theErr;
    
}



In another article, mxmora@unix.sri.com (Matthew Xavier Mora) wrote:
>
>A post a while ago showed some
>code on how to do this. Check your archive.

:) :)  I really need to write a program to search the digest.  There's just
too much there to search through by hand....

Mike.
-- 
_____________________________________________________________________________
Michael A. Kelly                                         University of Oregon
mkelly@cs.uoregon.edu                             Computer Science Department
_____________________________________________________________________________
Newsgroups: comp.sys.mac.programmer
From: keith@taligent.com (Keith Rollin)
Subject: Re: Using ProcPtrs
Followup-To: comp.sys.mac.programmer
Organization: Taligent
Date: Fri, 16 Oct 1992 12:31:57 GMT

In article <Bw78A8.C99@comp.vuw.ac.nz>, Adrian.Ross@comp.vuw.ac.nz (Adrian
Charles Ross) wrote:
> 
> When using the address of a procedure to specify that procedure for later use,
> eg. setting a control's action proc or a sound channel's completion routine,
> it seems to me (I'm relatively new to this) that when the time comes later
> for the procedure to be executed, its segment may have moved in memory
> and its pointer would thus no longer be valid.
> If this is the case, why are facilities for control action procedures etc 
> provided? How do you get round this problem?

There is no problem. When you take the address of a function, you are
actually getting a pointer to its jump table entry. If the segment later
moves, the jump table entry will reflect its new position.

-----
Keith Rollin
Phantom Programmer
Taligent, Inc.
From: Peter Cramer <pgc@pop.cwru.edu>
Newsgroups: comp.sys.mac.programmer
Subject: Re: TCL panes & controls
Date: 12 Oct 1992 14:06:30 GMT
Organization: Physics Dept, Case Western Reserve University
Distribution: world
NNTP-Posting-Host: physicsmac1.phys.cwru.edu
X-UserAgent: Nuntius v1.1

I finally solved the problem that was plaguing me.  The problem was that
scroll bars were appearing in places where they should have been
invisible when I scrolled their enclosure.  (why I needed this
functionality is something I won't bore you with here)

I traced the problem to the CControl::Offset method, where the following
fragment appears:

HidePen();
...
MoveControl(...);
...
ShowPen();

The thing is, MoveControl() apparently doesn't always listen to
HidePen().   I replaced the call to MoveControl with some code that
manipulates the control record directly, and everything worked fine. 
There was a bonus in that scrolling speed improved tremendously! 
Interestingly, the bug appeared on my IIsi (running system 7) only when I
was in 256 color mode.

Thanks to Dana Emery and Jamie McCarthy for their very useful advice.
Newsgroups: comp.sys.mac.programmer
From: k044477@hobbes.kzoo.edu (Jamie R. McCarthy)
Subject: Re: mac CBeautifier?
Organization: Kalamazoo College
Date: Fri, 9 Oct 1992 16:59:03 GMT

ksand@apple.com (Kent Sandvik) writes:
>
>The latest developer CD has a tool called cdent that works really fine,
>I use it daily. Forget the days of silly C code bracket wars, cdent
>reformats your code to your liking.

I can't find cdent on "ROM With a View."  Are you sure it made it on the
final version?
-- 
 Jamie McCarthy      Internet: k044477@kzoo.edu      AppleLink: j.mccarthy
 "To flame someone on an open forum is, to me, the height of insensitivity."
   - P.J. Plauger
Newsgroups: comp.sys.mac.programmer
From: ksand@apple.com (Kent Sandvik)
Subject: Re: Is IM going to be repackaged?
Date: Wed, 7 Oct 1992 02:49:22 GMT
Organization: Apple
Followup-To: comp.sys.mac.programmer

In article <dq+pmjh.nagle@netcom.com>, nagle@netcom.com (John Nagle) wrote:
> 
>       It doesn't really matter, though, because 75% of software sold at
> retail comes from the top 11 firms.  The era of amateur programming is
> drawing to a close.

Don't forget the GNU offerings on the UNIX platform.

Kent
-------------------
Kent Sandvik (UUCP: ....!apple!ksand; INTERNET: ksand@apple.com)
DISCLAIMER: Private activities on the Net.
Newsgroups: comp.sys.mac.programmer
From: sjw@bluemoon.rn.com (Steve Waydo)
Subject: ResEdit
Organization: Blue Moon BBS ((614) 868-998[024])
Date: Wed, 07 Oct 92 17:38:34 EDT

I have a large pascal program that I am working on.  I want to use ResEdit 
to make a new window, but it always uses the global coordinate system, 
reletive to the screen, not the window.  This causes problems when a user 
moves the window.  How can I make a window that won't use global 
coordinates???  Thanx.

 This is from
     sjw@bluemoon.rn.com
who doesn't have his (or her) own obnoxious signature yet
From: minow@Apple.COM (Martin Minow)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Execution timing of ODOC
Date: 8 Oct 92 14:45:44 GMT
Organization: Apple Computer Inc., Cupertino, CA


In <0q3-4l@engin.umich.edu>, Michael F. Kamprath
<kamprath@space-grant.sprl.umich.edu> wrote:

>Whenever I send my application an open document >event from outside the
>application, it will not actually open the >document until I bring the
>application to the front.  How do I get the >program to open it imediately
>while it is still in the background?  I assume >this ia an easy one, but I
>just don't see it.

Make sure your application SIZE resource flags include "background NULL
events." The value 0x58E0 seems to work for me. Your initialization
sequence ought to include something like the following:
		FlushEvents(everyEvent, 0);
		/*
		 * Clean out event queue -- see Tech Note 180.
		 * Calling EventAvail tells Multifinder to bring
		 * the application to the front. It is needed
		 * especially if canBackground is set in the
		 * size resource, but harmless otherwise.
		 */
		for (i = 1; i <= 3; i++)
			EventAvail(everyEvent, &EVENT);

Hope this helps.

Martin Minow
minow@apple.com
Newsgroups: comp.sys.mac.programmer
From: siegel@world.std.com (Rich Siegel)
Subject: Re: Amateur Programming? [Re: Is IM going to be repackaged?]
Organization: GCC Technologies
Date: Mon, 12 Oct 1992 14:26:37 GMT

>) >Word processors are done pretty well by the big companies these days.
>) >So are drawing apps.  But the development of something like THINK
>) >C 5.0 is well within the reach of two or three talented and informed
>) >folks with a year or two of evenings and weekends to spend.  And the
>) >end result could well be better.

Not hardly. The compiler alone in THINK C 5.0 represents about three
man-years of solid 50+ hour a week work by three talented and informed
individuals with years of combined compiler design and implementation
experience. An industrial strength, professionally finished development
environment is not the sort of thing you can knock off on nights and 
weekends.

>The success of large commercial developers is certainly not generally
>due to code quality, nor due to the cleverness of designers or managers.
>Nor is it due to the working environment or the quality of personnel.

So what -is- it due to? You never finished this thought...

The continued success of THINK C is due to the fact that the designers
and implementors listened to the people who were going to use it. That's
the key to success in any software venture: listen to your customers,
and when they ask for something, don't take it at face value - figure
out -why- they asked for it, and what they really need. Then fill that
need, and people will buy the product.

>I was disheartened to find myself tripping over egos, crossing into 
>invisibly-delimited "territories," and continually gearing up for 
>competition with folks who in a more sensible world would be cooperative 
>coworkers.  (With this attitude of fear and loathing apparently so
>often in evidence I am surprised that any software EVER gets written.)

Sounds like you picked the wrong place to shop for a job. It's been my
experience that if you look, you'll somewhere find a group of people
that in an overall sense share your world view and way of thinking
about customers and products. If you do, it's an excellent fit, and
the annoying little personality quirks just disappear.

R.



-- 
-----------------------------------------------------------------------
Rich Siegel                              Internet: siegel@world.std.com
Software Engineer & Toolsmith
GCC Technologies
Newsgroups: comp.sys.mac.programmer
From: jpugh@apple.com (Jon Pugh)
Subject: Re: PowerBook Traps?
Date: Wed, 14 Oct 1992 06:48:08 GMT
Organization: Apple Computer, Inc.
Followup-To: comp.sys.mac.programmer

In article <1992Oct14.013909.24590@gallant.apple.com>, Steve Christensen
<stevec@apple.com> wrote:
> 
> In article <jpugh-121092191216@90.20.3.200> Jon Pugh, jpugh@apple.com
> writes:
> >Heck, we don't even keep the published ones the same!  How's about that
> >Wakeup function?  ;)
> 
> You mean the wakeup timer?  Well, it's supported on machines whose
> hardware supports it.  

Too bad it's also supported on machines that don't support it.

Does that parse?

The problem is that the wakeup timer call never errors, even on machines
without a timer.  As far as I could tell, there was no way to determine if
this trap would actually work.  I ended up having to use the informational
Gestalt selector and building that information into the code.  It sucked.

Just my 2 cents of whining.  I'll stop before I get to the SuperClock icon.
 ;)

Jon
From: stevec@apple.com (Steve Christensen)
Newsgroups: comp.sys.mac.programmer
Subject: Re: PowerBook Traps?
Date: 12 Oct 92 22:26:39 GMT
Organization: Apple Computer, Inc.
X-Useragent: Nuntius v1.1

Daryl Spitzer, Daryl_Spitzer@mindlink.bc.ca writes:
>I should have mentioned that I have read the Power Manager chapter, but
>couldn't find any information on switching between the internal modem and
>external (just info on turning off and on power to the ports) nor on
turning
>on and off rest mode or powersaver mode.
>
>Are there traps for these?
>
>Perhaps I should did around in the Portable control panel and Battery DA
with
>MacsBug to see what I can find...

No, there are no programming interfaces for dealing with the Power Manager
other than those documented in IM VI.  Part of the reason for this is that
mucking around with the power management system if you don't know how
everything works can cause stuff to break.  The folks who are providing
some of these features (Connectix' CPU comes to mind) do so by playing in
the Power Manager.  This is potentially "dangerous" because we're not
obligated to keep the Power Manager's internals the same from PowerBook
to PowerBook.  Evolution and improvements to the model force things to
change...

steve
Newsgroups: comp.sys.mac.programmer
From: mhall@abc.comp.sys.mac.programmer (Matthew Hall)
Subject: Re: Best way to get A5 into VBLTaskProc?
Organization: Oberlin College Computer Science
Date: Thu, 15 Oct 1992 01:13:13 GMT
X-Posted-From: abc.cs.oberlin.edu
NNTP-Posting-Host: sol.ctr.columbia.edu

Hello-
	I asked this same question recently and got the same answer.
However, that the address of the task is stored in A0 is not
documented in any IM that I can find.  If it isn't documented, isn't
it about as safe as self modifying code? (I know for revised and
x-time tasks it is stored in reg A1, but it explicitly says in IMVI
that for slot tasks you may need to use self modifying code)

Confused about what Apple is doing,
-matt hall

--
-------------------------------------------------------------------------------
Matt Hall.    mhall@occs.oberlin.edu  OR  SMH9666@OBERLIN.BITNET
              (216)-775-6613 (That's a Cleveland Area code. Lucky Me)

"Life's good, but not fair at all"  -Lou Reed

Newsgroups: comp.sys.mac.programmer
From: jasper@sisters.cs.uoregon.edu (Jon Barber)
Subject: Think Pascal library within a Think C project ??
Organization: University of Oregon Computer and Information Sciences Dept.
Date: Wed, 7 Oct 1992 22:59:27 GMT

  Hi - we're a two-person team developing Mac apps for
biology instruction, and we have some existing code
in Think Pascal that we'd like to use from Think C.
Is this possible?
I've tried making a Pascal code library (Build Library...)
which works from a Pascal test project, but 
on the C side of things, the Pascal library
doesn's seem to be visible when we try to Add File the Pascal
library to the C project.  Is this the right direction?
The documentation alludes to the possibility of doing
this sort of thing - so now, how is it done?
Thanks in advance...
+---------------------------+----------------------------------------+
| "jasper" Jon Barber       | Jasper Enterprises                     |
| jasper@cs.uoregon.edu     | Unix & Mac Consulting, Ad Excellentum  |
+---------------------------+----------------------------------------+
|  * Currently based in Eugene, Oregon, living the simple            |
|    life with macs, peacocks, and three consulting gigs.            |
|  * Anyone interested in a Vegetarian Telecommuting Commune?        |
|  * Anyone interested in hiring me for inexpensive, high-quality    |
|    work in exotic locations??  India?  Costa Rica?                 |
|    Switzerland?  Nepal?  New Zealand?  Your Winnabego?             |
+--------------------------------------------------------------------+
Newsgroups: comp.sys.mac.programmer
From: Mike.Hammer@bbs.oit.unc.edu (Mike Hammer)
Subject: Code for Simple Text Editor
Organization: Extended Bulletin Board Service
Date: Thu, 15 Oct 1992 21:09:05 GMT

Hi!

Does anyone have sample C/C++ codes to generate a simple text editor
that they can e-mail me, or have any information where I can
ftp it from? Thank you.

Mike


--
   The opinions expressed are not necessarily those of the University of
     North Carolina at Chapel Hill, the Campus Office for Information
        Technology, or the Experimental Bulletin Board Service.
           internet:  bbs.oit.unc.edu or 152.2.22.80
Newsgroups: comp.sys.mac.programmer
From: ksand@apple.com (Kent Sandvik)
Subject: Re: mac CBeautifier?
Date: Wed, 14 Oct 1992 04:29:27 GMT
Organization: Apple
Followup-To: comp.sys.mac.programmer

In article <1992Oct9.165903.24305@hobbes.kzoo.edu>, k044477@hobbes.kzoo.edu
(Jamie R. McCarthy) wrote:
> ksand@apple.com (Kent Sandvik) writes:
> >The latest developer CD has a tool called cdent that works really fine,
> >I use it daily. Forget the days of silly C code bracket wars, cdent
> >reformats your code to your liking.
 
> I can't find cdent on "ROM With a View."  Are you sure it made it on the
> final version?

Well, a find from Finder found it immediately with my "ROM With a View",
or the Dev CD dated September 92. If you want to do it the hard way,
look inside the Development Platform:C++ Related folder.

We are looking into problems with the cdent  tool writing to low memory 
(address 0 and 4). Still seems to work fine in my MPW environment...

Kent/DTS
-------------------
Kent Sandvik (UUCP: ....!apple!ksand; INTERNET: ksand@apple.com)
DISCLAIMER: Private activities on the Net.