HDTenEightyP/NetNews huggingface dataset:
From: Glen.Stewart@f175.n2240.z1.ieee.org (Glen Stewart)
Subject: RE: RTF definition/interpretation...somebody goofed!!? HELP!! (medium
Organization: FidoNet node 1:2240/175 - The Associati, Grand Blanc MI
Date: Fri, 21 Aug 1992 13:50:11 GMT

Microsoft IS quite close-mouthed about the RTF format, so I hear.  I noticed a 
drastic change in how they handled the Word 4.0 RTF coding, compared to the
Word 5.0 coding.  I wrote a C program to convert RTF 4.0 to simple formatted
text, and it failed to work on 5.0.

I have a set of XCMDs on my BBS to convert to/from RTF in a HyperCard field. 
I can also put the C code online if you like.



--  
=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=
 Glen Stewart - Internet: Glen.Stewart@f175.n2240.z1.ieee.org
Newsgroups: comp.sys.mac.programmer,comp.sys.mac.system
From: bberqu@sagpd1 ()
Subject: Color Icons
Keywords: coloricon
Date: Wed, 26 Aug 1992 23:38:00 GMT

Hi,

I'm trying to create some color icons using ResEdit in 256 color mode, so
I create the Icons with certain colors (like yellows/oranges ...) just 
fine, I copy them to the scrap and then paste them into the getinfo 
window, however, most of the (if not all) orange/yellow colors don't
show up when the icon is pasted, all shades of the blues show up just
fine.  I also tried the apple colors pallete in ResEdit also with oranges 
and reds, still no success.  I hope this isn't a FAQ, Any explanations 
would be appreciated.

Programmers question:

I'm trying to use ModalDialog with a filterProc function which will
handle popupmenus,  when I call ModalDialog and just let it sit there
no mouse movement or anything, after a while, I get, I believe a system
error #26 according to MacsBug, all my filter proc function does is 
return (TRUE), I've also tried FALSE.  My impression from IM is that
ModalDialog sits there and waits for a mousedown event within the dialog
and when it gets either a itemhit or incontent or whatever, it then calls 
the filterProc function (if defined), is this true? I assume that it 
passes the dialog poointer/event record pointer/itemhit pointer, is this 
true?  It looks like its calling my filterProc constantly, if this is true 
do I need handle events within the filterProc?  Assuming all my parameters
are correct for filterProc are correct, what am I doing wrong?

An explanation of how ModalDialog and the filterProc functions work with
each other would be nice.

Thanks in advance

Brian
Newsgroups: comp.sys.mac.programmer
From: zben@ni.umd.edu (Charles B. Cranston)
Subject: Re: updating window text / getting text lines from buffer
Followup-To: comp.sys.mac.programmer
Organization: UM Home for the Terminally Analytical
Date: Fri, 28 Aug 1992 23:48:55 GMT

In article <zben-280892150237@zben-mac-ii.umd.edu>,
zben@ni.umd.edu (Charles B. Cranston) wrote:

> var
> 	junk:	Integer;
> 	Buff:	Packed Array[0..255] of SignedByte;
> 	PBRec:	ParamBlockRec;
> begin		
> 	PBRec.ioRefNum := theFile;
> 	PBRec.ioBuffer := @Buff;
> 	PBRec.ioPosMode := $0D80;  <<----80 is read till EOL bit, 0D is CR!
> 	PBRec.ioPosOffset := 0;
> 	PBRec.ioReqCount := 256;
> 	junk := PBReadASync(@PBRec);
                 ^ urp!
> 	UseText(PBRec.ioActCount,@Buff);

Yeah, I tried to get funky and replace PBRead(@PBRec,False) on
the fly and got it wrong.  It should be PBReadSync not ASync.

zben@ni.umd.edu     -KA3ZDF
Newsgroups: comp.sys.mac.programmer
From: cfejm@ux1.cts.eiu.edu (John Miller)
Subject: OK buttons overlaying PICTs:  Help, please
Date: Sat, 29 Aug 1992 18:48:34 GMT
Organization: Eastern Illinois University


Hi All,

What am I missing?  Creating a simple modal dialog in ResEdit, I have a
PICT that covers the whole dialog area.  My OK dismissal button needs to
sit on top of the PICT.  Either the button gets overdrawn or doesn't
respond to clicks--depending on numbering of DITL items.

(Is this a FAQ?)

Thanks for any help.

John

-- 
John Miller
Music Theory
Eastern Illinois University
Newsgroups: comp.sys.mac.programmer
From: reed@snake.tc.cornell.edu (Michael G. Reed)
Subject: Re: Hacking Think_C Malloc, need big free!
Followup-To: comp.sys.mac.programmer
Reply-To: reed@Theory.TC.Cornell.EDU
Organization: Cornell National Supercomputing Facility
Date: Tue, 1 Sep 1992 12:06:52 GMT

In article <1992Aug31.223642.1858@bnr.ca>, brunner@crchh447.bnr.ca (James Brunner) writes:
|> Howdy, I'm working on a kludge where I am combining several UNIX utilities.
|> Each of these allocates memory and it gets freed automatically at exit(0).
|> I would like to be able to free all malloc-allocated memory between calls
|> to these utils.  I've looked at alloc.c but it's all in asm and hard to read.
|> 
|> How can the library be modified to add a free_all routine?

If I remember correctly, ThinkC's malloc (and calloc for that matter) are 
simply mapped into calls to the memory manager call NewPtr.  Therefore, the
only way to "free-all" would be to free everything in the heap (which would
be VERY bad, because you would free your code as well...).  I'm not sure how
to do it (I don't have IMs here at work yet), and for that matter, I'm not
sure this would even work, but I think you could create a new heap, set your
current heap (zone?) into that heap, do all your allocation and then simply
destroy the heap for your "free-all".  Sound plausible?

-Michael

-----------------------------------------------------------------------------
Michael G. Reed                                  (reed@Theory.TC.Cornell.edu)
Cornell National Supercomputing Facility                       (607)/254-8806
-----------------------------------------------------------------------------
        Why be normal, it's boring; and boring people should be shot.

Note:  These are not the views of my employer (and probably not mine either).
Newsgroups: comp.sys.mac.programmer
From: leonardr@ccs.itd.umich.edu
Subject: Re: ??? AppleEvents - sending > 32K 
Originator: leonardr@diddley.ccs.itd.umich.edu
Keywords: AppleEvents 32K barrier
Organization: Campus Computing Sites, University of Michigan-Ann Arbor
Date: Wed, 26 Aug 1992 03:33:38 GMT

In article <1992Aug25.235916.3393@athena.mit.edu> decanio@athena.mit.edu (Ken DeCanio) writes:
>
>I am trying to send more than 32k of data by a single AppleEvent.
>I've tried using an AEDescList, but I get an AppleTalk error (-92)
>
        As of the Apple Event Manager 1.0 (and 1.0.1), you can NOT send 
more than 64K worth of data in a single AERecord (which would include a 
DescList).  Future versions of the AEM will support much olarger data
passing, but in the meantime your best bet is to use either multiple events
or create a PPC link (using AE's to setup the link).


-- 
-----------------------------------------------------------------------
Leonard Rosenthol		  Internet: leonardr@ccs.itd.umich.edu
Director of Advanced Technology   AppleLink: MACgician
Aladdin Systems, inc.		  GEnie:     MACgician
Newsgroups: comp.sys.mac.programmer
From: Glen.Stewart@f175.n2240.z1.ieee.org (Glen Stewart)
Subject: RE: PROGRAMMING IN BASIC
Organization: FidoNet node 1:2240/175 - The Associati, Grand Blanc MI
Date: Tue, 18 Aug 1992 14:22:38 GMT

Mary-

What basic compiler are you using?  If it's ZBasic, I have some source code
here that can help.  If it's QuickBasic, I can't help, since they structure
programs much different.

Drop in on the BBS, or FREQ the file called MITAT using password GRACE.


--  
=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=
 Glen Stewart - Internet: Glen.Stewart@f175.n2240.z1.ieee.org
Newsgroups: comp.sys.mac.programmer
From: rudim@cs.kuleuven.ac.be (Rudi Maelbrancke)
Subject: Projects to be converted in Think Pascal.
Organization: Dept. Computerwetenschappen K.U.Leuven
Date: Thu, 3 Sep 1992 14:09:57 GMT

Hello,

I have a problem opening some example projects which are accompaning 
plug in cards for Macintosh.

When I open the projects, I get a message saying: The project name has to be
converted (compressed) before proceeding...

When I click OK the file is enlarged but seems to contain no files.
(No references in the project).

Does anybody knows what a compressed or converted project means?

I'm using system 7.0 and still THINK Pascal 3.0

Rudi Maelbrancke,

Please E-mail me.

Rudi.Maelbrancke@cs.kuleuven.ac.be

Thank you!
From: mcmath@csb1.nlm.nih.gov (Chuck 'Amnesia causes.... uh, I forget' McMath)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Human Interface questions, specific functionality
Date: 28 Aug 92 12:25:03 GMT
Followup-To: comp.sys.mac.programmer
Organization: MSD

In article <1992Aug27.230932.11741@verity.com>, anders@verity.com (Anders
Wallgren) wrote:
> 
> In article <1992Aug27.175328.1@tesla.njit.edu> Elliotte Rusty
> Harold, erh0362@tesla.njit.edu writes:
> >	2.  A user opens a file on a locked disk and makes changes to it.
>  
> >	(Alternately the user locks the disk while the file is open.) 
> When
> >	the user attempts to save should I 
> >	
> >	  a)  Simply post an error message saying the disk is locked? 
> >	  b)  Check that the disk is locked before every save (If so
> how?) 
> >	  and if it is do a Save As instead?
> >	  c)  Check that the disk is locked before every save  
> >	  and eject the disk and post a dialog asking the user to unlock
> >	  and reinsert it?
> 
> If the user opens a file that is locked or that is on a locked
> volume, you should probably warn them that any changes they make
> can't be saved to that file.  You might still enable Save and treat
> that command like Save As (or treat it like they're saving a new
> document).
> 
	I would think that when you open a file on a locked volume you should do
