HDTenEightyP/NetNews huggingface dataset:
From: Michael Brennan <mikeb@sam.amgen.com>
Subject: Re: TCL archives
Organization: Amgen
X-Useragent: Nuntius v1.1
Date: Wed, 7 Oct 1992 00:22:57 GMT

In article <dx3uv972.fcta61@moebius.cubetech.com> Peter Creath,
peterc@cubetech.com writes:
>Where's the FTP site where all the shareware/freeware TCL classes
>are archived?

The only one I know of (and it is a very good one) is at ftp.brown.edu.
From: mxmora@unix.SRI.COM (Matt Mora)
Newsgroups: comp.sys.mac.programmer
Subject: Re: problem with my dialog filter
Date: 9 Oct 92 00:28:01 GMT
Organization: SRI International, Menlo Park, California

In article <D88-JWA.92Oct8205414@byse.nada.kth.se> d88-jwa@byse.nada.kth.se (Jon Wtte) writes:

>You should use _Delay, which is a system call that does just
>this, but also calls SystemTask. It might also do other
>things in the future. Doing only this is really bad, since
>there may be drivers that need time often.

I would hate to disagree with Jon but I don't think delay calls systemtask.
I think it just stuffs LMG "ticks" into d0 , adds the delay amount and loops
until "ticks" is bigger than d0. 

I created my own Delay function that calls WNE with the sleep at 1 tick. It 
works ok.


Matt







-- 
___________________________________________________________
Matthew Mora                |   my Mac  Matt_Mora@sri.com
SRI International           |  my unix  mxmora@unix.sri.com
___________________________________________________________
Newsgroups: comp.sys.mac.programmer
From: absurd@applelink.apple.com (Tim Dierks, software saboteur)
Subject: Re: Event loop with appevents
Date: Fri, 16 Oct 1992 00:40:43 GMT
Distribution: comp.sys.mac.programmer
Organization: MacDTS Marauders
Followup-To: comp.sys.mac.programmer

In article <ALESKINE.92Oct15230248@cardhu.cs.hut.fi>, aleskine@cs.hut.fi
(Arto Leskinen) wrote:
> 
> Does anyone have sample how to make up an event loop that uses apple
> events for real work. So when user clicks Quit, it will send quit 
> apple event to itself. How slow would it be?

Very fast; if you send the AppleEvent using the kCurrentEvent constant
to specify the destination process, virtually no time will be spent sending
the event (the event is actually delivered and dealt with before
AESend returns).  Let me put it this way: a lot more time is spent
flashing the "Quit" item in the menu after the user selects it than
how long it will take to dispatch this event.  (Constructing it
also take a little time, but that should be fast too).

> What is PPC, program to program communication? How it differ from apple
> events.

The PPC Toolbox is the more generalized platform upon which AppleEvents
are built.  You can use the PPC toolbox to communicate with other
processes in a general fashion; AppleEvents adds a structure and a
grammar to that communication; it is AppleEvents that allows
unrelated applications to communicate.

Tim Dierks
MacDTS, but hey!
From: thepope@bigboy (Michael Kohne)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Dynamic Change of Mouse Tracking Speed
Date: 15 Oct 92 00:27:33 GMT
Organization: Temple University

ralex@tigger.cs.Colorado.EDU (Repenning Alexander) writes:
: 
: I am dealing with the visual representation of complex data structures.
: I like to experiment with the Mouse Tracking Speed to make it easier
: for users to track on important information: "soft snapping".
: 
: Is there some simple way to change the mouse tracking speed (e.g. via
: a trap)?  What I need is a function allowing me to adjust mouse
: tracking to speeds like the ones avaivable in the MOUSE CDEV (very
: slow, .., fast). How is the MOUSE CDEV doing it?
: 
: Any ideas, clues?
: 
:   Thanks,  Alex

