HDTenEightyP/NetNews huggingface dataset:
From: piovanel@ghost.dsi.unimi.it (marco piovanelli)
Subject: Saving window position
Organization: Computer Science Dep. - Milan University
Date: Mon, 25 Jan 1993 14:09:57 GMT
Summary: How do I save window positions without changing a file's modification d

I've decided to implement automatic saving of window positions in my
application.  I've tried to cling as closely as possible to the
guidelines expounded in IM VI (User Interface Guidelines).
However some points remain obscure:

1. IM VI says that if the user opens a document, moves its window around
   and then closes the document without making any changes, my app is
   supposed to save the new window position without asking anything and
   without CHANGING THE FILE'S MODIFICATION DATE.
   I implement this with by doing a PBGetCatInfoSync() when I open
   the document file and a PBSetCatInfoSync() after I modify and close it.
   Is this the recommended way?  Is there an easier way?

2. When a document is opened, I check to see if the saved window
   position makes sense for the current monitor(s).  I have a function
   declared as follows:

   FUNCTION WindowInDesktop(VAR windowFrame: Rect): Boolean;

   The function returns TRUE if windowFrame is COMPLETELY ENCLOSED
   in the Gray Region.  But other applications (e.g. the Finder and
   StuffIt Lite) restore the window position even if the window frame
   is mostly offscreen.  What is the correct algorithm?

Thank you in advance for any suggestion.

					-- marco
From: gk1@acpub.duke.edu (Gavin  Kistner)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Help me get the ResEdit Icon BACK! Please!?!
Keywords: resedit
Date: 23 Jan 93 19:57:31 GMT
Distribution: usa
Organization: Duke University; Durham, N.C.

In article <2B619518.22183@news.service.uci.edu> eapg070@orion.oac.uci.edu (Caroll Elke Pohl) writes:
>i'm having this problem with resedit too. after rebuilding the desktop
>the resedit application icon as well as the document icons were gone.
>the BNDL and ICN# resources were ok but...
>after rebuilding the desktop again the problem persists.
>weird.
>
>-caroll

Interesting...all my ResEdit icons just disappeared, too.
VIRUS!!  VIRUS!!  VIRUS!!  VIRUS!!  VIRUS!!  VIRUS!!  VIRUS!!  VIRUS!!

Well, OK, maybe not.

I wonder, though...

:)

-Gavin
Newsgroups: comp.sys.mac.programmer
From: mark@pokey.jsc.nasa.gov (Mark Manning)
Subject: Re: Geneva 9 Radio Buttons, Checkboxes, etc...
Organization: NASA
Date: Mon, 25 Jan 1993 21:26:54 GMT

Hello!

   I have my own problem with dialogs and font setting.  I have a
Static Text Field I want to change from one font to another as well
as change the size and face values.  From ftp.apple.com I downloaded
something which seemed to address this.  In the QAS the programmers
say to do:

dp:=DialogPeek(myDialog);
TextFont(geneva);
TextSize(9);
dp^.textH^^.txFont := geneva;
dp^.textH^^.txSize := 9;
SetWTitle( myDialog, 'ADSP Thing' );
(etc....)

But this doesn't work.  Later on the programmers again address the
problem and say that you need to create ICTBs and to include a much
larger segment of code.

The first method did not seem to work.  Does anyone know if the second
method works?  I hate to type in everything only to find it doesn't work.
Then I'd have to take it all back out again. *ugh*.

Thanks ahead of time for this information. :)

Newsgroups: comp.sys.mac.programmer
From: John Brewer <jbrewer@wri.com>
Subject: Re: Verifying valid handles, how to?
X-Xxmessage-Id: <A789E9F0D2010A90@thunderpuppy.wri.com>
X-Xxdate: Mon, 25 Jan 93 01: 03:12 GMT
Organization: Wolfram Research, Inc.
X-Useragent: Nuntius v1.1.1d16
Date: Tue, 26 Jan 1993 01:03:15 GMT

Um.... Why not just

	#define KillHandle(h) (DisposHandle(h), h = 0)

Simple, but effective....

