Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!brutus.cs.uiuc.edu!apple!netcom!dlb!zygot!bruceh
From: bruceh@zygot.UUCP (Bruce Henderson)
Newsgroups: comp.sys.next
Subject: Re: terminal start-up
Summary: Some Ideas
Keywords: indexing terminal interface builder
Message-ID: <2464@zygot.UUCP>
Date: 11 Aug 89 16:01:43 GMT
References: <2201@hub.UUCP>
Distribution: usa
Organization: ATI Wares Team
Lines: 60

In article <2201@hub.UUCP>, dz@casaba.ucsb.edu (Daniel James Zerkle) writes:
> The only problem is that these apps think that they need
> a Terminal window from which to run.  If I click on their
> icons (default icons, not custom) from the browser, they
> start up a Terminal before running.  I want these things to
> run on their own, as they don't need stdio.
> 
> What's going on, and what can I do about it?

The problem lies with your application's lack of an Icon.
This question has been asked a lot on the net, because the fact that
such a thing is needed and how to provide it are rather poorly
documented. [It may be the ONLY shortcomming of those wonderful Docs!]
but what you do is this....

In the interface Builder, bring up the Project window [under File] and
you will see a text field labeled "Application Icon".  You need to give
it the name of a tiff file that will represent the Application to the
workspace manager.  You can create your own by using the "Icon" program
found in /NextDeveloper/Demos/Icon.

When you use Icon, you want to use the Prefrences menu command an set
the window to your Icon's size.  This can be anything less that 64x64.
I have noticed that most applications use 48x48 or 56x56.  The Detail
window in Icon makes this job a whole lot easier. [BTW, I think Icon is
a pretty cool item...]  You want to save your tiff file with Alpha [in
the Save panel].  

Once you rebuild your app [after you set the Application Icon field in
the Project panel in IB], you will notice it has the default
Application Icon that looks like a MegaPixel Display, to get your icon,
you need to copy your program to somewhere your workspace manager knows
to look for applications.  I created /LocalApps, which is already in
the WorkspaceManager search path, and the copied it there.  once you do
that, you use the Browser Utilities menu to chose the find tools
command.  Things will wirr and spinf for a few seconds, and when it
stops, clicking on your application's name in the browser will bring
your icon up in the window.

> Lots of applications (Digital Librarian, Browser, WriteNow) use
> other applications (Preview, WriteNow, Edit, ...) to display files
> and the like.  How can one application let another one know that
> it should be doing something (including starting up, if necessary)?
> I assume that some sort of messaging is going on, or perhaps the
> receiving end gets an event.  How do you know what sort of messages
> to send to any particular application?

This is implemented through NeXT's two custom classes for IPC. they are
called Speaker and Listener.  They are both well documented in the 3
volume Technical Documentation and they are very useful in the
functionallity they implement.  If you need more you can always
subclass [isn't OOP great!]                


-- 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Bruce Henderson                                       Software Engineer
zygot!bruceh@Apple.COM			    
"Sorry, Mathematica can't goon this much"
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^