I don't know how to change the mouse tracking speed, but I do know that it is
more complex than 1 number. If you can find someone with a Kensington Turbo
Mouse, and the Turbo Mouse control panel, have them show you the 'custom' 
settings. Basically, the mouse tracking speed is a series of 8 thresholds
that tell the system how to repond to mouse movements of varying lengths and
speeds. I don't know where these numbers reside in memory during run-time,
however. It may be that you could simply use macsbug to figure out what 
resource the Mouse Control panel is messing with in the system.

"Pope" Q.E.D
Michael Kohne
thepope@bigboy.cis.temple.edu
House of the Techno-Discordians, Archery Amusements Division
<twang!>
Newsgroups: comp.sys.mac.programmer
From: ksand@apple.com (Kent Sandvik)
Subject: Re: MPW ToolServer?
Date: Fri, 16 Oct 1992 02:42:13 GMT
Organization: Apple
Followup-To: comp.sys.mac.programmer

In article <1992Oct14.133015.25030@Arco.COM>, jrowney@arco.com wrote:
> 
> Simple question -- what is it and where can I get it if I need it?

Toolserver is available from ETO#9 and other ETO CDs, and I do think
you could get it when you order Object Master. It's a background server
(with a small window) that executes MPW tools from other applications
that sends it Apple Events. Nothing hinders to write your own ToolServer,
the AE suite is documented in the ETO documentation. Actually I should post
them here. Sorry, have to go home, my wife called and she's ANGRY when
I'm late for dinner. Tomorrow.

Kent
-------------------
Kent Sandvik (UUCP: ....!apple!ksand; INTERNET: ksand@apple.com)
DISCLAIMER: Private activities on the Net.
From: brunner@crchh447.bnr.ca (James Brunner)
Newsgroups: comp.sys.mac.programmer
Subject: Anyone have a bar-graph/progress monitor?
Date: 7 Oct 92 15:42:26 GMT
Reply-To: brunner@crchh447.bnr.ca (James Brunner)
Organization: Bell-Northern Research, Richardson, Tx

Looking for a bar-graph/event handler routine to indicate progress.  I'm porting
a UNIX program and what I really need is a routine that I can call periodically
that will:
    * Indicate progress (I can pass it a percent, etc)
    * Handle update events to the progress monitor
    * Handle suspend/resume events for the app
    * Allow execution of other tasks (multi-process stuff)

If someone has code that I can reuse, I would hate to re-invent the wheel.

Thanks, please reply by e-mail (save some bandwidth).
-- 
---------------------------------------------------------------------------
Jim Brunner - (brunner@bnr.ca)
All opinions are my own and have nothing whatsoever to do with BNR, NT,
NTI, Bell Canada, or any of the BCE corporations or affiliates.
From: de19@umail.umd.edu (Dana S Emery)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Think C++??
Date: 10 Oct 92 10:18:06 GMT
Followup-To: comp.sys.mac.programmer
Organization: Personal

In article <1992Oct9.195615.29886@gn.ecn.purdue.edu>,
jess@gn.ecn.purdue.edu (Jess M Holle) wrote:
> 
> Any idea as to how long before Think C goes C++?  Will it ever?


I'd like to see the present code shaken down a bit more before it gets
extended again, bugs aside (not that they dont need attention, they do, and
not just for quadras, see recent csmp posting), I have concerns about the
adequacy of project management.  

I have asked them to implement a project <-> makefile capability, which
would allow plaintext archival of project files (stripped of object/library
content of course).  

I have also asked them for a "Save Stripped Project" capability, so that I
dont need a 10 Mb hole in my HD, just so that I can archive projects to
preserve them from foolish debugger corruptions.

IMHO, both features are necessary, the first allows human readout/cross
platform usage, the second is a simple, fairly cheap conveniance, which
helps us to compensate for the primary weakness of the debugger (its
tendency to fail and corrupt the project in the process).
--

