Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!zephyr.ens.tek.com!tektronix!nosun!ohsuhcx!jasmerb From: jasmerb@ohsuhcx.ohsu.edu (Bryce Jasmer) Newsgroups: comp.sys.next Subject: Re: Help with File Packages Message-ID: <649@ohsuhcx.ohsu.edu> Date: 24 Aug 90 18:59:51 GMT References: <26d31071.45fe@petunia.CalPoly.EDU> Reply-To: jasmerb@ohsuhcx.UUCP (Bryce Jasmer) Distribution: na Organization: Oregon Health Sciences University, Portland Lines: 69 In article ebostick@polyslo.CalPoly.EDU (Edward Bostick) writes: > I have an application and a manual for the application >that I would like to put together in a file package. I >have an icon that I would like to use to represent the >file package. Ah yes, I just got done doing this yesterday so while it is still fresh in my mind, I will tell you how to do it. First of all, the best way to find answers is to check out NextAnswers. I can't speak highly enough about the wonderful combination of NextAnswers and Digital Librarian. (I used to think Macintosh Tech Notes were good, NextAnswers and DL run circles around them.) To find out what to do when I was doing the .app thing I started up DL and searched for "package and app". The first (of four) things to come up was an article describing how to set up the iconheader file so that the workspace will recognize the .app directory as an application and will display the icon of the program inside that directory. Here are the two lines that describe the application icon. The first line will probably already be there, you need to add the second. F myProgram myProgram app F myProgram.app myProgram app >Do I use the Project Inspector panel in IB >to associate the icon with the file package? Nope, you can't do it with 1.0 IB. Maybe in 2.0. >Should the application name field be change? No, it should stay the same. >And, if I want to use make install, should the install directory >field be changed? Yes, the install directory should be "~/Apps/myProgram.app" or "/LocalApps/myProgram.app". When you do a make install it will put the application in that directory. You can also mess with the Makefile.postamble so that when you do a make install it will also check to make sure that your manual gets copied into that directory. > Once I have the file package put together I would like to >be able to have the application use a function like getwd() >to get the path name of application or the file package. The program if launched from the browser (or dock) will have the full pathname in NXArgv[0]. If it was launched from a shell it will have a partial pathname and you would have to use getwd(). Just check if the first character is a '/'. If it isn't you will need the getwd(). >... This works, but WriteNow >will create a new window along with opening the manual >window. I feel that I must be doing something wrong with >the messages that I'm sending. Sorry, I haven't done a lot of stuff with messaging WriteNow so I can't answer that. As a kludge, I think you can perform a system() call and pass "open /pathname/manual.wn" as the arguement. This is just a guess, I haven't tried it out. Hope this helps, Bryce Jasmer Oregon Health Sciences University Biomedical Information Communication Center Research and Development jasmerb@ohsu.edu