John
Newsgroups: comp.sys.mac.programmer
From: mshields%peruvian.cs.utah.edu@cs.utah.edu (Michael S Shields)
Subject: Re: Modifying width of PopUp menus in System 7.1
Date: 22 Jan 93 01:18:47 MST
Organization: University of Utah Computer Science

In article <absurd-190193022736@seuss.apple.com> absurd@apple.apple.com (Tim Dierks, software saboteur) writes:
>
>Here's some code to do what you want.  I'm right in the middle of working
>on this,
>so I can't say it's 100% correct, but I'm pretty sure it's close.  It will
>give
>you all the essential concepts, anyway.
>
>Tim Dierks
>MacDTS, but I speak for myself
>

[some code deleted]

>    // First, we'll clean up after buggy software.  A number of commercial
>products
>    // (word processors are most common) screw up the window manager port;
>they leave the
>    // txSize field set to 12.  It and the txFont field should always be
>left set to 0;
>    // this makes them the system font and size.  So first thing we do is
>clean up
>    // after these miscreants.
>    
>    GetWMgrPort(&wMgrPort);
>    SetPort(wMgrPort);
>    TextFont(0);
>    TextSize(0);
>    
[more code deleted]

This section I have a question about. I found out the other day that the system
software for international use(ie. Kanji) doesn't use 0 as the system font.
If I set the SysFontFam global to 0 the menu and titlebar text showed up in
Chicago not Osaka(is this the correct name?). Now does TextFont and TextFace
have the intelligence to use the correct font or does it blindly use Chicago?
This was using Kanji 7.1 on a IIsi.

Mike Shields
mshields@peruvian.cs.utah.edu
From: nagel@kithrup.Irvine.CA.US (Mark D. Nagel)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Think Reference 2.0 Review
Date: Thu, 28 Jan 93 14:05:44 PDT
Reply-To: nagel@Kithrup.Irvine.CA.US
X-Mailer: uAccess - Macintosh Release: 1.6v1


In article <D2150096.o2q2ry@sproul.sproul.com> (comp.sys.mac.programmer), Sproul@sproul.sproul.com (Mark Sproul) writes:
> 
> When it is fully installed it occupies 7.1 meg, it has
> multiple database files and indexes.  It containes VAST amounts of
> data and insight including overview of many of the new things like
> Sound manager and inter application communication. Well worth the
> money and will be very valuable to all programmers.  I have not tried
> the new copy text features but they are documented.  Another nice
> feature is that all toolbox calls that may move memory are noted with
> a memory chip symbol to help you remember when this may be a problem.

I just installed this at work and it seems very useful.  However,
I hope there is a fixer-upper release soon, as I am concerned that
the first few times I really tried to use it, I found spelling
errors in symbolic constants.  I can live with the occasional typo
in descriptive text, but there should be absolutely no errors in the
spelling of symbolic constants or function names.  The example I came
across was under Gestalt in the gestaltFindFolderAttr selector.  Since
this was the first real lookup I had done, I am forced to wonder how
prevalent this problem is in the databases.  All in all, though, a
very useful product.


Mark

-------------------------------------
Mark Nagel <nagel@mdn.uucp>

If at first you don't succeed, that's pretty much it.
				-- SDI Design Team
Newsgroups: comp.sys.mac.programmer
From: gloor@paprika.lcs.mit.edu (Peter A. Gloor)
Subject: WANTED: QuickTime player for Unix
Organization: MIT Laboratory for Computer Science
Date: Mon, 25 Jan 1993 18:45:49 GMT

NTED: QuickTime player sources for UNIX

Does anybody know whether there is a 
commercial or (even better) public domain
QuickTime player with or without source code 
for Unix/X-Windows available.

Please answer directly to me, I will repost
to the net if there is an interest.

Peter Gloor



---------
Peter A. Gloor
MIT Laboratory for Computer Science
545 Technology Square
Cambridge MA 02139
gloor@lcs.mit.edu
From: mxmora@unix.sri.com (Matthew Xavier Mora)
Newsgroups: comp.sys.mac.programmer
Subject: Re: Serial question
Date: 27 Jan 93 19:49:31 GMT
Followup-To: comp.sys.mac.programmer
Distribution: comp
Organization: SRI International

