HDTenEightyP/NetNews huggingface dataset:
From: jsp@uts.amdahl.com (James Preston)
Newsgroups: comp.sys.mac.programmer
Subject: Re: vrefNum from Path Name
Date: 5 Sep 92 00:05:53 GMT
Reply-To: jsp@pls.amdahl.com
Distribution: usa
Organization: Amdahl Corporation, Sunnyvale CA

paul@svl.cdc.com (Paul Kohlmiller) writes:

}lari@strauss.cs.unc.edu (Humayun Lari) writes:

}>In article <Btwwt5.7Bv@taligent.com> keith@taligent.com (Keith Rollin) writes:
} [says to always use FSMakeFSSpec and not create a FSSpec on your own.]
}>What about when the file/directory you're referring to does not exist?
}>If I remember correctly, FSMakeFSSpec checks to make sure that it does, so
}>it would return an error code when you're trying to create an FSSpec prior to
}>performing a Save As... Or am I wrong about this? Keith?

}My reading of IM6 seems to say that you will get an error but the
}FSSpec is still good. Haven't tried it.
}Other Opinions welcome.

I can vouch for this.  FSMakeFSSpec returns the file not found error, but
goes ahead and makes a valid FSSpec for the missing file (i.e. the vRefNum
and dirID fields reference the correct folder, and the name field contains
the name of the non-existant file).  A very handy feature.  But do remember
that FSSpecs are only found on System 7.

--James Preston

Newsgroups: comp.sys.mac.programmer
From: niko@iastate.edu (Nikolaus E Schuessler)
Subject: Re: 68000 Assembler Wanted ?
Organization: Iowa State University, Ames, IA
Date: Thu, 10 Sep 1992 13:02:43 GMT

In article <1992Sep9.085333.26340@cc.uow.edu.au> kamclo@cc.uow.edu.au (Kam Lo Lo) writes:
>	I'm just new to Mac, but would like to know is there any PD or
>	shareware 680x0 assembler available. (tell me the FTP sites if
>	possible).
>
 You could struggle getting gas to work on the mac (if you have some
sorta c compiler). This would however require a bit of mucking with
object code to get it in the right format...


-- 
Niko Schuessler               
Project Vincent Systems Manager              email: niko@iastate.edu
Iowa State University Computation Center     voice: (515) 294-1672
Ames IA 50010                                snail: 272 Durham
From: mxmora@unix.sri.com (Matthew Xavier Mora)
Newsgroups: comp.sys.mac.programmer
Subject: PathNameFromDirID (pascal source)
Date: 14 Sep 92 22:19:45 GMT
Followup-To: comp.sys.mac.programmer
Organization: SRI International


Here is a non system 7 dependant version of the Pathname trilogy.
It returns a handle, not a lame Str255 of the full pathname.

Why am I posting all this? To get it into the next version of the 
UMPG of course. :-) Hopefullly it will be out before MacWorld SF. Yes I'm
actively working on it.

If anyone has any code that they would like to share (or update stuff that
has been in the first volume), send it along and I'll include it, if it
works.

{-------------------------------------------------------------------------}
{Path Name From DirID                                                     }
{by Matthew Xavier Mora                                                   }
{9-14-92                                                                  }
{Given a vrefNum and a directory Id, this function will return a handle to}
{the full path name. It creates the handle as it goes. It does not have   }
{the limited string length (255) problem like the ones I have seen.       }