this:

1. Put up a dialog telling the user they can't change this file
2. Disable 'Save', but of course leave 'Save As' enabled.
3. If they do a 'Save As' to another volume, the file becomes 'changeable',
because it's not the same file they opened.

This seems to make sense.

In the case where someone opens a file, ejects the diskette, locks it,
reinserts it and tries to save, you'd get a file manager error when the
save is attempted.  I would put up an error dialog and just go on.  If they
insist on trying to save to a locked volume they deserve what they get.

chuck
 
|- chuck mcmath - mcmath@csb1.nlm.nih.gov - MSD, Inc. ------------|
|- National Library of Medicine - National Institutes of Health --|
|- Bethesda, MD 20894 - <clever message on vacation until Sept 1> |
|- "Hey batter, hey batter, hey batter, swing" - Anon. -----------|
From: steve.herman%express@freedom.msfc.nasa.gov (Steve Herman)
Newsgroups: comp.sys.mac.programmer
Subject: Question: Unmounting server volumes
Date: 1 Sep 92 21:49:33 GMT
Followup-To: comp.sys.mac.programmer
Organization: BCSS

Hello everyone,

   I'm having a peculiar problem when attempting to unmount server volumes
using PBUnmountVol.  

   If an application is running off of the server volume I get error -47
fBsyErr (file is busy).  That's OK.  If I quit the running application the
error goes away and PBUnmountVol works.

   However, if a file from the server volume is in the trash, I get the