In article <DPB.93Jan26163809@scws6.harvard.edu>, dpb@huelings.harvard.edu
(David Baker) wrote:
> 
> I tried to test out the serial port with the following porgram, and I got the
> same problem I had had in the project I'm working on, which is that the
> machine freezes during the FSWrite call.  When I enter MacsBug, I am in a loop
> in _vSyncWait.  Does anyone know what I'm doing wrong?

I often run into this With Eudora and Fetch. I can't seem to reliably
download
any files with fetch. It gets hung up in _vSyncWait. A value at a0+10 is
not being adjusted and it hangs forever. If I clear that word then it
continues
and usally hangs or crashes. I don't know what it is but I see this problem
also but its with MacTCP/Eudora/Fetch/TelNet/ZapTCP not with comm software.

Xavier


--
----------------------------------------------------------------------
Matthew Xavier Mora                                mxmora@unix.sri.com
SRI International                                       (415) 859-5011
----------------------------------------------------------------------
Newsgroups: comp.sys.mac.programmer
From: lardieri@phoenix.Princeton.EDU (Stephen Lardieri)
Subject: determining idle time
Originator: news@nimaster
Organization: Princeton University
Date: Fri, 22 Jan 1993 04:36:25 GMT

Is there a reliable way of an application determining how long the machine
has been idle?  Preferably something that does not require constant time
slices, i.e. something that would allow me to call WaitNextEvent() with
a long snooze time?  This app will only be running under System 7, if it
matters.

Newsgroups: comp.sys.mac.programmer
From: John_Shepardson.esh@qmail.slac.stanford.edu (John Shepardson)
Subject: Re: How to hide the menubar
Followup-To: comp.sys.mac.programmer
Organization: Stanford Linear Accelerator
Date: Thu, 28 Jan 1993 17:49:12 GMT

In article <1k8u69INNke8@uwm.edu>, bowden@convex.csd.uwm.edu (John W.
Bowden) wrote:

> How can I hide the menubar so that is doesn't
> obscure full-screen windows?

Buy Think Reference II.  It tells you how to do this and a thousand other
things!
Organization: Penn State University
Date: Mon, 25 Jan 1993 09:26:15 EST
From: <F0O@psuvm.psu.edu>
Newsgroups: comp.sys.mac.programmer
Subject: Becomming a Mac programmer

   Hi!

   I'm starting a new job in about a week, where they use Macs.  I'm a
Windows programmer, and am glad to get experience on the Macs, but may
have to do some programming on the Mac.
   I was wondering what the difference was between programming under the
Windows environment and under the Mac, and what would be good books/journals
for me to read to catch up?
   I DO NOT want to start a war over Windows vs Mac.  Just simply need
some sources so I can catch up on the Mac world.


                                                          [Tim]
Newsgroups: comp.sys.mac.programmer
From: ross@bnr.ca (Ross Brown)
Subject: Re: how to launch anything, like the Finder does...
Organization: Bell-Northern Research Ltd.
Date: Tue, 26 Jan 1993 17:48:20 GMT

In article <01050133.oea6u6@distant.uucp> edw@distant.uucp (Ed Watkeys) writes:
>I would like to have a program I'm working on launch everything inside of
>a folder, exactly the way the Finder does when it starts up. Is there a
>way to do this that doesn't involve hundreds of lines of code? Can I use a
>Finder Apple event to do somthing like this? BTW, when I say "everything,"
>I mean everything, including sounds, etc. This seems to be a job for Finder
>events, the more that I think about it...

I have an application which will be beta testing this spring which does this,
among other seemingly easy things.  Write to me if you're interested.

==============================================================================
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.
==============================================================================

The above material is not related in any way to my employment with BNR.
Newsgroups: comp.sys.mac.programmer
From: aaron@noproblem.uchicago.edu (Aaron L. Bratcher)
Subject: mac microkernel
Followup-To: comp.sys.mac.programmer
Organization: University of Chicago
Date: Wed, 27 Jan 1993 13:58:51 GMT


Is there anyone from Apple that can tell us what the status of the
mircokernel for the mac is? Will it work on my current mac with System 7?
Is the threads product still supported? Will threading on the microkernel
use the same functions as the threads package?

Lots of questions from mac die-hards.