{ Also most assumed there would be no errors so it just tested until      }
{ block.ioDrDirID = 2. Which for the most part is true but as your        }
{ debugging your application you will find that sometimes its not true or }
{ will never get there.                                                   }
{ It is based on source code from Apple DTS.                              }
{ Don't forget to dispose the handle when you are done with it.           }
{-------------------------------------------------------------------------}

 function PathNameFromDirID (DirID: longint; vRefnum: integer): Handle;

  var
   Block: CInfoPBRec;
   directoryName: str255;
   err: integer;
   HaveAux: boolean;
   h: Handle;
   theSize: Longint;
   delimiter: Char;
 begin
	PathNameFromDirID:=nil;
  haveAUX := false;   {Use whatever function to determine if your running
under AUX}

  h := Newhandle(0);

  if (h = nil) then 
     exit(PathNameFromDirID);
   
  with block do
   begin
    ioNamePtr := @directoryName;
    ioDrParID := DirId;
   end;

  repeat
   with block do
    begin
     ioVRefNum := vRefNum;
     ioFDirIndex := -1;
     ioDrDirID := block.ioDrParID;
    end;
   err := PBGetCatInfo(@Block, FALSE);

   if haveAUX then
    begin
     if directoryName[1] <> '/' then
      begin
       delimiter := '/';
      end;
    end
   else
    delimiter := ':';

   theSize := longint(length(directoryName) + 1);
   directoryName[length(directoryName) + 1] := delimiter;
   theSize := Munger(h, 0, nil, 0, Ptr(ord(@directoryName) + 1), thesize);
  until (block.ioDrDirID = 2) or (err <> noerr);

  PathNameFromDirID := h;
 end;
From: rgonzal@gandalf.rutgers.edu (Ralph Gonzalez)
Newsgroups: comp.sys.mac.programmer
Subject: Help: app can't open prefs file with SOME systems
Keywords: quickbasic
Date: 1 Sep 92 12:48:02 GMT
Organization: Rutgers Univ., New Brunswick, N.J.


Has anyone seen this problem?

I'm writing an app with QuickBASIC, which finds the Preferences folder
and stores a prefs file therein. Thereafter [how's that for archaic
English usage?] it loads the contents of the prefs file whenever you
run the app.

This usually works fine. However, in two cases (one a Mac Plus/Sys
6.0.7, the other a IIfx/Sys 7.0) my app creates the file fine the
first time it is run but crashes when trying to load the prefs every
time I run it thereafter.

When I run it under the interpreter on these same machines, the
problem doesn't arise (this is a common frustration when using
QuickBASIC!). I tried removing all cdevs and inits from the Mac
Plus/Sys 6.0.7 combo but it didn't clear up the problem. Yet, when I
rebooted with another copy of Sys 6.0.7 my app ran fine even though I
copied the prefs file which had formerly caused problems to the new
System. (That is, the prefs file itself is not corrupt.)

I haven't been able to track the problem down any further; I was just
wondering whether anyone else had experienced this sort of thing...

Thanks for any (email) replies,
Ralph
-- 
Ralph Gonzalez, Computer Science, Rutgers Univ., Camden, NJ
Phone: (609) 757-6122; Internet: rgonzal@elbereth.rutgers.edu
--
Newsgroups: comp.sys.mac.programmer,comp.sys.mac.misc
From: howard@netcom.com (Howard Berkey)
Subject: Re: Opinions on THINK Reference?
Date: Tue, 08 Sep 92 08:01:46 GMT
Organization: Netcom - Online Communication Services  (408 241-9760 guest) 

In article <ksand-070992133416@wintermute.apple.com> ksand@apple.com (Kent Sandvik) writes:
>In article <1992Sep6.152213.12596@miavx1.acs.muohio.edu>,
>psweeney@miavx1.acs.muohio.edu wrote:
>> Is Symantec's THINK Reference worth it?  It doesn't support
>> IM VI, and I have heard of no upgrades.  However, I have
>> seen a friend's copy, and it looks pretty useful.
>
>Currently the sold Think Reference does not have all the IM VI
>information.
>
>I've seen that bundle sold for less than $50, I would rather 
>spend the money on this nice package, than sit and have six
>huge volumes always open on my small table.

I agree... it's the best spent money on tools I've shelled out yet.

>
>I'm eagerly awaiting the day when all important programming references are 
>integrated to development environments. 411, Blue Notes and 
>Think Reference is just the first generation of lookup tools.

Yes! 

>
>Kent
>"I would rather have a thousands idiots attacking my position, than
>have one idiot helping to defend it."	[Paraphrased from Voltaire]

sorry man, this idiot had to agree w/you.  Maybe 1k idiots will wait for the
sys 7.5.5/pink/newtonOS version of the reference.

-Howard