same -47 error.  But when I then either empty the trash *OR* select the
item in the trash and choose "Put Away", and again call PBUnmountVol the
-47 error remains.

   I can drag the server to the trash from the Finder and it unmounts OK. 
But I can't get it to unmount from my application?!?

   A co-worker seems to think this problem may be related to open Working
Directories which still point to the server volume.

MY QUESTIONS:

   What do I need to do to clear this error?

   Also, the Finder can differentiate between "open files" and "files in
the trash" because you get a different alert message when unmounting in
these situations, can I do this too?

Thanks in advance...

----------------------------------------------------
- Steve Herman - BCSS
- Boeing Computer Support Services
- Huntsville, AL
----------------------------------------------------
From: landwebe@math.rutgers.edu (Peter Landweber)
Newsgroups: comp.sys.mac.programmer
Subject: Problem writing INIT/cdev
Summary: trying to get the Finder to open a
	 Control Panel that is already open
Date: 3 Sep 92 05:53:43 GMT
Distribution: comp
Organization: Rutgers Univ., New Brunswick, N.J.



     I am working on an INIT/cdev combination to be used under System
7, and I've run into a problem.
     At startup time, the INIT moves its resource map after the system
resource map in the linked list, and it patches CloseResFile() to
ignore the file.  The result is that my file stays open, and its
resources are always available.  This is similar to what Suitcase II
does with font suitcases.  So far everything has gone extremely well 
using this technique.
     Now, I'm trying to add a "cdev".  The problem is that when the