Any news would be greatly appreciated. Thanks.
Newsgroups: comp.sys.mac.programmer
From: niko@iastate.edu (Nikolaus E Schuessler)
Subject: Re: My Resource ID's keep changing numbers!!!!
Organization: Iowa State University, Ames, IA
Date: Mon, 25 Jan 1993 13:49:28 GMT

In article <1993Jan25.052531.7806@dunix.drake.edu> kjt001@dunix.drake.edu (Devil Bunny!) writes:
>I'm working with Think C 4.0 and ResEdit 2.1.1, and I am trying to
>change the resource ID's for my menus.  I can change the numbers, and
>they save - whenever I open the .rsrc file, it shows the correct IDs,
>but when I try to access them with Think C, I can only access them with
>IDs of 128,129, and 130.  I've assigned them as 400,401,and 402.
>
>I've created a MBAR resource (ID 400), and listed those three menu
>resources in them.  I can load the resourses and display them on the
>screen with the MBAR resource.  But when I try to add more items, I
>can't access them with IDs of 400,401,402 - and when they are clicked
>on, they return the IDs of 128,129,and 130.
>
>Why can't I change these resource numbers???  And what's screwing up;
>ResEdit or Think C?
>

There are two places where you have to make the change. One is the
resource id which you probably have changed. I'm not at a mac now, but
you need to open the menu resource. There is a menu that pops up
with a choice that is 'get info' or change MDEF id or something like
that. Choose it and you should be able to find the 128-130 number
that needs to be changed still.
-- 
Niko Schuessler               
Project Vincent Systems Manager              email: niko@iastate.edu
Iowa State University Computation Center     voice: (515) 294-1672
Ames IA 50011                                snail: 272 Durham 
Newsgroups: comp.sys.mac.programmer
From: ulbrich@informatik.uni-ulm.de (Jan Ulbrich)
Subject: Waiting for CTB-connection...
Organization: University of Ulm, Germany
Date: Thu, 28 Jan 93 08:56:08 GMT

Hi there,

I wrote an application working with CTB to connect to other computers  
-
and it works fine. Now I want to add the ability to wait for a  
connection
and don't understand, why my code doesn't work: For what code do I  
have
to wait as status, to know that the connection is established? And  
how
am I informed, that a connection I use was closed?

Thaks for help and have a nice day, Jan

///
o-o
 L   flynn (remember tron?)
 _   ulbrich@informatik.uni-ulm.de



