Path: utzoo!attcan!uunet!super!udel!rochester!rutgers!att!mtunf!arr From: arr@mtunf.ATT.COM (Andrew Raffman) Newsgroups: comp.sys.amiga Subject: Re: What are menus? Summary: done before Message-ID: <860@mtunf.ATT.COM> Date: 18 Jan 89 23:05:35 GMT References: <3234@sugar.uu.net> <1472@zen.UUCP> <2308@nunki.usc.edu> <15045@cisunx.UUCP> Organization: AT&T ISL Middletown NJ USA Lines: 50 In reference to having a printer icon into which files are dropped to print things, In article <15045@cisunx.UUCP>, ejkst@cisunx.UUCP (Eric J. Kennedy) writes: > > Well, why couldn't we do this on the Amiga? We have an icon for the > rad: disk and the ram: disk, why couldn't an icon be made for the prt: > device? Maybe in ARP wb replacement? How about 1.4? The actual > 'disk.info' file could maybe live in s: or ENV: under 'prt.info'. But > it should show up with the disk icons. > > It sure would save a lot of trouble. There is currently no easy way to > print a file from the workbench, which strikes me as being rather silly. When I first got my amiga, I wrote a program called devbuf (or something like that), which would automatically create a directory, copy a .info file into it, and then wait for files to be dropped into the directory. When new file appeared in the directory, it would launch a program, passing the name of the file to the program, and then delete the file after the program had exited. The syntax for calling it was: prnbuf directory icon prog [arg1 .. argm] <> [argm+1..argn] where: directory was where the buffer should be set up icon was a .info file to be copied to the directory prog was a program to run when a file was placed in the directory arg1..argn were the arguments to the program <> (I think) was where the name of the file would be filled in. To set up a printer buffer in ram:, I would type: run prnbuf ram:printer s:printer.info copy from <> to prt: After this point, a new icon would appear in RAM: (which I would then move out onto Workbench) which would be my printer device. To print file test.txt, I would drop drop the file into the icon, which automatically fire off: copy from ram:printer/test.txt to prt: delete ram:printer/test.txt To look at the print queue, just double click on the icon. The code to do this was only about 100 lines, most of which was for looking for new files in the directory and ignoring .info files (which shouldn't be printed). Unfortunately, I lost the source, but it shouldn't be that hard to recreate. The advantage of this approach is that it doesn't require a driver, and is infinitely configurable by the user. Has anyone done something else like this? Andy Raffman AT&T Information Systems mtunf!arr