-- 
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
Howard Berkey						howard@netcom.com
"Jesus Christ, How many people does it TAKE to kill the President?"
		-John Dillinger, in _Illuminatus!_
Newsgroups: comp.sys.mac.programmer
From: kamclo@cc.uow.edu.au (Kam Lo Lo)
Subject: 68000 Assembler Wanted ?
Organization: University Of Wollongong
Date: Wed, 9 Sep 92 08:53:33 GMT

	I'm just new to Mac, but would like to know is there any PD or
	shareware 680x0 assembler available. (tell me the FTP sites if
	possible).

	Thanks in Advance.

	K.C Lo
	kamclo@wampyr.cc.uow.edu.au

Newsgroups: comp.sys.mac.programmer
From: John Champion <dedjhc@arco.com>
Subject: Re: Patching the _Launch Trap
Organization: Arco Alaska Inc.
X-Useragent: Nuntius v1.1
Date: Tue, 8 Sep 1992 14:51:00 GMT

In article <abrn6k+.leonardr@netcom.com> Leonard Rosenthol,
leonardr@netcom.com writes:
>	Welcome to the wonderful world of "protected patches".  This is a
>new trick in System 7 to make sure that programmers don't "screw up"
system
>patches.  It basically means that it is near impossible to patch such a
trap.
>
>	If you could post what you are trying to accomplish by patching _Launch
>someone could probably suggest an alternate approach that would be
successful.

I need FSSpec type information on applications and associated documents
that are launched, particularly by the finder.  Unfortunately, not all
applications accept apple events so I can't just check for those.

-John Champion      dedjhc@arco.com
From: Joe.Francis@dartmouth.edu (Joe Francis)
Newsgroups: comp.sys.mac.programmer
Subject: Re: simulating page-flipping via cluts
Date: 14 Sep 92 20:55:33 GMT
 <MHALL.92Sep6135523@occs.cs.oberlin.edu> 
 <18ja83INNk53@agate.berkeley.edu> 
 <1992Sep10.182147.25618@hobbes.kzoo.edu>  
 <1992Sep11.030344.1@vax1.umkc.edu>
Organization: Dartmouth College, Hanover, NH
X-Posted-From: InterNews1.0a4@newshost.dartmouth.edu

Is this the technique that someone was trying to claim a software
patent on?
Newsgroups: comp.sys.mac.programmer,comp.sys.mac.system,comp.sys.mac.games
From: og@access.digex.com (Gary Goldberg)
Subject: Re: Need INIT to *reduce* screen size.
Keywords: extension INIT reduce screen size games etc
Organization: Personal Account - Digital Express Greenbelt, MD
Date: Sat, 12 Sep 1992 12:42:22 GMT

There is a control panel called MiniScreen that will do what you are looking for. It is probably available in sumex, although if you don't find it there, I
would try umich. No clue whether is is S7 compatible, and what video it
requires, but it is what you're looking or otherwise. - Gary

-- 
- Gary Goldberg og@access.digex.com Bowie, MD KA3ZYW
And NO organization to represent. ' ... Free, free at last ...'
Info on 'The Simpsons'? Let me know.
From: ar4@sage.cc.purdue.edu (Piper Keairnes)
Newsgroups: comp.sys.mac.programmer
Subject: System Error #25 at _Jackson
Date: 6 Sep 92 21:27:02 GMT
Distribution: na
Organization: Purdue University

I'm using ThinkC 5.0 updated to 5.0.1 on a Mac IIci System 7.0 (tuneup) in
32-bit mode.

Every time I try to step through a program with the debugger, I get a System
Error #25 with MacsBug left at a label called _Jackson. I do not get this
error when I opt-Step. I can only step about 3-5 times before the Debugger
crashes. If I set a Debugger() somewhere within the code, I can only step
3-5 times from that point.

The project runs fine without the debugger. There are no possible memory
problems within the lines of code that are being stepped through. i.e.
stepping through some ToolboxInit() code that I've used consistently with no
problem in the past.

I've reinstalled ThinkC 5.0 and tried running with and without the 5.0.1
patch. I'm downloading the 5.0.2 patch now, but don't really think it will
solve the problem. I've tried running with absolutely no INITs.

