HDTenEightyP/NetNews huggingface dataset:
From: dorner@pequod.cso.uiuc.edu (Steve Dorner)
Newsgroups: comp.sys.mac.programmer
Subject: Re: What's the best debugger?
Date: 6 Apr 92 16:56:11 GMT
Article-I.D.: ux1.1992Apr6.165611.25169
Organization: University of Illinois at Urbana-Champaign

neeri@iis.ethz.ch (Matthias Ulrich Neeracher) writes:
>SADE is powerful, but not easy enough to use.

SADE makes you spend quite a bit of time programming your debugger, rather
than debugging your program.  I find this frustrating, but it isn't the
end of the world.

I find SADE's performance quite acceptable; now that I have my Quadra.
Before that, SADE was sort of slow; again, not the end of the world,
but inconvenient.

What *IS* the end of the world (:-)) is that SADE is unable to view
the contents of variables before the current stack frame, if those variables
are in registers.  Compounding the problem is that MPW's C compiler lacks
a switch to keep variables out of registers. [Yes, I know that I could add
code to each of my declarations to force variables out of registers, but that's
a mess and a big pain in the tush.]  This is a major deficiency.

When I have a sticky debugging problem that doesn't involve the toolbox
(eg, parsing routines), I move the code to my cube and use gdb.  Gdb has
SADE beaten hands down in most areas, including the ability to inspect
previous stack frames.
-- 
Steve Dorner, U of Illinois Computing Services Office
Internet: s-dorner@uiuc.edu  UUCP: uunet!uiucuxc!uiuc.edu!s-dorner
Newsgroups: comp.sys.mac.programmer
From: florian@convex.csd.uwm.edu (Chris Florian)
Subject: Mac Problems
Originator: florian@convex.csd.uwm.edu
Organization: UW-Milwaukee: Computing Services Division
Date: Wed, 15 Apr 1992 13:52:58 GMT

	Okay, don't laugh...

	I have a mac, model: M0001W (That's a first generation Mac
	expanded to 512k.)  

	The problem I am having is that I keep getting System Error
	ID=2 and ID=3.  This may just be because the mac I have is
	just not capable of running the programs I ask of it.  But
	the programs I am trying are old enough that they should run.
	Even the ones that came with the mac often crash, for example
	Microsoft Multiplan.  Any Ideas?

	Secondly,  I have been having a real problem getting a
	communication package to work on this thing?  I had heard that
	there are some non-standard pin configurations on the original
	macs' modem connection.  If anyone knows of a program that
	would work on this mac, and where to find it, please let me
	know.

	My wife and I received it as a gift, and it IS better
	than a typewriter, and some games do work, so...

	Just remember what your mother told you, "If you haven't got
	something nice to say, SHUT UP!"


Newsgroups: comp.sys.mac.programmer
From: potts@itl.itd.umich.edu (Paul Potts)
Subject: Re: IM IV Sound Mgr error fix...where?
Keywords: now why couldnt they have gotten it right the first time
Organization: Instructional Technology Laboratory, University of Michigan
Date: Thu, 16 Apr 92 18:21:33 GMT

In article <5340@pdxgate.UUCP> howard@rigel.cs.pdx.edu (howard l. berkey) writes:
>
>Hi all!
>	I understand that the chapter on the Sound manager in IM IV (four,
>not six) is somewhat, ah, misinformative and I was wondering if the correct
>info is available on an FTP site... I looked on sumex but didn't see it.  Also
>I was wondering if Apple/Addison-Wesley/apda or some philanthropist was going
>to produce an edition of IM IV with the correct information.

IM-6 (VI, six : > ) is much improved, although still a little hard to follow
as far as organization goes. Beyond that there is the draft chapter for a
revised Inside Macintosh that is available on ETO disks and (maybe) on 
Develop or the Developer's CDs.

I've been able to get along quite well with IM-6.
-- 
Paul Potts - potts@itl.itd.umich.edu
Un damne' descendant sans lampe,/ Au bord d'un gouffre dont l'odeur
Trahit l'humide profondeur,/ D'e'ternels escaliers sans rampe... 
   -Baudelaire on DOS/Windows programming   