finder opens up my file as a Control Panel, it expects my file's
resource map to be the first in the linked list.  Since the resource
map is actually at the end of the linked list, the finder crashes.

So, my questions are:
1)  Is there a way for the Finder to open up a Control Panel if the
file is already open, and its resource map is not at the front of the
linked list?
2)  Is there a way to open a file twice, with two separate resource
maps?  That way, I could still have one resource map linked after the
system resource map, and the other at the front of the linked list.
One of the maps could be read-only if necessary.

Any suggestions, answers, or solutions would be greatly appreciated.

-- Greg Landweber  (landwebe@math.rutgers.edu)
From: Marc Tamsky <u_banzai@mcl.ucsb.edu>
Newsgroups: comp.sys.mac.programmer
Subject: UDP Programming Examples (where?)
Date: 28 Aug 1992 00:27:55 GMT
Organization: Banzai Institute for Strageic Information & Biomedical Engineering
Distribution: world
NNTP-Posting-Host: dial-slip43.ucsd.edu
X-UserAgent: Nuntius v1.1.1d7
X-XXDate: Thu, 27 Aug 92 17:27:28 GMT

Where can I find a site, (or someone could mail me) some UDP programming
examples for the mac?

Thanks
----------
u_banzai@mcl.ucsb.edu    	  KB6JWE		 Marc Tamsky

In New Salem, ND stands the worlds largest Holstein Cow.
12000#, 38' H, 50' L.....	it's fiberglass!
From: pollansw@cse.fau.edu (Warren Pollans)
Newsgroups: comp.sys.mac.programmer
Subject: yacc/lex -like utilities for thinkC?
Date: 26 Aug 92 20:45:09 GMT
Organization: Florida Atlantic University, Boca Raton, FL, USA

Are there utilities like the unix yacc and lex available for use
with thinkC?  I'm taking a compiler-writing course and would like
to do as much as possible of the project (1000-1500 lines) at home
on my SE (2.5M, probably expanded to 4M).  At worst, I can write
and test modules at home and put the whole thing together on the
unix system (sunOS).

Any other compiler-writing tools available to be used with thinkC?

Thanks,

Warren

(pollansw@cse.fau.edu)
Newsgroups: comp.sys.mac.programmer
From: Michael Brennan <mikeb@sam.amgen.com>
Subject: Re: THINK Reference
Organization: Amgen
X-Useragent: Nuntius v1.1
     <John_Shepardson.esh-210892101457@moose.slac.stanford.edu>
Date: Wed, 2 Sep 1992 21:37:19 GMT

In article <John_Shepardson.esh-210892101457@moose.slac.stanford.edu>
John Shepardson, John_Shepardson.esh@qmail.slac.stanford.edu writes:
>I agree that Think C ref is great, but it doesn't yet contain Sys 7 info.
>A big disadvantage is that is does not have much low level stuff...
>I have also noted quite a few inaccuracies in it.  

I've noticed quite a few inaccuracies in it, too.  It bothers me that in
all the time it has been out, Symantec has not bothered to offer a single
update to correct the numerous bugs and typos in the program.  One could
easily get the impression that the program has been virtually abandoned
by Symantec as far as support and further development for the product is
concerned.