I've tried 32-bit mode and 24-bit mode also. Nothing seems to work. I've
tried everything I can think of to make the Project compile differently. It
looks like it is a true Debugger problem.

After installing ThinkC 5.0.2 update, if that doesn't work I'll reinstall
System 7.0 (w/ TuneUp).

Has anyone run into such a problem before? Can anyone give me a suggestion?
I'm pretty much stuck for now because I need to use the debugger.

-- 
Piper Keairnes - Computer Science   ** PUCC Consultant for money. **
INTERNET: ar4@sage.cc.purdue.edu    **   Mac programmer for fun.  **
Newsgroups: comp.sys.mac.programmer
From: reuven@athena.mit.edu (Reuven M. Lerner)
Subject: Is a dirent.h available for Think C 5.0?
Organization: Massachusetts Institute of Technology
Date: Wed, 9 Sep 1992 04:01:47 GMT

I'm working on my first Mac program (which also happens to be my
bachelor's thesis), and I've run into a few problems. The most major
one so far appears when I try to compile some code that was written
for a Unix box, and that I'm trying to incorporate into my code. (The
Unix software is part of the WAIS -- Wide Area Information Server --
package from Thinking Machines; among other things, my thesis will act
as a primitive WAIS client.)

Anyway, Think C 5.0 appears to be choking on variables of type struct
dirent. This sort of makes sense, since dirents appear in Unix
machines, and aren't really applicable to Macs. Nevertheless, I
haven't been able to figure out a way around this problem -- somehow
or other, I think I'm going to need dirents on the Mac.

Does anyone know how to do this? Is it a simple case of defining the
structure in an include file, and then using Think C's Unix library
functions for accessing files? Do I have to rewrite some functions and
structure definitions? Or have I stumbled onto a major hole in the
library, and should I look somewhere else for information?

Thanks for any help you can provide.
From: urlichs@smurf.sub.org (Matthias Urlichs)
Newsgroups: comp.sys.mac.programmer
Subject: Re: updating window text / getting text lines from buffer
Date: 10 Sep 1992 13:38:30 +0200
Organization: University of Karlsruhe, FRG
NNTP-Posting-Host: 127.0.0.1

In comp.sys.mac.programmer, article <zben-280892150237@zben-mac-ii.umd.edu>,
  zben@ni.umd.edu (Charles B. Cranston) writes:
> In article <1992Aug25.232449.12720@kronos.arc.nasa.gov>,
> joshr@kronos.arc.nasa.gov (Joshua Rabinowitz-Summer-91) wrote:
> 
> > a file documented somewhere in IM for getting the filemanager to
> > parse files into lines delimited by any desired char ('\n' in this case)
>  
[ PBRead{A}Sync example deleted ]

Depending on what you're doing, though, it may be a lot faster if you
allocate a largish buffer and just read your lines out of it.
PBRead is _slow_ if used unbuffered. I once wrote a TIFF reader and dropping
my own stupid buffer into the read procedure made the file reader five times
faster.

-- 
Why does the porridge bird lay her egg in the air?
-- 
Matthias Urlichs  --  urlichs@smurf.sub.org -- urlichs@smurf.ira.uka.de   /(o\
Humboldtstrasse 7 -- 7500 Karlsruhe 1 -- Germany  --  +49-721-9612521     \o)/
Newsgroups: comp.sys.mac.programmer
From: bberqu@sagpd1 ()
Subject: Color Questions
Keywords: color
Date: Mon, 14 Sep 1992 22:56:45 GMT


Hi, 

A couple of questions: Has anybody ever had the problem in Think C 5.0 when
you launch the think debugger it corrupts the System File, its happened to
me twice, when it happened I'd reboot the mac and get the welcome to mac
dialog followed by the desktop with no windows and a menu bar with 
nothing in it, and the cursor changing from the watch to the pointer 
over and over and over?

In an application I'm writing I've got a color menu with three different
menu items each having a color icon to the left of the menu item (you
know just like the Labels menu on the desktop), Now when you select
each one of the menu Items it brings up the Color Picker, my problem is
how do I make the color Icons in the menu change to the color selected
with the color picker?