Newsgroups: comp.sys.mac.programmer
From: kamprath@caen.engin.umich.edu (Michael F. Kamprath)
Subject: Large pointer blocks
Date: Mon, 06 Apr 92 21:50:35 EDT
Organization: The University of Michigan, Ann Arbor

I've been writing several computational programs lately on the mac
(in THINK C 4.0.5) and I've finally figured out (with some help) a 
stable way to handle large arrays using pointers.  But now that
my programs are stable, I would like to increase the array size 
but I can't allocate pointers for memory blocks larger than about 
30K of RAM.  I think I read some where that this is a natural limitation
in the Mac.  My question is, if my program heap is, for example, 2 Megs
of RAM, my coding only taking up the first 50K of RAM, why
can't I (or how can I) use the rest of the 1.95 Megs of RAM for arrays
to be manipulated by the code?  If I am limited to 32K of usable array
(or pointer) accesable memory, is there a clever way to circumvent this, 
short of saving blocks of memory to a hard drive? 

I am using a IIci to do my programing on.  Does the new Quadra have this
same memory limitation?  If so, how can Apple seriousely try to put it off as 
a "powerful", "number crunching", "Atila the Hun" type of computer?  

I realize a Mac is slow when compared to DEC stations and the such, so it
may not be my best choice for heavy number crunching.  But it is accesible
and overnight runs are not impratical for me. If anybody could help me solve
this memory problem, I'd really appreciate it.

Michael Kamprath
kamprath@caen.engin.umich.edu
Newsgroups: comp.sys.mac.programmer
From: zobkiw@world.std.com (Joe Zobkiw)
Subject: Re: question: THINK C "real window" console available?
Organization: The World Public Access UNIX, Brookline, MA
Date: Fri, 10 Apr 1992 14:11:29 GMT

<< If one doesn't exist perhaps someone could make one available for ftp.
>>

Hmmm...this makes no sense to me. If it doesn't exist, how can it be
made available?

In any case...you probably mean scrolling window? I would agree that it
would be nice if THINK C's console window was a bit more like MPW's 
worksheet. I don't know if anything like this exists...but it may.


-- 
<--------------------------------------------------->
 joe zobkiw                     zobkiw@world.std.com
 mac.synthesis.MIDI.development.C.asm.communications
>---------------------------------------------------<
Newsgroups: comp.sys.mac.programmer
From: ksand@apple.com (Kent Sandvik)
Newsgroups: comp.sys.mac.programmer
Subject: Re: More help with app startup tracing, please.
Date: 10 Apr 92 01:46:54 GMT
Organization: MacDTS Mongols

In article <1992Apr1.055747.12908@acsu.buffalo.edu>, triantos@acsu.buffalo.edu
(Nick B Triantos) writes:
> 
> Forgive me for sounding naive, but I'm still not really able to follow what is
> going on during the segment loading process.  CODE 0 tells the system to load
a
> segment, maybe more than one at a time.  Then it (I think) JMP's to the
> beginning of the segment, yes?  I think that if I'm able to see what a program
> is doing just before, during, and after its startup screen is displayed, I may
> be able to figure out why I can't get it to work correctly.
> 
> I'm no longer interested in making the program work, but I'd really love to
> understand the application startup process better.

Inside Macintosh, Second book, Segment Loader (second chapter) is what you need
to read.

Speaking about runtime issues, and especially model far which is a new beast
to understand, the forthcoming MPW documentation has a good chapter which 
has an inside-out description of how everything works together. I can't say
the exact day/time this documentation is ready, but we are speaking about months
or maybe weeks.

Cheers,
Kent Sandvik
Dynamic Language Materialist
Newsgroups: comp.sys.mac.programmer
From: engber@ils.nwu.edu (Mike Engber)
Subject: pattern alignment
Summary: how do you match it up between a offscreen GWorld and a window?
Organization: The Institute for the Learning Sciences
Date: Wed, 8 Apr 1992 16:20:48 GMT