Dana S Emery <de19@umail.umd.edu> | "Novo, de Novo,
                                  |     de novo, de no-o-o-o-o---, 
                                  | Novemba come an' dey gonna go home."
Newsgroups: comp.sys.mac.programmer
From: J074870@LMSC5.IS.LMSC.LOCKHEED.COM
Subject: RE: Primer Problem
Organization: Lockheed Missiles & Space Company, Inc.
Date: Fri, 16 Oct 92 00:31:45 GMT

------------------------- Original Article -------------------------
From: krl@alpha.sunquest.com (ken r. lauver)
Newsgroups: comp.sys.mac.programmer
Subject: Question about a program in Mac C Prog Primer Volume 1
Date: 15 Oct 92 21:57:00 GMT
Organization: Sunquest Information Systems, Tucson AZ
News-Software: VAX/VMS VNEWS 1.4-b1

Has anyone entered the programs from Dave Mark and Cartwright Reed's
book Macintosh C Programming Primer Volume 1, Second Edition?  In
particular the Reminder.c project/program is getting a compile error
in the CopyDialogToReminder function (page 325 in my book).  It is
trying to set up a notification manager variable if the LaunchCheckBox
item has been checked.  I know the short section of code may lead to
more questions about other variables and stuff.  If anyone has found
this to be a problem too, how were you able to correct the problem.

The section of code reads:

GetDItem( dialog, iLaunchCheckBox, &itemType, &itemHandle, &itemRect );

if (reminder->launch = GetCtlValue( (ControlHandle)itemHandle) )
   reminder->notify.nmResp = &LaunchResponse;
/*   this statement has the  ^  compiler saying that an invalid
     pointer operation is    !  being attempted.        */

else
   reminder->notify.nmResp = &NormalResponse;
/*   same thing for this     ^  statement too
************                 !                          */
The problem you have here is a bug from the author.
Basically, you have two different pointers involved.
Place (ProcPtr) infront of both &LaunchResponse and &NormalResponse.
(IE: (ProcPtr)&LaunchResponse;  ).  Another problem you will have is
with the define kDialogResID.  Your dialog is 128 not 129.  Drop the +1
off of kBaseResID+1.
   OSErr                    err;
Did you get the eventtrigger to send the four high level messages?  I
didn't.

Finally, you will run into a problem with the NEW REMINDER dialog.  When
you select the LAUNCH box.  A selection window appears for the program
you want to launch.  Well the OK and CANCEL keys from NEW REMINDER obviously
get deactivated.  Well after you select or cancel your program option. The
two buttons are not reactivated.  I have not figured this one out.
I would hate to go on to the next chapter without getting this
Hope this helps out.

Matt Shember.

Newsgroups: comp.sys.mac.programmer
From: Anders Wallgren <anders@verity.com>
Subject: Re: scanf equivalent calls that does not use global variables?
Organization: Verity, Mountain View, CA, USA
Date: Thu, 8 Oct 92 16:17:23 GMT
X-Xxmessage-Id: <A6F9AE77AB01C897@pokey.verity.com>
X-Useragent: Nuntius v1.1.1d12
X-Xxdate: Thu, 8 Oct 92 17:23:03 GMT

In article <RMF.92Oct7164515@chopin.cs.columbia.edu> Robert M.
Fuhrer, rmf@chopin.cs.columbia.edu writes:
>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.

I think these use globals as well - use the toolbox calls.
Newsgroups: comp.sys.mac.programmer
From: Meessen@slig.ucl.ac.be  (Christophe Meessen)
Subject: Think C bug (updated) SOLVED !
Followup-To: comp.sys.mac.programmer
Organization: Universite Catholique de Louvain (Belgium)
Date: Wed, 7 Oct 1992 10:51:35 GMT

Thanks to all of you who answerd my question !

I forgot to include <stdio.h> !

This would have poped to my eyes if I the prototype checking flag was set.

I'll teach this to my friend.

