Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!accuvax.nwu.edu!tank!eecae!netnews.upenn.edu!grad2.cis.upenn.edu!ranjit From: ranjit@grad2.cis.upenn.edu (Ranjit Bhatnagar) Newsgroups: comp.sys.amiga Subject: Re: PowerPacker 2.2a problems Message-ID: <15175@netnews.upenn.edu> Date: 5 Oct 89 21:21:17 GMT References: <1989Sep20.221509.4401@edson.ee.UAlberta.ca> <1837@convex.UUCP> <1858@sactoh0.UUCP> <898@nigel.udel.EDU> Sender: news@netnews.upenn.edu Reply-To: ranjit@grad2.cis.upenn.edu.UUCP (Ranjit Bhatnagar) Distribution: na Organization: University of Pennsylvania Lines: 72 In article <898@nigel.udel.EDU> new@udel.edu (Darren New) writes: >In article <1858@sactoh0.UUCP> hrlaser@sactoh0.UUCP (Harv R. Laser) writes: >>What PP needs is a 'config' file to save parameter changes >>so one can customize the menu choices to his liking and have >>the program load with those settings each time it's run. > >Actually, you could write a program that you give it the name of the >screen and window and a menu option. That program would wait for that >screen, then that window, then the menu to appear, and then would >hook into the input.device and pass on a MenuPick message (or whatever >it's called) to the window. Then we would have a generic configuration >program for anything with menus. Then we put it in ARexx scripts and >viola (:-), we're running menu-only program that don't have ARexx >ports from ARexx! Now, could this be done with keys, too? You >betcha. Hmmm.... I wish I had as much time as ambitions... Amazingly enough, this is exactly what DigiPaint 3 from NewTek does. Every user function (and a few mysterious extras) has a command word associated with it, which you can send from an AREXX script. There's also a big file on the digipaint disk containing the correspondence between keys and command words, so you can change the command-key equivalents by changing this file. There's another file like that for gadgets, but it's in binary, so I don't know how the information is stored. Here, for your amusement, is an AREXX script that will regularize the pallettes of a set of IFF files. Use it for making ANIMs with those silly programs that STILL don't know how to change pallettes between frames. DigiPaint 3 must be running when you invoke this. I haven't actually TESTED this script; it gives you an idea of what's going on, though. /* pals.rexx */ /* before using, bring up DigiPaint and set it to the appropriate screen parameters: interlace or not, width, and height */ /* it's DESTRUCTIVE! Will replace each file with the remapped version. */ address 'DigiPaint' 'Aoff' /* turn everything off */ 'Clsc' /* close digipaint screen so things move faster */ 'Load' /* bring up load picture requester */ 'Fnam'||arg(1) /* specify arg(1) as filename */ 'Dnam' /* clear directory name */ /* I've tested: if you specify '' as directory and 'ram:pics/foo' as filename, it loads ok */ 'Okls' /* accept this filename */ 'Pfil' /* use pallette from first file */ 'Sron' /* shrink HIRES pictures to fit HAM mode */ 'Oklo' /* go ahead with load */ 'Save' /* save possibly shrunk version on top of old version */ 'Okls' do i = 2 to arg() /* for each subsequent file */ 'Load' 'Fnam'||arg(i) 'Dnam' 'Okls' 'Pcur' /* keep current pallette */ 'Oklo' 'Save' 'Okls' end /* there you have it. */ "Trespassers w" ranjit@eniac.seas.upenn.edu mailrus!eecae!netnews!eniac!... "Such a brute that even his shadow breaks things." (Lorca)