I have a GWorld containing a copy of part of the screen. I need to
erase some of it (to make an object disappear) before I copy it onto
the screen. The problem is getting the pattern alignment right.

Any ideas? 

Note: the GWorld doesn't necessarily just contain the bits of the
window containing the object - it contains an arbitrary piece of
the screen - in support of dragging objects between windows.

Please cc via email if possible.

-ME
From: d88-jwa@hemul.nada.kth.se (Jon W{tte)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Simple text engine needed
Date: 8 Apr 92 17:08:24 GMT
Organization: Royal Institute of Technology, Stockholm, Sweden
Originator: d88-jwa@hemul.nada.kth.se

.cso.uiuc.edu> rps32513@uxa.cso.uiuc.edu (Ronald P. Smith) writes:

   I'm looking for a good text engine with no limit as to size of text.
   I need to be able to display a 7 meg document in a scrolling window.  The
   program would keep at most 100K in memory at a time, loading in a different
   section of the text as needed.  I thought about writing something myself,
   but don't really know where to start.  What is the accepted way to display

Welcome to the Number One Pet Peeve Of Mac Programmers (tm)

I would recommend the Word Solutions Engine from DataPak.
It's $394 per license, plus $1 for media (floppy) and the
license lets you use the library any way you want except
re-selling it as a library or in its "virgin" form.

It handles > 32k text, and they sell an add-on for paging
to disk (among other add-ons)

The functionality is a little quirkier than TextEdit, but
not much. I have had some problems with the selection not
updating correctly, but that's probably my own fault.

-- 
h+@nada.kth.se; Jon W{tte, the Diplomat - NOT!
Newsgroups: comp.sys.mac.programmer
From: mlanett@void.ncsa.uiuc.edu (Mark Lanett)
Subject: Re: MPW 3.1 Libraries needed
Organization: University of Illinois at Urbana
Date: Tue, 14 Apr 1992 15:39:50 GMT

gl@giordano.enpc.fr.edu (Gilles LEFEBVRE) writes:

>I bought MPW 3.1 last year for investigation purpose. I intended to use
>it only 2 weeks ago in order to port some c and c++ code from SUN workstation.
>I realised that some libraries was missing 
>(Libraries:Libraries, Libraries:CLibraries, ...). Calling our french
>distributor of APDA, they were able to send me 3.2 Libraries. I have problems
>to compile c programs, but I could solve it by mixing 3.1 and 3.2 libs. But
>the c++ compiler (which is in fact a front precompiler) doesnt want to function
>properly.

The 3.1 and 3.2 libraries can't be mixed without changing the headers also. 3.2
uses new calling conventions for parameter passing -- some parameters are
passed in registers, and only the 3.2 headers have the parameter pragmas to
tell the compiler how it's supposed to work. But if you have the 3.2 headers
and libraries everything should be fine.

This presumes your compiler understands parameter pragmas. The 3.2 C compiler
does; I don't know about 3.1 C and know that gcc 1.37 *doesn't*. In one of
these cases you'll need the 3.1 *headers and libraries*.

The 3.2 headers and libraries are on ftp.apple.com, though I don't know what
the status is concerning ftp-ing them from France. Best bet for the 3.1 ones
would be an older developer's cd (Disky Business?).

I'm curious about your return address: fr.edu. Is .edu a worldwide hierarchy?
I thought it was w/in USA (USA-centric point of view here). I don't recall ever
seeing a non-USA site under the .edu domain.
-- 
Mark Lanett, Software Tools Group, NCSA; mlanett@uiuc.edu; NCSA.STG (AppleLink)
From: m89ewe@tdb.uu.se (Erik 'EWe' Widell)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Think Class Library discussion list
Date: 7 Apr 92 09:43:19 GMT
Organization: Dept. of Scientific Computing, Uppsala Univ.

jbm@hpgrla.gr.hp.com (Jim Moy) writes:
: >Is there a discussion list dedicated to the Think Class Library? If not I...
: >mind maintaining a mailing list and an archive here at Brown University.
: 
: I would also be interested in this.
: 
: Jim Moy
: Hewlett-Packard Greeley Hardcopy
: jbm@gr.hp.com

Yes, I'm also interested.
/Erik

--
-------------------------------------------------------------------------------
|      _____ __       __        Syntax errare humanum est.                    |
|     //     ||      //                                                       |
|    //__    || /|  // ___      email : m89ewe@tdb.uu.se                      |
|   //       ||/ | // //__\                                                   |
|  //_____   |/  |//  |___      University of Uppsala - Sweden                |
|                                                                             |
-------------------------------------------------------------------------------
From: wysocki@husc.harvard.edu (Chris Wysocki)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Popup menus - menuitems at runtime
Date: 16 Apr 92 21:06:19 GMT
Organization: Harvard University, Cambridge, MA

In article <1992Apr16.210258.1@summer.chem.su.oz.au>, wong_a@summer.chem.su.oz.au
writes:

> I want to use the new control for popup menus (IM VI 3-16) but I want to 
> set up the menu-items at run-time. Easy enough, once you can extract the
> MenuHandle from the control's contrlData field then you can do,
> 
> 	for (i=0;i<menuItemsCount;++i)
> 		AppendMenu(popupMenu,ArrayStrPtr[i]);
> 	ShowControl(popupCntl);
> 
> Unfortunately, the control is NOT updated until you've called TrackControl,
> which leaves the control Rect blank until the user clicks on it. Has
> anyone figured out a workaround for this problem, or I am just completely
> wrong about this.

The way I got around this problem was involved puting a single blank item in
the MENU resource and adding the items at runtime with code that looked like:

 	for (i=0;i<menuItemsCount;++i)
   if (i == 0)
    SetItem(popupMenu,1,ArrayStrPtr[i]);
   else
  		AppendMenu(popupMenu,ArrayStrPtr[i]);
 	ShowControl(popupCntl);

Not particularly elegant, I admit, but it works.

Chris Wysocki
wysocki@husc.harvard.edu
Newsgroups: comp.sys.mac.programmer
Subject: Need help with Finder AppleEvents...
From: rsherman@mthvax.cs.miami.edu (Roby Sherman)
Date: 15 Apr 1992 22:56:09 -0400
Organization: The Tao of Programming
Keywords: Need help with finder appleevents
NNTP-Posting-Host: mthvax.cs.miami.edu

Hi.

I am trying to put together a small pascal program that will send an "SOPE"
(Open Selection) Apple Event to the Finder. My program sends off the Apple
Event but nothing happens, which leads me to believe that I've done
something wrong as usual. ;-)  My only reference has been the "Finder
Events" stack off of FTP.APPLE.COM which is written far too topsy-turby for
me... I am looking for a very simple C or Pascal piece of code that
demonstrates how to put together and X-mit this Apple Event to the Finder.

		      Thanks in advance...
		      
				Roby
				
-- 
rsherman@mthvax.cs.miami.edu					Roby Sherman
Newsgroups: comp.sys.mac.programmer
From: krk@itl.itd.umich.edu (Kenneth Knight)
Subject: Re: refreshing a colour screen
Organization: Instructional Technology Laboratory, University of Michigan
Date: Wed, 15 Apr 92 17:34:59 GMT

In article <cmp9116.703254870@s1.sys.uea.ac.uk> you write:
>Pleae could someone help me on the subject of refreshing a screen
>after it has been overwritten when a dialog box has been displayed.
>I have no representation of what is on the screen, so redrawing it is
>a long process.  I have tried bitmaps, pixmaps, and offscreen drawing
>(using Apples Tech. note 120, but falls over on the For loop, and messes
>up the colour).  If anyone could tell me how to copy the screen pixels
>to a pixel map, and then copying it back again with the colour info.
>intact.
 
Very quickly. You will generaly do all drawing to a screen in one routine -
the routine that is called when an update event takes place. Up to that point
most times you will do your drawing in an offscreen graphic's world or repre-
sent it with some meta-language or some other mains depending on what you
deem best. In order to get the udpate events you have to invalidate the
rectangle (or region) that needs to be re-drawn. For simplicities sake just
invalidate the whole portRect of the window (I assume that is what you
have) that got covered by the dialog (naturally, it is better just to
invalidate the part that needs to be re-drawn). The call you need for this
is InvalRect().
 
Let's assume you are doing all your drawing to an 8-bit deep off screen
GWorld that you've made with NewGWorld (IM VI and note 120, and other
places). You've been very good about being sure to draw into that world
(i.e. Get/Set-GWorld calls in the right places and you do Lock/Unlock-Pixles()
calls before and after you do any drawing into this GWorld as you should).
 