Bien cordialement,

                           Christophe MEESSEN
Newsgroups: comp.sys.mac.programmer
From: tj@kona.cs.ucla.edu (Tom Johnson)
Subject: sizeof(AThinkCObject) ?
Organization: UCLA, Computer Science Department
Date: Thu, 15 Oct 92 15:59:11 GMT



The Think C 5.0 manual tells me:

  "You cannot use the sizeof operator to take the size of a class name or
   of an object.  This use was allowed in THINK C 4.0."


So, how can I do it?  I need to know how big an object is (I need to allocate
space for a array of object created with "new_by_name").
I can't use GetHandleSize or GetPtrSize, since I don't know whether
they are direct or indirect objects, can I?  

<oops.h> contains the following structure:
	/*  class info format  */

typedef struct {
  Ref	superclass;	/*  0 for root class (MUST BE FIRST)  */
  Ref	allocator;	/*  "operator new" (0 if none)  */
  Ref	deallocator;	/*  "operator delete" (0 if none)  */
  Ref	constructor;	/*  "X::X()" (0 if none)  */
  Ref	destructor;	/*  "X::~X()" (0 if none)  */
  long	size;	/*  # bytes in object of this class  */
  short	dispatch;	/*  offset back to dispatch table (+1 for indirect)  */
  char	name[];	/*  class name (0-terminated)  */
} ClassInfo;

But I don't know if I should be getting my info from here....seems kind of
like using low memory globals -- possible incompatibilites with future
upgrades.

 
Any suggestions?

Tom
-- 
Tom Johnson             "They say Confucious does his crossword with a pen."
tj@cs.ucla.edu                               -Tori Amos
Newsgroups: comp.sys.mac.programmer
From: thor@vivaldi.psu.edu (Thomas Moertel)
Subject: How can I associate a TDialogBehavior with a view using ViewEdit?
Organization: Pennylvania State University
Distribution: comp
Date: 8 Oct 92 04:38:35

I can't seem to figure out how to associate a TDialogBehavior with a
TWindow using ViewEdit.  _The Programmer's Guide to MacApp_ claims,
"To make a dialog window modal, you need to associate a
TDialogBehavior object with it, which you can do with ViewEdit."  (Ch.
12) However, neither the Programmer's Guide nor the Guide to MA Tools
says how to do this.  Tinkering with ViewEdit has not revealed the
solution either.

It seems to be possible, though, because DemoDialogs pulled it off:
the Format dialog's view resource has "TDIALOGBEHAVIOR" embedded in
the window description.  So, the big question is, can it be done from
ViewEdit?  And if it can, how does one go about doing it?

Thanks for the help!



--

Tom Moertel                 Pennsylvania State University
thor@vivaldi.psu.edu        "Them bats is smart. They use radar!"  ;-)
Newsgroups: comp.sys.mac.programmer
From: absurd@applelink.apple.com (Tim Dierks, software saboteur)
Subject: Re: MPW Question
Date: Thu, 15 Oct 1992 22:07:27 GMT
Organization: MacDTS Marauders
Followup-To: comp.sys.mac.programmer