Third question, when I set say the red/green/blue guns to something other
than full intensity or 0 intensity, I don't get the color except the full
intensity or 0 intensity guns. For instance say I wanted pink, and set the
red/green/blue values to something which is pink, I don't know off hand
what that is, however, it would not show up pink, but maybe red.  It does
show up pink after I select the color picker within the app and select pink.  
I suspect I'm not initializing something which the Color Picker does.  Any 
help would be appreciated.  I am using a CWindowPtr by the way. 

Thanks in advance

Brian
Newsgroups: comp.sys.mac.programmer
From: bohus@math.lsa.umich.edu (Geza Bohus)
Subject: Q: How does ATM know which bitmapped/Type-1 pairs are the same?
Date: Tue, 08 Sep 92 22:45:29 EDT
Organization: University of Michigan, Mathematics Department, Ann Arbor

Hi People,

As the sublect says, I'd like to know how ATM figures out if a
bitmapped font is the same as a Type-1 font. Since the fontnames
contain all sorts of abbreviations, ATM has to figure out somehow if a
font in the System and its Type-1 version in the Extensions folder
belong to each other. I was trying to look at some pairs that work and
some that don't and couldn't figure it out. (By 'doesn't work' I mean
a Type-1 font which doesn't get loaded even though there is a
bitmapped font installed with the same name.)

Please send email.

AdvaThanksnce,

gb
From: jeremyr@dcs.qmw.ac.uk (Jeremy Roussak)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Patching the _Launch Trap
Date: 10 Sep 92 17:54:27 GMT
Organization: Computer Science Dept, QMW, University of London

In <BuCLzq.A7z@taligent.com> keith@taligent.com (Keith Rollin) writes:

>In article <1992Sep9.172136.13700@dcs.qmw.ac.uk>, jeremyr@dcs.qmw.ac.uk (Jeremy
>Roussak) writes:
>>
>> The other problem with patching _InitGraf is that it doesn't
>> move memory, so neither can (should) your patch. We won't get
>> into the "all traps move memory because of patches" here! You
>> can argue that unexpectedly moving memory within _InitGraf
>> probably won't matter because of the way in which apps call it,
>> but it's a little unsafe. _InitFonts, on the other hand, does
>> move memory and is usually called immediately after _InitGraf.

>You make a good point concerning patching _InitGraf. I had thought about it at
>the time, but went ahead and patched it, figuring that I was safe for the
>reasons you gave.
>>
>> When is _InitAllPacks called?
>>

>After your application is loaded, but just before its entry point is called.

Are you sure this is correct? I just tried trapping with
MacsBug on _InitAllPacks: the file dcmd fails to show that the
application's resource file is open, CurMap is
FinderPreferences and CurApRefNum is the Finder. (SE/30, 7.0
tuned). If the app's resource file isn't available, it's tricky
to find it's details. CurApName is correctly set up, though.

Jeremy
Newsgroups: comp.sys.mac.programmer
From: bwilliam@iat.holonet.net (Bill Williams)
Subject: Re: How do I mount a SCSI device?
Organization: HoloNet (BBS: 510-704-1058)
Distribution: comp
Date: Mon, 7 Sep 1992 08:32:26 GMT

Newsgroups: comp.sys.mac.programmer
From: croyer@atg.amex-trs.com (Chuck Royer)
Subject: RCS for Macintosh
Date: Thu, 10 Sep 1992 19:52:04 GMT
Reply-To: croyer@atg.amex-trs.com
Organization: American Express Advanced Technology Group
Followup-To: comp.sys.mac.programmer

Does anyone have a version of RCS that runs on the MAC?  We have software
that is under RCS on UNIX and want to do the same on the MAC.  Please
send e-mail replies to "Vincent_Tapia%qm@atg.amex-trs.com".  We will
summarize if there is interest.

Thanks in advance.

-- 


- Chuck Royer
From: vnguyen@sdcc13.ucsd.edu (Vuong Nguyen)
Newsgroups: comp.sys.mac.programmer
Subject: pictures
Keywords: Vuong
Date: 15 Sep 92 07:17:27 GMT



???????????

	I have a picture drawn by a MS Window software and saved in