-- NewsGrazer, a NeXTstep(tm) news reader, posting --
M>UQR=&8P7&%N<VE[7&9O;G1T8FQ<9C!<9FUO9&5R;B!#;W5R:65R.WT*7&UA
M<F=L,3(P"EQM87)G<C$R,`I<<&%R9%QT>#$Q-3)<='@R,S`T7'1X,S0U-EQT
M>#0V,#A<='@U-S8P7'1X-CDQ,EQT>#@P-C1<='@Y,C$V7'1X,3`S-CA<='@Q
M,34R,%QF,%QB,%QI,%QU;&YO;F5<9G,R-%QF8S!<8V8P($AI('1H97)E+%P*
M7`I)('=R;W1E(&%N(&%P<&QI8V%T:6]N('=O<FMI;F<@=VET:"!#5$(@=&\@
M8V]N;F5C="!T;R!O=&AE<B!C;VUP=71E<G,@+5P*86YD(&ET('=O<FMS(&9I
M;F4N($YO=R!)('=A;G0@=&\@861D('1H92!A8FEL:71Y('1O('=A:70@9F]R
M(&$@8V]N;F5C=&EO;EP*86YD(&1O;B=T('5N9&5R<W1A;F0L('=H>2!M>2!C
M;V1E(&1O97-N)W0@=V]R:SH@1F]R('=H870@8V]D92!D;R!)(&AA=F5<"G1O
M('=A:70@87,@<W1A='5S+"!T;R!K;F]W('1H870@=&AE(&-O;FYE8W1I;VX@
M:7,@97-T86)L:7-H960_($%N9"!H;W=<"F%M($D@:6YF;W)M960L('1H870@
M82!C;VYN96-T:6]N($D@=7-E('=A<R!C;&]S960_7`I<"E1H86MS(&9O<B!H
M96QP(&%N9"!H879E(&$@;FEC92!D87DL($IA;EP*7`HO+R]<"F\M;UP*($P@
M("!F;'EN;B`H<F5M96UB97(@=')O;C\I7`H@7R`@('5L8G)I8VA`:6YF;W)M
6871I:RYU;FDM=6QM+F1E7`I<"@I]"C\I
`
From: edw@distant.uucp (Ed Watkeys)
Newsgroups: comp.sys.mac.programmer
Subject: Geneva 9 Radio Buttons, Checkboxes, etc...
Date: Fri, 22 Jan 93 21:00:12 EST
Organization: Distant Software
Reply-To: edw@distant.uucp
X-Mailer: uAccess - Macintosh Release: 1.6v2

I just got ahold of SuperClock! 4.0.2 (very nice), and while I've used
SuperClock! for a few years, the nice, tasteful Geneva 9 radio buttons etc.
just got me thinking about how I could do them in my own dialogs.

Snooping through SuperClock! with ResEdit, I found that his radio buttons
(and checkboxes, presumably) use custom controls. Rather than simply stealing
his controls and trying to get them to work, I would like to find out for
myself how it's done (also, it seems unethical, if not illegal to steal his
controls). Anyway, while this doesn't seem like a really hard thing to do,
it requires a knowledge of controls a little more extensive than I possess.
(Incidentally, my knowledge consists knowing how to manipulate controls, not
creating them or doing abnormal things with them.)

This Geneva 9 thing seems to be really catching on: AppleTalk Remote Access
make extensive use of Geneva 9, as do many other programs which I can't
remember right now. Chicago is pretty ugly, IMHO, and once you go Geneva for
user interface stuff, well, you know what they say...

In any event, if anyone knows and would like to explain if there's a way to
do dialogs with Geneva 9 in a way that is not painful, I would love to hear
it. I guess you could use some other font if you really want to, but I don't
know why you would...

Ed

--
Edwin H. Watkeys III                                   edw@distant.uucp
Distant Software                               dsinc!jabber!distant!edw
+1 215 387 7971                                     edw%distant@bts.com
From: dash@apple.com (dash)
Newsgroups: comp.sys.mac.programmer
Subject: Drawing on the desktop
Date: 28 Jan 93 23:48:04 GMT
Organization: Apple Computer Inc.

Could someone please explain to me how you draw directly onto the
desktop? I have a utility application that will need to draw a bar graph
directly onto the desktop, then erase it when the user is finished. I do
NOT want to open a window for this, as it is a system INIT/CDEV.

Regards,

dash
Newsgroups: comp.sys.mac.programmer
From: toge@kekvax.kek.ac.jp (Nobu Toge)
Subject: Re: When is a menu disabled? (enableFlags isn't all)
Followup-To: comp.sys.mac.programmer
Organization: KEK
Date: Wed, 27 Jan 1993 05:32:22 GMT

In article <walkerj.728102613@milo.math.scarolina.edu>,
walkerj@math.scarolina.edu (Jim Walker) wrote:

> 
> I can't think of any good way to tell when a modal dialog is in
> front, either.
> 

Call _FrontWindow or look up WindowList and look at the windowKind of
the front-most window.  You can judge by looking whether it's dialogKind 
or others.  I'm using this in my init and it works rather nicely.

Re: enableFlags: I don't know except possibly to patch EnableItem and
DisableItem and keep track of menu dis/enable actions.  Pretty ug.

- Nobu Toge (Nat'l Lab for High Energy Physics)
- toge@kekvax.kek.ac.jp

#include <StandardDisclaimers.h>
From: davidp@stealth.usc.edu (David Peterson)
Newsgroups: comp.sys.mac.programmer
Subject: Re: "GLOBAL System Variables", Help!!!
Date: 24 Jan 1993 19:07:55 -0800
Organization: University of Southern California, Los Angeles, CA
Distribution: world
Reply-To: davidp@usc.edu
NNTP-Posting-Host: stealth.usc.edu


In article <C1CAAv.9Hu@news.udel.edu>, lecates@bach.udel.edu (Roy LeCates) writes:
|> In article <1993Jan21.200510.7950@fcom.cc.utah.edu> Dmitry Boldyrev <dmitry@chemistry.chem.utah.edu> writes:
|> >Does anyone know how to write/read Global variables in THINK Pascal ?
|> >I have an address of CurActivate ($0A64) and size (4).
|> >Think Reference says that it's a "Global Variable", but
|> >when I tried to use it in Pascal it says "unknown indef.".
|> >" MyWindow := CurActivate; "
|> 

Well, it C you do something like this to set a global:

	*((GlobalType*) GlobalName) = newValueOfTypeGlobalType;

I'm not positive about Pascal, but I think it would look something like this:

	(GlobalType^(GlobalName))^ := newValueOfTypeGlobalType;

Works for types four or less bytes in size. (In C at least, Pascal might
copy the whole thing over.) Just turn it around to read the global.

-dave.
Newsgroups: comp.sys.mac.programmer
From: k044477@hobbes.kzoo.edu (Jamie R. McCarthy)
Subject: What does 0xB6DB6DB6 mean to you?
Organization: Kalamazoo College
Date: Thu, 28 Jan 1993 07:28:16 GMT

I have an extremely puzzling heap-corruption bug that I've been actively
tracking down for days.  I don't have many clues.

One clue that I do have is, the hex bytes B6 DB 6D seem to get written
over blocks of mine occasionally.  They rarely (never?) get written 
outside blocks, so the heap is (often) not corrupted.  Anyone know what
might be doing this?

I would guess it's some kind of debugging tool;  the binary
representation is ...110110110110110110... but I can't figure out who
might be reponsible...
-- 
 Jamie McCarthy      Internet: k044477@kzoo.edu      AppleLink: j.mccarthy
 "I know I can't spell, so does anyone who reads this, but my spelling
  is not that bad."				 - Gerald A. Josephson
Newsgroups: comp.sys.mac.programmer
From: peter@cujo.curtin.edu.au (Peter N Lewis)
Subject: Re: Shareware summary (long)
Followup-To: comp.sys.mac.programmer
Organization: NCRPDA, Curtin University
Date: Sat, 23 Jan 1993 10:11:57 GMT

In article <1993Jan22.142321.16278@wega.rz.uni-ulm.de>,
walrath@faw.uni-ulm.de (Wayne K. Walrath) wrote:
> 
> In article <PETE.93Jan17213434@tatjana.rice.edu>, pete@tatjana.rice.edu (Louis Wu) writes:
> | 
> |> Still, there are more honest people out there than I had originally
> |> thought.  I've made enough to pay for my computer, which I certainly never
> |> expected in the beginning. My checks have probably come half from the
> |> states, half from elsewhere. Of the elsewhere, Australia sent the most. But
> |> I've also had checks from Britain, Canada, Denmark, France, Germany,
> |> Holland, Japan, Norway, Sweden, and Switzerland.
> 
> It would seem not such a bad idea to have an option for people 
> to pay their shareware fees closer to their home (country). For example, 
> let's say that a Belgium-based company/person 
> receives all payments from users in Europe

A simpler alternative, the one I took, is simply to open a bank account in
the relevent country, and then accept checks drawn on banks in that
country, and when you receive them, mail them to the bank.  Of course,
opening a bank account in a country you're not in is often a non-trivial
exercise (fortunately I had help from a good friend over there).

Actually, its probably close to impossible to get an Australian bank
account set up without being here, I can check if anyone is interested. 
Its nearly impossible to get one even if you are here these days!  besides,
with the Australian dollar sinking as fast as it is, you wouldnt want to
leave the money here long (makes my ammerican dollars look good though :-).

I'm always amazed by shareware authors who say they get lots of payments
from Australia, I live here, and Australia makes up only a small percentage
of shareware payments I've recieved (like, I think about 4 or 5 total,
ever!)

> Anyone care to add to these thoughts, or if someone knows about 
> organizations already established for this purpose, I would enjoy
> hearing how they are working. So far, I have never seen a program that
> mentioned such an organization.

I've never heard of one.  I'd offer to help anyone who gets lots of
Australian shareware payments, but a) I'm so disorganized myself it would
be a bad idea, and b) I'd probably get jealous :-)

Have fun all,
   Peter.

_______________________________________________________________________
Peter N Lewis <peter@cujo.curtin.edu.au>             Ph: +61 9 368 2055