In article <1992Oct15.135831.26391@alias.com>, Reid Ellis <rae@Alias.com>
wrote:
> 
> Keith Rollin <keith@taligent.com> writes:
> |I got one, too. Looks like this:
> |
> |AddMenu Special "Unmangle Name/U" 'set temp "`catenate
> |"{Active}.<opt-6>"`";  Alert -s "`UnmangleTool "{temp}"`"'
> |
> |That's all one command line; any line breaks are provided by your friendly
> |neighborhood newsreader.
> 
> <Bruce.Hoult@bbs.actrix.gen.nz> writes:
> |Why use two statements when one will do?  :-)
> |
> |AddMenu Special "Unmangle Name/U" \d
> | 'Alert -s `UnmangleTool \d`Catenate "{active}.\6"\d``'
> |
> |[  \d means <option>-d,  \6 means <option>-6  ]
> 
> My preference is for in-place unmangling.  A bit more verbose, but I
> like it [\x is options-x, \. is option-. etc etc]
> 
>     AddMenu Misc 'Unmangle/U' \d
>         'Begin; \d
>             target "{active}"; \d
>             set str `cat "\6"`; \d
>             set unstr "`unmangle {str}`"; \d
>             if "{unstr}" =~ /Unmangled symbol: (\x)\r1/; \d
>                 set unstr "{\r1}"; \d
>             end; \d
>             replace "\6" "{unstr}"; \d
>             rotateWindows; \d
>         End > Dev:Null \. Dev:Null'
> 
> The only thing about this is that it *requires* that at least 2
> windows be open.  Ergle.

OK, if we must:

AddMenu {Key} 'Unmangle/U' \d
    'set tempSym `catenate "{active}".\6`; \d
    if "`unmangletool "{tempSym}"`" =~ /Unmangled symbol: (\x)\r1/; \d
        echo -n "{\r1}" > "{active}".\6; \d
    end; '

I don't know why I think anyone might care, but it doesn't
require two windows, only uses one variable, and executes faster.
Nyaahh.

By the way, for you Think folk, this is why I use MPW (No, not because
we have to unmangle function names); because all I have to do is click
on a header file name and hit command-option-d to open the file out
of the CIncludes folder.  I can look up function prototypes with one
key-click or menu selection.  I can get whole paragraphs of text from
Inside Mac with one command key.  The whole system is so customizable
and powerful compared to Think's editing environment; I couldn't live
without it. (OK, that's an exaggeration).

Tim Dierks
MacDTS, but I speak for myself
Newsgroups: comp.sys.mac.programmer
From: ross@bnr.ca (Ross Brown)
Subject: Re: Apple Events! How to locate a service?
Organization: Bell-Northern Research Ltd.
Date: Thu, 8 Oct 92 15:56:41 GMT

In article <yjc-071092151355@b61539.student.cwru.edu> yjc@po.cwru.edu (Jerome
Chan) writes:
>
>  Apple Events is a cool way to communicate between various applications.
>However, I noticed a drawback. It doesn't have a services directory.
>Everytime there is a need to locate a particular application
>service/server, I've got to fiddle around with the PPC thingies. If the
>application/server providing the service is not running, there is no way my
>application can find out where the server/application is located, launch it
>and continue (with the user's consent of course!).

Well, there's no sure-fire programmatic way of doing it in System 7, but if
your local program knows that the remote application/server has a certain PPC
port name, or a certain NBP entity type alias assigned by PPC, and your machine
has an alias to the application/server somewhere on its disk, then everything
you describe can be done by a program on your machine without alerting the
user, with the requisite combination of IPCListPorts, StartSecureSession, and
remote Finder AEs.  This amounts to implementing a services directory on the
*client* machine rather than the *server*, which may not be what you want, but
it works.

A directory server capability of the sort you describe could be built into the
client program on the standard of signatures.  PPC allows servers to register
themselves on the network on a creator/type basis, so client programs can use
signatures to check whether a server is running.  The desktop database has a
call (PBDTGetAPPL) which can find the location of the server program given its
signature.  Once your client program mounts the remote volume where the server
program lives, you can use PBDTGetAPPL with ioVRefNum referring to the remote
volume.  The resulting value in ioAPPLParID gives you the exact directory,
which you can easily search to find the server program.  Make an alias, send a
'sope' AE to the remote Finder, and voila.

I'd like to see the result, once you get it working!

==============================================================================
Ross Brown, Dept. 7C22  < Bell-Northern Research     >  Just the facts, ma'am.
Advisor, Telemgmt Svcs  < P. O. Box 3511, Station C  >  We don't care whose
ross@bnr.ca             < Ottawa, ON, Canada K1Y 4H7 >  opinions yours aren't.
==============================================================================

Newsgroups: comp.sys.mac.programmer
From: k044477@hobbes.kzoo.edu (Jamie R. McCarthy)
Subject: Re: Event Manager Too Slow or izzit just me?
Organization: Kalamazoo College
Date: Tue, 13 Oct 1992 19:48:21 GMT

scott@mcl.ucsb.edu (Scott Bronson) writes:
>d88-jwa@byse.nada.kth.se (Jon Wtte) writes:
>>
>>Okay, why are you checking for WaitNextEvent?
>
>Hey, I still check simply because it takes no time,

You are obviously using a meaning of the word "no" with which I am
not familiar.  :-)

>>1) System 6 way: GetOSEvent.
>>2) System 7 way: Kill all apps but me.
>
>Or, finally, a technique that works under all systems that I know
>of: don't use an event loop.  Simply use GetKeys and Button...

Allow me to provide the obligatory reminder to anyone who's going to do
this:  it's considered polite to inform the user that you're deactivating
the rest of her computer.  I suggest a notice on a splash screen or
options screen, something like:  "To obtain maximum smoothness, this
arcade game will temporarily stop the rest of the computer.  For
example, file sharing and modem transfers will not work while the game
is in play." (This suitably-newbie message should suffice both for games
that don't give time, and for games that kill all other processes, I
think.)
-- 
 Jamie McCarthy      Internet: k044477@kzoo.edu      AppleLink: j.mccarthy
 "Magic Johnson says he attended two scheduled meetings [of] the president's
  AIDS commission, one more than Mr. Bush credited him with during Sunday's
  debate [and] one more than any of the three members of the Bush cabinet..."
From: mkelly@mystix.cs.uoregon.edu (Michael A. Kelly)
Newsgroups: comp.sys.mac.programmer
Subject: C.S.M.P. Digest V1 #180 Available
Date: 10 Oct 92 07:49:55 GMT
Article-I.D.: cs.1992Oct10.074955.13617
Followup-To: poster
Organization: University of Oregon Computer and Information Sciences Dept.


C.S.M.P. Digest             Fri, 09 Oct 92       Volume 1 : Issue 180

Today's Topics:

	Storing Windows
	THINK C 5.0 Code overflow
	GCC under MPW Shell.
	Altering the TRAP dispatch table.
	how to put indelible serial# in resource fork of app?



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

The digest is a collection of article threads from the internet newsgroup
comp.sys.mac.programmer.  It is designed for people who read c.s.m.p. semi-
regularly and want an archive of the discussions.  If you don't know what a
newsgroup is, you probably don't have access to it.  Ask your systems
administrator(s) for details.  (This means you can't post questions to the
digest.)

Each issue of the digest contains one or more sets of articles (called
threads), with each set corresponding to a 'discussion' of a particular
subject.  The articles are not edited; all articles included in this digest
are in their original posted form (as received by our news server at
cs.uoregon.edu).  Article threads are not added to the digest 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 digest).  Article threads that
consist of only one message are generally not included in the digest.

The entire digest is available for anonymous ftp from ftp.cs.uoregon.edu
[128.223.8.8] in the directory /pub/mac/csmp-digest.  Be sure to read the
file /pub/mac/csmp-digest/README before downloading any files.  The most
recent issues are available from sumex-aim.stanford.edu [36.44.0.6] in the
directory /info-mac/digest/csmp.  If you don't have ftp capability, the sumex
archive has a mail server; send a message with the text '$MACarch help' (no
quotes) to LISTSERV@ricevm1.rice.edu for more information.

The digest is 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 issue as it is created.  Sorry, back issues
are not available through the mailing list.

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


-- 
_____________________________________________________________________________
Michael A. Kelly                                         University of Oregon
mkelly@cs.uoregon.edu                             Computer Science Department
_____________________________________________________________________________