a .TIF formated file.  Does anyone know how to import this picture
file to a Macintosh.   I tried to use SuperPaint, MacDrawII, .... to
retrieved the picture after the convert the IBM .TIF into Mac .TIP ,
but I failed .

Thank you very much and I really appreciate this.

Vuong Nguyen
vnguyen@sdcc13.ucsd.edu

Newsgroups: comp.sys.mac.programmer
From: thomask@lobo.rmhs.colorado.edu (Thomas C Kerrigan)
Subject: Re: Problem with DrawString and ScreenSavers.
Date: Fri, 11 Sep 1992 23:37:47 GMT
Distribution: comp.sys.mac.programmer
Organization: Rocky Mountain High School
X-Newsreader: Tin 1.1 PL5

Newsgroups: comp.sys.mac.programmer
From: potts@itl.itd.umich.edu (Paul Potts)
Subject: Re: THINK C linker makes me sad
Organization: Instructional Technology Laboratory, University of Michigan
Distribution: usa
Date: Wed, 9 Sep 1992 13:07:16 GMT

In article <1992Sep09.054939.1042@km4ba.uucp> alan@km4ba.uucp (Alan Barrow) writes:
>In <1992Sep8.085120.24380@reed.edu> bowman@reed.edu (Eric Bowman (bobo)) writes:
>
>>In article <fdrny7c.howard@netcom.com> howard@netcom.com (Howard Berkey) writes:
>>>So I was writing this really small, simple app. (a mac version of xclock,
>>>just for fun.)  It was only 3k.  Then I added a call to sprintf().  It 
>>>exploded the program to 22k.

If all you want is sprintf for things like ints and strings, you can use
ANSI-Small. I use ANSI-A4 in my XCMDs, and it only adds about 6K.


-- 
"...remove protective cap. Hold atomizer with thumb at base and nozzle 
between first and second fingers. Without tilting head, insert nozzle into 
nostril. Fully depress rim with a firm, even stroke and sniff deeply."
-advice for presidential candidates from Paul Potts - potts@itl.itd.umich.edu
Newsgroups: comp.sys.mac.programmer
From: e-sink@uiuc.edu (Eric W. Sink)
Subject: Re: Shareware compilers
Originator: sink@ux2.cso.uiuc.edu
Reply-To: e-sink@uiuc.edu
Organization: University of Illinois at Urbana
Date: Thu, 10 Sep 1992 13:50:36 GMT

Glenn Stauffer <stauffer@cc.swarthmore.edu> writes:

>In article <1992Sep6.083131.25903@terminator.cc.umich.edu> Michael
>Dautermann, dauter@terminator.cc.umich.edu writes:
>> LA/HARVESTC   1,524    6/27/92     BinHex4.0,Compact1.33
>> /mac/development/languages/harvestc1.2.cpt.hqx
>>
>>    Freely-distributable C compiler and editor.  It's  standalone, but
>>    it's also compatible with MPW-C.  You can create projects,
>>    compile, build/link.  Even  supports a couple of Pragmas.  Minimal
>>    editor does the job. 
>>

>If I'm correct, the Harvest C product is not entirely complete - the docs 
>mention that some support libraries need to be obtained from Apple.  I 
>believe that they are freely available via FTP from apple.com.

What a lovely opportunity to bash the Apple legal department !

Yes, Harvest C is "incomplete" in the sense that it requires the MPW
headers and libraries.  (It's also "incomplete" in the sense that there
are still bugs, but then, you do have the source code... :-)  Actually,
I tried to get permission to distribute those headers and libs with
Harvest C.  I made MANY phone calls to Apple Licensing.  I mailed them
snail mail as well as AppleLink mail.  They sent me information THREE
times about licensing totally unrelated things.  I never even got to
the point where they understood what I wanted to do.

How many lawyers really know what a header file is ?

-- 
Eric W. Sink, Spyglass        | "Kill 'im.  Kill 'em all." - Cpt. James Hook
1800 Woodfield Drive          |
Savoy, IL  61826              |
---- e-sink@uiuc.edu ---------|---------- 217-355-6000 -----------------------