To: instone@andy.bgsu.edu Cc: don Subject: Tools for user interface RESEARCH --text follows this line-- Hi! This is reference to your USENET article about "Tools for user interface RESEARCH". I have not had time to respond to it publically yet, but I hope I can answer some of your questions in this message. I work for Ben Shneiderman at the University of Maryland Human Computer Interaction Lab. I am the one who implemented the experiment comparing pie menus with linear menus that was described in the CHI '88 paper. (I first implemented pie menus for the X10 window manager "uwm" when working for Mark Weiser's Heterogeneous Systems Lab.) Included below is a recent message I send to comp.lang.forth, in response to someone asking for comments about Mitch Bradley's Sun Forth system. I linked together the window manager and the Forth system, so I could program the window manager interactivly, and I used it to implement the experiment to Jack Callahan's specifications. The Forth based window manager system is hardly "generic". It's a 68000 Forth system, which runs on a Sun. Since it uses the X10 window system, you can perform the experiment on any machine that runs X10, and run the window manager on a Sun over the network. But nobody is using X10 any more (The X10 libraries aren't installed at UMD any more, so I can't even recompile it). The main motivation behind linking together the window manager and the Forth system was to have an interactive extension language with which I could program the behavior of the window system. The system was extremely useful for my research into pie menus, and I was able to rapidly implement, try out, and tune various styles of interaction, and add and change features of the experiment in response to comments on the pilot study. On the other hand, the system was based on an complex, monolithic window manager, which wasn't designed to be programmable in the first place, with an no-holds-barred extension language nailed on top of it as an afterthought. The parts of the system that were mallable were those that I had broken out into Forth, and things I could effect by calling C functions and manipulating C data structures from Forth. There were a couple of huge event dispatching loops I had to break up into pieces that I could call from Forth. I had control of the main loop in Forth, and could intercept events and handle them as I pleased, or call a C function to let the original window manager code deal with them. So it had all the functionality of the original pie-menuified window manager, and all the functionality of Forth. A much more interesting and useful generic tool for user interface research would be one that was itsself written in an interactive extension language, designed to be programmed and customized from day one. [...] Article 964 of comp.lang.forth: Path: mimsy!brillig.umd.edu!don From: don@brillig.umd.edu (Don Hopkins) Newsgroups: comp.lang.forth Subject: Re: Forth for VAX, Sun Summary: Bradley Forthware: 4444 is the number of the best! Keywords: sun, unix, cforth Message-ID: <17412@mimsy.UUCP> Date: 10 May 89 11:06:40 GMT References: <24085@agate.BERKELEY.EDU> Sender: nobody@mimsy.UUCP Reply-To: don@brillig.umd.edu.UUCP (Don Hopkins) Organization: U of Maryland, Dept. of Computer Science, Human Computer Interaction Lab Lines: 154 In article <24085@agate.BERKELEY.EDU> web@garnet.berkeley.edu (William Baxter) writes: >To my inquiry about Forth systems for the VAX and Sun, I received two >responses, both mentioning the same programs. > >C Forth 83: > >Runs on both VAX (VMS or Unix) and Sun, and in fact on just about every >computer with a half decent C compiler. The price is $50, which gets >you C kernel source, Forth utilities source, on-line documentation, and >a printed glossary. It's a Forth-83 dialect with 32-bit stacks, real >files, and several utilities. I used a version of CForth when I was working for Mitch, summer before last at Sun. It's a very nice Forth system, and quite portable. You can define your own Forth primatives in C, by adding them to this big switch statement! We linked CForth together with a schematics CAD system (CADroid), so you could call the CADroid commands from Forth, and then we wrote a user-friendly extension language in Forth. It accepted postfix commands, and prompted for arguments in English. You could interactivly define macros for laying out circuit bodies and wiring them up, by typing commands, pointing with the mouse, selecting from menus, pressing function keys, putting in your own prompts for arguments, bindings macros to keys, etc. It also supported interactive loops and conditionals. Mitch came up with a really neat unified syntax for them: condition? [ ] condition? [ ][ ] count [ ] count [ ][ ] The last one (the loop-with-an-else-clause) was particularly useful because it could be used instead of the otherwise common construct: count 0= [ ][ count [ ] ] The way these constructs worked interactivly (and during macro definition) was that you started a loop by typing a count and a [, and it would execute commands as you typed them in, the first time through the loop, and once you typed the matching ] (they nested!), it would re-execute the now-compiled loop count-1 more times, real fast. The conditional form had just the same behavior: It would either execute what you typed as you typed it, or ignore your commands, according to the condition (|-1| or 0). So when we carefully consider all of these facts, we are forced to ask ourselves the following question: What was today's topic again? Wait, I remember: Bradley Forthware. > >Sun Forth: > >Runs on any Sun 2, Sun 3, or Sun 4, and also on most non-Sun 680x0 Unix >machines. The price is $200, which gets you the binary, source code, >metacompiler, 200+ page printed manual, and a ton of utilities (for >instance, it can load C object files into the Forth dictionary and >execute the C subroutines as Forth words. It also has a disassembler >and both high level and assembly language debugging tools.) > > Sun Forth is an excellent, rich, fast, fantastic Forth system! I've used it for all kinds of things, on the Sun-2, the Sun-3 (68K), and the Sun-4 (SPARC). It also runs on the Atari ST, and the Mac, I think. (I haven't used those versions) On the Sun-2, I had a good time using Sun Forth to figure out how to frob the CG1 color graphics card, by printing out the cg1reg.h file, mmap'ing in the device registers, and frobbing around with them. (I finally discovered that you could only write to the color table during vertical retrace, when I got mad and frustrated that my unsucessful attempts at loading the color table were taunting me by kinda sorta working occasionaly, and I decided to punish it by running it in an infinite loop. My color table slowly faded into view!) It's got a kick-ass decompiler, that pretty prints forth code and disassembles primatives! Who needs manuals or source code? (But you get them anyway! ;-) There are a lot of other nice features, like an emacs-like command line editor, with history, and command completion over your Forth vocabularies. It's very well interfaced with Unix. It also runs stand-alone without Unix. Mitch uses it in the hardware lab at Sun to debug decadent wayward hardware, by dropping in a Forth ROM, talking to it through a serial port, and running it in the framebuffer memory! [It looks real neat munching away on the screen, and it can work even when the main memory is fried!] The list of features goes on and on... The ability to dynamicly load in C object files makes Sun Forth useful for a whole lot of things you'd normally never think of (or at least admit to thinking of) using Forth for! On the Sun-3, I linked in a version of the X10 "uwm" window manager I had modified to do pie menus. I could call all the window manager functions from Forth, passing them arguments on the stack, and I could bind mouse actions and menu selections to Forth functions. I moved the main control loop that dispatched events into Forth, so I had a crack at the events before passing them on to uwm. Forth could could respond to window system events, track the mouse, pop up menus, change the cursor, move windows around, etc... It had complete access to all the window manager function and data structures. One thing I used this system for was to implement an experiment that Jack Callahan designed, comparing pie menus with linear menus. (A paper describing the experiment is in the CHI'88 conference proceedings.) The Forthified window manager administered the experiment by randomizing the order in which the menus were presented, prompting the test subject to select a certain item from each menu, and recording the menu selections made and the time each took, etc... The Forth system was very useful for prototyping different mouse tracking techniques for pie menus -- it would have been very painful to have to go through the old edit-compile-link cycle every time I wanted to tweak something! NeWS is an example of how useful it is to have a window manager with an interactive extension language! (But I didn't have NeWS yet.) X window managers are big messy programs (even in the X10 days!), but I was able to plug X10 uwm right into Sun Forth, and start hacking away -- instant extension language! (Though uwm wasn't exactly /designed/ for that kind of abuse!) I've also used Sun Forth for other projects, like prototyping a hypertext markup language interpreter (NeWS HyperTIES), and as a Cellular Automata Machine rule compiler. I cloned Tom Tofoli's CAM rule language in Sun Forth, and wrote a tool for computing and displaying them in NeWS. Not anything like as fast as the real CAM hardware [256x256 cells @ 60 frames/sec], but if you feed it the right rules and initial conditions, and wait a while, it will make lots of pretty patterns that take up lots of disk space. >Both are available from: > >Mitch Bradley >Bradley Forthware >P.O. Box 4444 >Mountain View, CA 94040 > Mitch swears the PO box number was totally coincidental! >---- >Disclaimer: Endorsement? I haven't even used them. > >William Baxter > >ARPA: web@{garnet,brahms,math}.Berkeley.EDU >UUCP: {sun,dual,decwrl,decvax,hplabs,...}!ucbvax!garnet!web Disclamer: Of course I'm quite biased, since I worked with Mitch for a summer, and I just love his Forth system. But so does Mitch, or it wouldn't have so many great features! -Don