While I agree that Think Ref is great, anyone considering purchase of the
product should be aware of this total lack of attention to the product by
Symantec since it's initial release.  Don't expect the inaccuracies in it
to be fixed; Symantec doesn't seem to care.
Newsgroups: comp.sys.mac.programmer
From: walkerj@math.scarolina.edu (Jim Walker)
Subject: Questions on UnmountVol and SetFileInfo
Organization: USC  Department of Computer Science
Date: 30 Aug 92 17:52:06 GMT


(1)  Inside Mac IV says that PBUnmountVol will close any open files on a
volume it's unmounting.  But when you drag a volume to the trash in Finder,
Finder calls UnmountVol, and if there were open files on the volume, the
call fails with a fBsyErr.  That error is not listed as one of the
possibilities in the PBUnmountVol documentation.  What's going on?

(2)  I traced a crashing INIT to the fact that _SetFileInfo was calling
NewDialog.  It created a dialog with 4 userItems and one button named
"Stop", but never actually displayed the dialog.  Can anyone tell me what
this dialog is for?

--

 -- Jim Walker  USC Dept. of Math.  walkerj@math.scarolina.edu
Newsgroups: comp.sys.mac.programmer
From: kemper@millelac.rhrk.uni-kl.de (Michael Kemper [Informatik])
Subject: Re: THINK Reference
Reply-To: kemper@millelac.rhrk.uni-kl.de (Michael Kemper [Informatik])
Organization: University of Kaiserslautern (Germany)
Date: Tue, 25 Aug 1992 10:37:20 GMT

If that is true it is really late (two years after the release of system 7)!

|\/|ichael |<emper              +++++++++++++++++++++++++++++++++++++++++++++++
University of Kaiserslautern    + Must I say this?                            +
Germany	                        + This is my own personal opinion...          +
kemper@rhrk.uni-kl.de           +++++++++++++++++++++++++++++++++++++++++++++++
 
Newsgroups: comp.sys.mac.programmer
From: gurgle@netcom.com (Pete Gontier)
Subject: ignoring first few CDEF draw messages
Date: Wed, 02 Sep 92 06:03:49 GMT
Organization: cellular
Keywords: CDEF draw message ignor control

I've just recently dug up an old popup menu CDEF I wrote oh-so-long
ago. It's quite spiffy -- as long as you're interested only in
Western script systems and don't care about icons or color.
 
I gave myself a tour through the code to make it look like the way
I indent code these days and found some pretty weird stuff.
Apparently I found it necessary to maintain some flags for each
control which were relevant when the control lived in a dialog. The
CDEF is ignoring the first couple of draw messages. I vaguely
remember something about badly sized or positioned ghost images
appearing in the dialog when the CDEF didn't ignore the first few
draw messages. Anybody have any experience with this? Is there a
way around it? I'd love to get rid of those flags.
-- 
 Pete Gontier // EC Technology // gurgle@netcom.com
From: lari@strauss.cs.unc.edu (Humayun Lari)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Keeping the cursor visible
Date: 2 Sep 92 21:54:21 GMT
Organization: The University of North Carolina at Chapel Hill

In article <15119@claris.com> wombat@claris.com (Scott Lindsey) writes:
>In article <Btwnq8.LMv@mentor.cc.purdue.edu>, neath@brazil.psych.purdue.edu (Ian Neath) writes:
>> 
>> writes to the TextEdit record, the cursor is hidden by (I assume) a
>> call to ObscureCursor.  Is it OK to keep calling ShowCursor ...
>
>ShowCursor won't actually show the cursor if it's only obscured.  I don't
>think there's a legal way to unobscure a cursor, however, setting the low-
>memory global CrsrNew = 0xFF forces it to really redraw.

If you're in charge of the writes to the TextEdit record (i.e. using TEKey),
you could use TEInsert instead to prevent TextEdit from trying to be polite
and calling ObscureCursor. Of course, TEInsert may be a bit slower, but in
practice it seems to make little difference. And it's definitely *much* cleaner
than having the cursor flicker every time a character is appended to the TE
record (especially if you're porting a MS-DOS-based language interpreter that
thinks a row of dots on the screen is a beautiful depiction of its progress).

