home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 274.lha / Scripit_v1.0 / Docs / Commands.txt < prev    next >
Text File  |  1989-08-06  |  10KB  |  263 lines

  1.                             Scripit Command Format
  2.                           ==========================
  3.  
  4.  
  5. MENU        menu menuitem <subitem>
  6.  
  7.             Simulate a menu selection from the selected window's menu.  The
  8.             input is 'menu' 'menuitem' and if needed 'subitem'.  This command
  9.             needs at least the first two to work.  Note 1 explains naming
  10.             conventions.  (If the window has the MENUVERIFY flag set,
  11.             Scripit will send a MENUVERIFY msg and wait for a reply to it
  12.             before sending the actual menu select message.)
  13.  
  14. GADGET      [ID num] [#num] [X num] [Y num] [gadname] [opt1] [opt2]
  15.  
  16.             This controls the gadgets of the selected window.  It needs a
  17.             gadgetname (or number) to identify the gadget and, depending
  18.             on the gadget type needs more arguments to modify that
  19.             gadget's contents.  It will send both a GadgetUp and a
  20.             GadgetDown message if the window's flags request that.
  21.             (See Note 4 for more info.)
  22.  
  23. GADGET      boolgadget
  24.  
  25.             Triggers a selected bool gadget from the selected window.
  26.  
  27. GADGET      stringgadget newstring
  28.  
  29.             Replaces the string in a string gadget with a new string and
  30.             simulates a 'return' on the gadget.  [opt1] is the new string.
  31.             
  32. GADGET      propgadget horz vert
  33.  
  34.             Changes the position of a proportional gadget.  The input values
  35.             reflect the horizontal and vertical prop position of the gadget.
  36.             (Values allowed: 0-65535)  [opt1] is the horizontal position,
  37.             and [opt2] is the vertical position.
  38.  
  39. GADGETDOWN  Does the same job as 'GADGET' except that it will only send
  40.             GadgetDown messages and not GadgetUp messages.
  41.  
  42. GADGETUP    Does the same job as 'GADGET' except that it will only send
  43.             GadgetUp messages and not GadgetDown messages.
  44.  
  45. WAIT        <delay>
  46.  
  47.             Suspends script execution for delay * 1/50th seconds.  Default
  48.             delay time is 25, i.e. 1/2 second.
  49.             
  50. LMB         x y
  51.  
  52.             Simulate clicking the left mouse button while the pointer
  53.             is at position x,y.
  54.             Related   : SELECTUP    Sends only LMBUp message.
  55.             Commands  : SELECTDOWN  Sends only LMBDown message.
  56.  
  57. RMB         x y
  58.  
  59.             Simulate clicking the right mouse button while the pointer
  60.             is at position x,y.
  61.             Related   : MENUUP      Sends only RMBUp message.
  62.             Commands  : MENUDOWN    Sends only RMBDown message.
  63.  
  64. DOUBLECLICK Simulate a double click.  This can be one of the following types:
  65.  
  66.             DOUBLECLICK GADGET boolgadget
  67.             DOUBLECLICK RMB
  68.             DOUBLECLICK LMB
  69.  
  70.             The delay between the two clicks is controlled by the double-
  71.             click setting in Preferences.
  72.  
  73. VERBOSE     [ON] or [FULL]
  74.  
  75.             Turns on debug text printout to the console window.  Default
  76.             mode is off.  VERBOSE ON will turn it on, any keyword other
  77.             than 'ON' will turn it off except VERBOSE FULL which will turn
  78.             on full debug display.
  79.  
  80. SCRIPT      [scriptfile]
  81.  
  82.             Transfers script file execution to another Scripit file.
  83.             Control will NOT return to the current file when the new script
  84.             file ends.
  85.  
  86. SUBSCRIPT   [scriptfile]
  87.  
  88.             Transfers script file execution to another Scripit file.
  89.             When that file ends, control will return to the current file.
  90.             (Be careful of scripts that call themselves!)
  91.  
  92.             (Both SCRIPT & SUBSCRIPT were broken in previous version.  They
  93.             are working now.)
  94.  
  95. DRAG        x,y,x2,y2,[steps]
  96.  
  97.             This is intended for use with WorkBench.  It will click on an icon
  98.             at x,y (if it exists) and will keep holding down the button while
  99.             moving the icon to x2,y2 where it will release the button.  It is
  100.             the equivalent of (RMBDOWN x,y + MOUSEMOVE x2,y2 + RMBUP x2,y2).
  101.             Steps, if specified, will make the drag into an actual drag by
  102.             inserting interim MOUSEMOVE commands between the RMBDOWN and
  103.             RMBUP.  The number of interim moves is the number of steps
  104.             specified.
  105.  
  106. MOUSEMOVE   x,y
  107.  
  108.             Simulates mouse movement to x,y.  (Sends a MOUSEMOVE message.)
  109.  
  110. DELTAMOVE   x,y
  111.  
  112.             Simulate mouse movement by x,y. (Sends a DELTAMOVE message.)
  113.  
  114. RAWKEY      code,qualifier
  115.  
  116.             Sends a RAWKEY event to the program owning the selected window.
  117.             This command is only intended for script generated by the auto-
  118.             script generator, "Recorder."
  119.  
  120. ITICK       x,y
  121.  
  122.             Sends an INTUITICKS event to the program.  This is only intended
  123.             for scripts generated by the Recorder.
  124.  
  125. POINTER     x,y [l] [L] [r] [R]
  126.  
  127.             Pointer will move the mouse pointer to position x,y on the current
  128.             screen.  This will _really_ move the pointer not just simulate it.
  129.             The qualifier (one of the following l,L,r,R) simulates left mouse
  130.             button down, left mouse button up, right mouse button down, right
  131.             mouse button up.
  132.  
  133.  
  134. DRAW        x,y x2,y2 x3,y3 ..... xn,yn
  135.  
  136.             A specialized command used for drawing on DeluxePaint's screen.
  137.  
  138.             It simulates the following:
  139.                 POINTER x,y l
  140.                 POINTER x2,y2 L
  141.                 POINTER x2,y2 l
  142.                 POINTER x2,y2 L
  143.                 ....
  144.                 POINTER xn,yn l
  145.                 POINTER xn,yn L
  146.  
  147. WAITFOR     screen window <maxdelay> [ABORT]
  148.  
  149.             WAITFOR is the same as SELECT except that it will wait until the
  150.             requested screen/window becomes available and then it will
  151.             select it.  Maxdelay specifies the maximum time WAITFOR will wait
  152.             for the requested screen/window to appear.  (delay in 1/50th
  153.             seconds.)  Default delay is 200.  The 'ABORT' option will abort
  154.             the whole script if the Maxdelay time expires.
  155.  
  156. RUN         <program>
  157.  
  158.             Simply runs another program.  Control returns immediately to the
  159.             script which continues executing.
  160.  
  161. RUNBACK     <program>
  162.  
  163.             Simply runs another program.  Control returns immediately to the
  164.             script which continues executing.  The program will not have any
  165.             input or output streams.
  166.  
  167. EXECUTE     <program>
  168.  
  169.             Executes another program.  Script processing will wait until the
  170.             program exits.
  171.  
  172. END         Quits the script execution.
  173.  
  174. LABEL       <labelname>
  175.  
  176.             Defines a label that marks the current position in the script.
  177.             (Label names are allowed to be of any length, however only
  178.             the first 24 characters are used.  You can use any characters
  179.             that you like in label names, however you might need to use
  180.             double-quotes around it if you want to use spaces.)
  181.  
  182. GOTO        <labelname>
  183.  
  184.             Script execution moves to the position of the specified label
  185.             in the script.
  186.  
  187. Note 1:     Argument format for Screen, Window, Menu and Gadget Selection:
  188. -------
  189.             The required item can be selected by specifying:
  190.  
  191.             a.  The item's name.  This is NOT case-sensitive.  Abbreviations
  192.                 are allowed.  (i.e. 'Pro' will match the first item that starts
  193.                 with 'Pro' e.g. 'Project'.)  Leading spaces are ignored.
  194.  
  195.             b.  The item's number.  This is the sequential number of the item
  196.                 in its list.  This must always start with '#' and a number.
  197.                 (e.g.  'MENU #1 #4 #3' will select the first menu, the fourth
  198.                 menuitem, and the 3rd subitem.)
  199.  
  200. Note 2:     Arguments can be seperated by one or more spaces, tabs, or commas.
  201. -------     Any string argument can be surrounded with double-quotes to
  202.             include spaces in its text.  (e.g.  "Text string")  All numeric
  203.             arguments are integer.  (i.e. no fractions allowed)
  204.  
  205. Note 3:     Always use 'WAIT' to introduce delays between functions that move,
  206. -------     resize, open, close windows to allow enough time for Intuition
  207.             and/or the program to respond to the previous command.  (e.g.
  208.             If you do a MOVETO 0,0 and then a MAXSIZE without a delay
  209.             between the two, Intuition will probably not have moved the
  210.             window yet at the time Scripit is requesting a resize.  This
  211.             will mess up the resize and can have serious effects.)
  212.  
  213. Note 4:     Gadgets can be selected by one of the following methods:
  214. -------     
  215.             a.  Gadget ID:
  216.                 This is the gadget's ID number.  Most programs have unique ID
  217.                 numbers for each gadget.  You can find out a gadget's ID by
  218.                 using the 'Lister' program.
  219.             b.  Gadget Name:
  220.                 This is the text that is normally attached to a gadget.  Few
  221.                 programs attach text to gadgets.  (Also use Lister for gadget
  222.                 names.)
  223.             c.  Serial Number:
  224.                 This is just a serial number of the gadget.  It is reliable
  225.                 in some programs, and unreliable in others.
  226.  
  227.             You can specify multiple search criteria and Scripit will search
  228.             based on the following logic:
  229.  
  230.             1.  Search for ID.  If found ID, then gadget found, unless more
  231.                 than more gadget with the same ID was found.
  232.             2.  Search for gadget name, first gadget that matches the name
  233.                 will be selected.
  234.             3.  Scan for serial number.
  235.  
  236.             Examples:
  237.  
  238.             a. Bool Gadget:
  239.   
  240.             GADGET ID 323 #6 X 10 Y 34 "gadname"
  241.  
  242.             This will search for ID 323 first, then "gadname", then #6.  The
  243.             X and Y settings are fed into the message sent to the program
  244.             because some programs need to know where the pointer is when the
  245.             gadget was clicked on.
  246.  
  247.             b. String Gadget:
  248.   
  249.             GADGET ID 323 #6 X 10 Y 34 "gadname" "newstring"
  250.             or
  251.             GADGET ID 323 #6 X 10 Y 34 "newstring"
  252.                 
  253.             c. Prop Gadget:
  254.   
  255.             GADGET ID 323 #6 X 10 Y 34 "gadname" x,y
  256.             or
  257.             GADGET ID 323 #6 X 10 Y 34 x,y
  258.                           
  259.  
  260.  
  261.  
  262.                       Copyright 1989  Khalid Aldoseri.
  263.