To draw that GWorld to the screen you would do something like this (in your
function that handles update events):
if (theWindow /* WindowPtr passed in */ == windowToUpdate) {
   BeginUpdate(theWindow);
     EraseRect(&(theWindow->portRect)); /* clear it all out. */
     DrawControls(theWindow);       /* if you have 'em. */
     DrawGrowIcon(theWindow);      /* ditto */
     CopyBits(&((GrafPtr)drawWorld)->portBits, &((GrafPtr)theWindow)->portBits,
               &(theWindow->portRect), &(theWindow->portRect), srcCopy, nil);
   EndUpdate(theWindow);
 
The CopyBits() is the key call. It copies the offscreen GWorld to you
window. To be perfectly safe you should make sure that the foreground color
is black and background color is white (of the current grafport). This will
let you avoid any potental colorizing problems.
 
Hope this helps (I am in a rush...)...
From: plumpton@wampyr.cc.uow.edu.au (David Plumpton)
Newsgroups: comp.sys.mac.programmer
Subject: Bug in TCL CRunArray
Date: 9 Apr 92 06:06:25 GMT
Organization: University Of Wollongong

CRunArray::SetValue starts with:

tRunPtr  runs = *hRuns;

Although it doesn't look like the hRuns Handle can move during the routine,
it definitely can (and in my case did).

HLock that hRuns sucker before you have the chance to regret it.  Of course,
don't forget to HUnlock it at the end of the routine.
-- 
/------------------------------\ /-------------------------------\
I       David Plumpton          I     There is a holy trinity:    |
I plumpton@wampyr.cc.uow.edu.au I N Tesla, R Feynman and C Sagan  |
\------------------------------/ \-------------------------------/
From: scott@mcl.mcl.ucsb.edu (Scott Bronson)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Regular reading of a serial device-how?
Date: 14 Apr 92 18:35:40 GMT

In <D88-JWA.92Apr13090917@hemul.nada.kth.se> d88-jwa@hemul.nada.kth.se (Jon W{tte) writes:

>> mhkohne@jupiter.cs.umbc.edu (Michael Kohne) writes:

>   2) a way to get some code called regularly (every 10 ticks or so), but NOT
>   at interrupt level. I can't think of any way either of these can be done,
>   so I ask you: any ideas? 

>Or you could write a driver (DRVR) and have an INIT install it;
>DRVRs get regular time from SystemTask.

>Or you could patch one of the "regularies" like _OSEvent or
>_SystemTask - but that degrades system performance a lot.

DRVRs get time, but I wouldn't exactly call it regular.  If you NEED to
be called every 10 ticks, right now a VBL task is the only way I know
of to ensure you get the time.  Most applications (and much system
software) that I've seen don't release processor time when tracking
mouseDowns, so if the user holds down the mouse button for more than
ten ticks (which is not uncommon), you could be left high and dry...

	- Scott
Newsgroups: comp.sys.mac.programmer
From: krk@itl.itd.umich.edu (Kenneth Knight)
Subject: Re: Mapping one color to another - help!
Organization: Instructional Technology Laboratory, University of Michigan
Date: Wed, 15 Apr 92 17:01:59 GMT

In article <1992Apr14.152106.5674@eng.umd.edu> russotto@eng.umd.edu (Matthew T. Russotto) writes:
>In article <1992Apr14.120824.12158@terminator.cc.umich.edu> krk@itl.itd.umich.edu (Kenneth Knight) writes:
>>I need some more help....
>>
>>I am writing a image processing tool that will re-map one color to another.
>>Specifically, all the pixels in an image (32 bit deep GWorld) of the specified
>>color will have their color changed to the current foreground color. I thought
>>that using the SetEntries() toolbox call to modify the 32-bit deep GWorld's
>>CLUT would make sense, but I can not figure out where the current color, the
>>one that will be changed, is in the CLUT. Nor am I sure just what goes in
>>the CSpecArray.value field. 
>
>32-bit GWorlds do NOT have useful color tables.  They are 'direct
>mapped', meaning each pixel value is $aarrggbb, where a = alpha
>channel, r = red, g = green, b = blue.  The color table is ignored.
>You have to iterate through the values in the pixmap and actually
>change the pixel values.

Alright, as an aside. I managed to do what I needed with a costum
search proc (and the documentation on those is really wierd. I am
not quite sure what the result param is for...). I followed a 
standard one I found and it works, but it only works for GWorld's
that are 32 bits deep. I applied it to the same GWorld set to 8
bits deep and nothing happened. 

Ideas anyone?

(Hey, Matthew, nice to see you are still around. Tell
everyone else I am too....and it might be that the U.M. cops
would get along with you EVEN BETTER than UMCP's...)

Newsgroups: comp.sys.mac.programmer
From: mkelly@mystix.cs.uoregon.edu (Michael A. Kelly)
Subject: C.S.M.P. Digest v1 #44 Available
Organization: University of Oregon Computer and Information Sciences Dept.
Date: Tue, 7 Apr 1992 12:47:25 GMT


C.S.M.P. Digest             Tue, 07 Apr 92       Volume 1 : Issue 44

Today's Topics:

	Speech synthesis toolkit
	Using Think C with the new Apple #includes
	Tail Patches
	Using Think C with new #includes, part II
	 MacApp3 & C++
	Question about SWIM programming
	char to keycodes
	New Programmer Needs Help!!
	Speaker-independent continuous-speech recogni
	How do I pass a string to an object in THINK C?
	FixMul tip
	Very Simple Questions
	"Please insert disk ^0" Help
	Error recovery in THINK C (was Re: Suggestion to the Developers of Think C)


The Comp.Sys.Mac.Programmer Digest is moderated by Michael A. Kelly.

These digests are available (by using FTP, account anonymous, your email
address as password) in the pub/mac/csmp-digest directory on ftp.cs.uoregon.
edu.  This is also the home of the comp.sys.mac.programmer Frequently Asked
Questions list.

These digests are also available via email.  Just send a note saying that you
want to be on the digest mailing list to mkelly@cs.uoregon.edu, and you will
automatically receive each new digest as it is created.

The articles in these digests are taken directly from comp.sys.mac.programmer.
They are not edited; all articles included in this digest are in their original
posted form.  The only articles that are -not- included in these digests are
those which didn't receive any replies (except those that give information
rather than ask a question).  All replies to each article are concatenated
onto the original article in the order in which they were received.  Article
threads are not added to the digests until the last article added to the
thread is at least one month old (this is to ensure that the thread is dead
before adding it to the digests).

Send administrative mail to mkelly@cs.uoregon.edu.

-- 
_____________________________________________________________________________
Michael A. Kelly                                         University of Oregon
mkelly@cs.uoregon.edu                             Computer Science Department
_____________________________________________________________________________
From: ksand@apple.com (Kent Sandvik)
Newsgroups: comp.sys.mac.programmer
Subject: Re: MMU dcmd??
Date: 9 Apr 92 02:50:20 GMT
Organization: MacDTS Mongols

In article <249@farallonfarallon.com>, neal@farallon.com (Neal Trautman) writes:
> 
> Anyone have a dcmd, for MacsBug or TMON Pro,
> that will allow me to manipulate the MMU and
> "write-protect" an area of memory??

> I need to figure out who's writing garbage on top
> of my CODE resources.

SADE 1.4a1, on ETO#6, has memory address MMU protection
(heh, something good with SADE...).

Cheers,
Kent Sandvik, Dynamic Language Prophet
Newsgroups: comp.sys.mac.programmer