Humayun Lari
(lari@cs.unc.edu)
From: bayes@hplvec.LVLD.HP.COM (Scott Bayes)
Date: Tue, 1 Sep 1992 21:42:38 GMT
Subject: Re: Re: GetKeys, Events, Sound Manager
Organization: Hewlett-Packard Co., Loveland, CO
Newsgroups: comp.sys.mac.programmer

I'm trying to get QuickBASIC Rev 1.00E (sys 7 compatible) to do high
resolution printing on my DeskWriter.  I have an SE.  I can't get there
from here.

I have the graphics (LINE and TEXTBOX graphics) nicely on my CRT at 72
dpi.  Now, I want to send them to my DW at its highest resolution, using
1 or 2 pixel wide lines rather than the 1 point size on the screen.  I'd
like the picture to be about the same size as on the CRT, but to take
advantage of the 300 dpi of the DW.

If I just redirect the picture to LPT1:, it comes out at 72dpi in
roughly WYSIWYG size.  I want 300 dpi at the same size.

I've tried 

OPEN "LPT1:" FOR OUTPUT AS #2
WINDOW OUTPUT #2         ' to use printer resolution
PICTURE ON
CALL PENSIZE(1,1)

<draw picture scaling everything up by factor of 4 [300dpi/72dpi]>

PICTURE OFF
CLOSE #2

This seems to send the picture to the printer right away (I thought it
was redirected to PICTURE$ instead).  If I now do

Image$=PICTURE$
OPEN "LPT1:" FOR OUTPUT AS #2
WINDOW OUTPUT #2
PICTURE (0,0)-(506,295),Image$  ' default coords of QB output window on SE

I expect the picture to be printed scaled down 4x so it's the same size
(96%) as on the screen, but rendered to the resolution of the DW
(300dpi).  Instead, I get something about 4 times as big as I expect,
with 1 point lines, seemingly smoothed to 300 dpi, but with line
endpoints on a 72 dpi grid.  Text done with TEXTBOX is the right size.

It's as though LINE in QB worked in points rather than pixels, and
PICTURE did not rescale the Image$ to the rectangle specified.

Can anyone help?

ScottB
Newsgroups: comp.sys.mac.programmer
From: mpradhan@medicine.adelaide.edu.au (Malcolm Pradhan)
Newsgroups: comp.sys.mac.programmer
Subject: GetPictInfo bug with QuickTime Picts?
Date: 28 Aug 92 00:12:22 GMT
Organization: Faculty of Medicine, University of Adelaide
X-UserAgent: Nuntius v1.1.1d9
X-XXMessage-ID: <A6C3A66612013808@baldrick.medicine.adelaide.edu.au>
X-XXDate: Fri, 28 Aug 92 17:46:14 GMT

Hello all,

 I'm using GetPictInfo to request a 256 colour palette from a 32 bit
image. Normally this works fine and I simply set the window's palette
to the one returned by GetPictInfo and copybits using ditherCopy, ie.

	err= GetPictInfo((PicHandle)pictH, &pictInfoRec, returnPalette,
						256, popularMethod, 0);
	SetPalette(myWindow, pictInfoRec.thePalette, TRUE);

 I have found that if the PICT is quicktime compressed (JPEG, Video)
no palette is returned and no error is signalled from the GetPictInfo
call - pretty frustrating.

 The only way I can see of getting around this is to create an gworld,
draw the compressed PICT into it and then GetPixMapInfo. Tedious and
memory intensive!

 Has anyone found a way of getting a clut or palette from a QT compressed
PICT? Is this a known bug which will soon be fixed in System 7.1 and
QT 1.5? :-)

Regards
Malcolm
_________________________________________________________________
    Malcolm Pradhan
    Medical Computing, Faculty of Medicine         _--_|\
    University of Adelaide, South Australia       /      \
    InterNet: mpradhan@medicine.adelaide.edu.au   \_.--x_/
    Fax: +618 223 2076  :x marks the spot:              v