home *** CD-ROM | disk | FTP | other *** search
/ Carousel Volume 2 #1 / carousel.iso / mactosh / da / transsen.sit / TransSend.doc next >
Text File  |  1987-03-15  |  6KB  |  44 lines

  1. TransSend is a DA companion for any terminal emulator.  It has two main purposes. First as a way to give 'preview and send' capability. TransSend is implemented as a modeless dialog with textedit boxes, buttons, and other controls. The main pushbutton sends the current text selection (highlighted text) out the modem port, using whatever parity, baud rate, etc. has been already set up. Text can be typed from the keyboard or imported/exported through the clipboard. 'Preview and send' can be used in situations like those where various history, command line editing,  and scripting mechanisms are now used, e.g. retrieving, editing, and executing previous command lines to the c shell. The main advantage is that a single interface can be used across host machines, operating systems, and programs. 
  2.  
  3. Second, the various buttons and boxes in the dialog can be used to give some semblance of a Mac-like interface to any command line oriented program running on the host. Text strings from the titles of currently selected pushbuttons, radio buttons, and checkboxes are brought together with any textedit items and shown as a provisional command line in the main textedit box, selected and all ready to send. The titles can also hold help info which is shown only while the mouse is down. A sample dialog which constructs the Unix 'find' command illustrates the ideas.
  4.  
  5. An indefinite number of such dialogs can be used by assigning each to a different pushbutton. Space can be found for all these buttons and boxes by defining an extra wide window extending well off the screen, and using the built-in scroll bar to shift the whole window left and right. (The main controls shift the other way so they're always on the screen). The window panorama is intended to show both the range of possible host commands and options, and record the actual choices made most recently. 
  6.  
  7. Resedit and Redit can be used as the Dialog Construction Kit. An annotated RMaker file gives the details. In particular, a non-standard window definition is included which has periodic notches so you can see more of the terminal window. This can just be removed if you don't like it. 
  8.  
  9. TransSend can be freely distributed, but should not be sold, etc, etc.  I'd like to get any comments anyone cares to make, especially re the Mac user interface guidelines.
  10.  
  11. Bill Benson, benson@lbl-csam.arpa, Lawrence Berkeley Lab, MS 50B 3238,
  12. Berkeley, CA 94720.
  13.  
  14.  
  15. Constructing a command line
  16. The buttons, boxes, and other dialog items are organized according to their order in the dialog item list, rather than where they appear in the window. Transsend doesn't pay any attention to spatial location.  The scope of the different kinds of dialog items is effectively extended as follows:
  17.  
  18. 1) command lines are associated with pushbuttons. Clicking on a pushbutton assembles eligible control titles and text fields from the following items in the dialog item list up to the next pushbutton. Items must be "Enabled" to be eligible, and radio buttons and check boxes must be "ON".
  19.  
  20. 2) clicking on any other item gives the expected result - turning buttons and boxes on or off, or placing the insertion point for text editing. TransSend then searches back through the list for the preceding pushbutton, and assembles titles and text as if it had just been clicked.
  21.  
  22. 3) consecutive radio buttons make up a set where one and only one button is "ON" at any time.
  23.  
  24. 4) Clicking a checkbox ON or OFF makes the following items Enabled or Disabled (and hence eligible or not) up to the next check item.
  25.  
  26. Help info
  27. To reduce clutter on the screen, control titles can optionally contain text which could be used to explain an option, for example, but will not be assembled into a command line. I've arbitrarily picked the hardspace character (option space, hex CA) to separate titles into two parts. The full title of any control item is shown in the main textedit box as long as the mouse button is held down. Only the first part of the title is highlighted (up to the hardspace). If the mouse is released while still in the control, then the command line is assembled, using only the first parts of the control titles, and put in the main textedit box. Otherwise if the mouse button is released outside the control (or if the control is Disabled), then the first part remains selected and can be sent with the Send button. Examples are the buttons for ctrl C and ctrl Z.
  28.  
  29. Customizing the dialog
  30. The DA comes with a window three screens wide already defined. Textedit boxes are in the first and third screens for 'preview and send'; a sample dialog with some common options for the Unix 'find' command is in the middle screen, which hopefully makes the syntax less 'painful'. Use a resource editor, or RMaker, to customize as you like.
  31.  
  32. Notes
  33. Some useful features that come with any dialog are: the tab key selects the next textedit box; autoscrolling can be used to reach text above and below the box boundaries;  control titles can have more text than is shown in the display rectangle; controls can be made inaccessible and placed off screen; very thin pushbuttons could be used as vertical or horizontal rules.
  34.  
  35. Scrolling to a new screen places the edit cursor at the end of the first textedit box for that screen.
  36.  
  37. This has only been tested with VersaTerm on a Plus, but should work with any terminal emulator on any Mac. Let me know if it doesn't.
  38.  
  39. To save space, 9 Pt. Geneva is used for text items. If dialog item number 1 is anything other than EditText, then the font defaults to 12 pt. Chicago as usual.
  40.  
  41. The window had better be an odd number of screenfulls. 
  42.  
  43. The Clipboard and Edit menu are supported, except for Undo.
  44.