home *** CD-ROM | disk | FTP | other *** search
/ A.C.E. 1 / ACE CD 1.iso / files / docs / blitzbad.lha / BlitzBasic2V1.3Part3.doc < prev    next >
Encoding:
Text File  |  1994-12-14  |  126.3 KB  |  3,464 lines

  1.  
  2. Part Three
  3.  
  4.  
  5. Statement: PrtText
  6. --------------------------------------------------------------------------
  7. Syntax: PrtText <STRING>
  8.  
  9. Mode  : AMIGA
  10.  
  11. Description:
  12.  
  13. PrtText: Prints the text 'STRING' at your printer...
  14.          It' s the same like WriteFile(0,"PRT:"), but why have the AMIGA
  15.          a own printer.device...
  16.          So I think we should use it, right?
  17.  
  18.  
  19. Statement: Hardcopy
  20. --------------------------------------------------------------------------
  21. Syntax: Hardcopy ScreenPointer,X,Y,Width,Height,PrtWidth,PrtHeight,Flags
  22.  
  23. Mode  : AMIGA
  24.  
  25. Description:
  26. Prints the screen or a part of it at your printer.
  27.  
  28. ScreenPointer: Adress of the screen (Addr Screen(x))
  29. X............: \ Are the corners of the screen where we
  30. Y............: / want to start printing it to paper...
  31. Width........: Width of the screen part you want to print
  32. Height.......: Height of the screen part you want to print
  33. PrtWidth.....: Width of the print(on the paper)
  34. PrtHeight....: Height of the print(on the paper)
  35. Flags........: Printerflags...
  36.                Have a look to a documantation aout it, the most 
  37.                importent(?) ones:
  38.  
  39.                $40  - Centre graphic
  40.                $10  - Weidth= Maximum
  41.                $20  - Height = Maximum
  42.                $100,$200,$300,$400 - Printing quality($400 = Heighest)
  43.  
  44. Bugs:
  45.  
  46. Hm, it seems that the flags are not 100% taken...I haven' t find out 
  47. why, but might be you do...I still working on it! But however, it 
  48. works..
  49.  
  50. BTW: This library is copyright 1992/93 by Andre Bergmann.
  51.      Use it on your own risk, I don' t take the responsibility for using 
  52.      it! This source is PD, feel free to update it!
  53.      Please send me updates done by you and Bug Reports!
  54.   
  55. Andre Bergmann
  56. Am Pannesbusch 39a
  57. 42281 Wuppertal 2
  58. Germany
  59. Tel: 0049/0202/702606
  60.  
  61.  
  62.                                 CONSOLE LIBRARY
  63. --------------------------------------------------------------------------
  64.  
  65.                         ConsoleLib (a little buggy yet):
  66.  
  67.                                    OPENCONSOLE  
  68.                                    PRINTCON     
  69.                                    NPRINTCON    
  70.                                    CLOSECONSOLE 
  71.  
  72.  
  73. Command: OpenConsole
  74. --------------------------------------------------------------------------
  75. Syntax : OpenConsole Window#,Console#
  76.  
  77. Description:
  78. Open a CON: Port for the window, so ANSI output is possible.
  79.  
  80.  
  81. Command: PrintCon
  82. --------------------------------------------------------------------------
  83. Syntax:  PrintCon Console#,Expression
  84.  
  85. Description:
  86. Write text to window-console.
  87.  
  88.  
  89. Command: NprintCon
  90. --------------------------------------------------------------------------
  91. Syntax:  NPrintCon Console#,Expression
  92.  
  93. Description:
  94. Write text to window-console, and add a Linefeed.
  95.  
  96.  
  97. Command: CloseConsole
  98. --------------------------------------------------------------------------
  99. Syntax:  CloseConsole Console#
  100.  
  101. Description:
  102. Close the CON: Port, but NOT the window itself!
  103.  
  104. Note:
  105. These command work if you use them only for ONE window...If you wanna 
  106. use the CON's for more windows, so that object are use it doesn' t work 
  107. anymore... Ya see, I need ya help, please...
  108.  
  109.  
  110.                                  CRUNCH LIBRARY
  111.  
  112.                               Available Commands:
  113.  
  114.                                    IMPLODE     
  115.                                    DEPLODE     
  116.                                    CRMDECRUNCH 
  117.                                    PPDECRUNCH  
  118.  
  119.  
  120. Function: Implode
  121. --------------------------------------------------------------------------
  122. Syntax:   Implode Error/CrunchedLen=Bufferadr,DataLen,?Callback
  123.  
  124. Description:
  125. Crunch a buffer using the Imploder algorythm. The ?Callback could be a 0
  126. for no own routine or a pointer to an own routine for display or abort 
  127. checking. If the Imploder command jump to the callback in register d0 
  128. the current crunch position is presend. The callback itself have to 
  129. return True for cont crunching or False for a break!
  130.  
  131. The command return the crunched buffer len or of course a break or an 
  132. error. If a <0 is returned the callback returned a userbreak, a return 
  133. of 0 means an error happens. Else the new buffer len is returned.
  134.  
  135.  
  136. Function: Deplode
  137. --------------------------------------------------------------------------
  138. Syntax:   Deplode Success=Startadr
  139.  
  140. Description:
  141. Decrunch a Imploder-Crunched buffer. There is no need to give the 
  142. crunched buffer len to the command, imploder handle this by itself. But
  143. be careful, if the alloceted buffer hasn' t enought space the program 
  144. crash.
  145.     
  146.     The buffer has to have a header like this:
  147.  
  148.     Type  Offset  Contents                  Function
  149.     LONG  0       "IMP!"                    To recongnize crunched files
  150.     LONG  4       Original Len              Datalen before packing
  151.     LONG  8       Crunched Len-$32          Datalen after packing
  152.     
  153.     So $a is the start of the datas...
  154.  
  155.     The decrunch routine NEED this header to decrunch!!!
  156.     Do memoryallocation for the buffer using a allocate for the 
  157.     Startadr+$4 size.
  158.  
  159.  
  160. Command: CrMDecrunch
  161. --------------------------------------------------------------------------
  162. Syntax:  CrMDecrunch Bufferadr [,Destinationadr]
  163.  
  164. Description:
  165. If the only parameter is the Bufferadr this routine works like the 
  166. Deplode command, but decrunch a CrunchMania crunched file. If you use it
  167. with to parameters the decrunch will be done from Bufferadr to 
  168. Destinationadr, so 2 buffers have to been allocated. 
  169.  
  170.     The header for CrunchMania files have to look like this:
  171.  
  172.     Type  Offset  Contents                   Function
  173.     --------------------------------------------------------------------
  174.     LONG  0       "CrM!"/"CrM2"              To recongnize crunched 
  175.                                              files.
  176.     
  177.     WORD  4       Minimum Security Distance  To savely decrunch Data 
  178.                                              when Source AND Dest is
  179.                                              in the same Memoryblock.
  180.  
  181.     LONG  6       Original Len               Datalen before packing
  182.  
  183.     LONG  10 ($a) Crunched Len               Datalen after packing 
  184.                                              without header.
  185.  
  186.     So at $d is the data startadress.
  187.  
  188.     This header is NEEDED for decrunching!
  189.  
  190.  
  191. Command: PPDecrunch
  192. --------------------------------------------------------------------------
  193. Syntax: PPDecrunch Bufferadr,Bufferend,Destinationadr
  194.  
  195. Description:
  196. This command decrunch a PowerPacker crunched file. PowerPacker need two
  197. buffers for decrunching. Also the lenght of the buffer must be given!
  198.  
  199. Sorry, I can' t find my PowerPacker archive where the header is 
  200. descripted...Like Imploder and CrunchMania PowerPacker also support his 
  201. own file header.
  202.  
  203. Please have a look at the PowerPacker(.library) documentation!
  204.  
  205.  
  206.                                  LOCALE LIBRARY
  207. --------------------------------------------------------------------------
  208.  
  209.                               Available commands:
  210.  
  211.                                    ISLOCALE     
  212.                                    USECATALOG   
  213.                                    FREECATALOG  
  214.                                    GETLOCALESTR 
  215.  
  216.  
  217. Function: IsLocale
  218. --------------------------------------------------------------------------
  219. Syntax:   result=IsLocale
  220.  
  221. Description:
  222. There is now way to check the ROM-Version of the Kickstart for locale 
  223. presents. Both, OS 2.0 and 2.1 have the ROM-Version 37.175! So the 
  224. command returns if the locale.library exists on the system.
  225.  
  226.  
  227. Command: UseCatalog
  228. --------------------------------------------------------------------------
  229. Syntax: UseCatalog Catalogname
  230.  
  231. Description:
  232. Opens the catalog for your programm. Might by your program is called 
  233. BB2Program the catalog should be called BB2Program.catalog. But you're 
  234. also able to open a catalog from an other program, like Term.catalog.
  235.  
  236. The catalog files are in an IFF format!!! Read the Commodore 
  237. documentation of it...
  238.  
  239.  
  240. Command: FreeCatalog
  241. --------------------------------------------------------------------------
  242. Syntax:  FreeCatalog
  243.  
  244. Description:
  245. Removes the catalog that you opened with UseCatalog.
  246.  
  247.  
  248. Function: GetLocaleStr
  249. --------------------------------------------------------------------------
  250. Syntax: GetLocaleStr #StringNumber,DefaultString$
  251.  
  252. Description:
  253. Read a string from the catalog that you opened with UseCatalog. You have
  254. to give a defaultstring to that command. If the asked string could be 
  255. find in the catalog the default string will be returned. Else the string 
  256. from the catalog will be returned.
  257.  
  258.  
  259.                                REQUESTER LIBRARY
  260. --------------------------------------------------------------------------
  261.  
  262.                               Available Commands:
  263.  
  264. Function: EasyRequest
  265. --------------------------------------------------------------------------
  266. Syntax:   EasyRequest Result=EasyRequest([#Window,]title$,body$,gtext$)
  267.  
  268. Description:
  269. A intuition system requester will be open. Optional you could give a 
  270. window number. The title$ is the displayed string in the top. body$ is 
  271. the displayed text in the requester, a Chr$(10) means a linefeed.
  272.  
  273. gtext$ is the text for the gadgets. Every gadgettext will be added by a 
  274. '|'.  
  275.  
  276. Examples:  "Ok" will only display one gadget in the requester.
  277.            "Ok|Cancel" add two gadgets to it.
  278.            "1|2|3|4|5" five gadgets are displayed.
  279.  
  280.  
  281.  
  282.                              AMIGA SUPPORT LIBRARY
  283. --------------------------------------------------------------------------
  284.  
  285.                               Available Commands:
  286.  
  287.                                    ALLOCMEM     
  288.                                    FREEMEM      
  289.                                    ISEVEN       
  290.                                    SEARCHSTRING 
  291.  
  292.  
  293. Function: AllocMem
  294. --------------------------------------------------------------------------
  295. Syntax:   MemoryBlock=AllocMem(Size,Type)
  296.  
  297. Description:
  298. Unlike calling Exec's AllocMem_ command directly Blitz2 will automatically
  299. free any allocated memory when the program ends. Programmers are advised
  300. to use the InitBank command.
  301.  
  302. Flags that can be used with the memory type parameter are:
  303.  
  304. 1=public    ;fast is present
  305. 2=chipmem
  306. 65536=clear ;clears all memory allocated with 0's
  307.  
  308.  
  309. Command: FreeMem
  310. --------------------------------------------------------------------------
  311. Syntax:  FreeMem MemoryBlock,ByteSize
  312.          (long)    (long)
  313.  
  314. Description:
  315. Deallocates memory obtained with AllocMem
  316.  
  317.  
  318. Function: IsEven
  319. --------------------------------------------------------------------------
  320. Syntax:   Result=IsEven(Expression)
  321.           (bool)  (byte,word,long)
  322.  
  323. Description:
  324. Returns true if Expression is even.  Of use when requesting a value from
  325. a user that MUST be even.
  326.  
  327.  
  328. Function: SearchString
  329. --------------------------------------------------------------------------
  330. Syntax:   result=SearchString(StringPointer,StartAddress,BlockLength)
  331.           (long)                (&string)    (long)        (long)
  332.  
  333. Description:
  334. Finds a string in the given memory block and returns its address. 
  335. Returns False otherwise.
  336.  
  337.  
  338.       BUM #6 contains almost all the PD commands of Elmore and some more.
  339.  
  340.                          DOS ELMORE LIBRARY      
  341.                          HARDWARE ELMORE LIBRARY 
  342.                          MATH ELMORE LIBRARY     
  343.                          ARRAY ELMORE LIBRARY    
  344.                          SYS ELMORE LIBRARY      
  345.                          STRING ELMORE LIBRARY   
  346.                          LIBRARY PROGRAMMING     
  347.  
  348.                                  New in BUM7 :
  349.  
  350.                          INCLUDE LIBRARY         
  351.  
  352.                              (For the uninitiated:)
  353.  
  354.                   NOTE ON FUNCTIONS, STATEMENTS and COMMANDS:
  355.                   -------------------------------------------
  356.  
  357. "FUNCTIONS" are Blitz2 tokens that require parameters in parentheses, 
  358. and return a value: n=ABS(m)
  359.  
  360. "STATEMENTS" are Blitz2 tokens that only perform an action but do not 
  361. return a value.  Their arguments do not require parentheses:
  362. PRINT "HELLO!"
  363.  
  364. "COMMANDS" are Blitz2 tokens that can be used as either a FUNCTION or 
  365. a STATEMENT, depending upon whether the arguments were in parentheses or
  366. not.
  367.  
  368. [Function form:]
  369. n=REQUEST("TITLE","SELECT YES OR NO","YES|NO")
  370.  
  371. [Statement form:]
  372. REQUEST "TITLE","SELECT OK TO CONTINUE","OK"
  373.  
  374.  
  375.                                DOS.ELMORE LIBRARY
  376. --------------------------------------------------------------------------
  377.  
  378.                          CHDIR               ENTRYHOUR     
  379.                          PATHLOCK            ENTRYMINS     
  380.                          COPYFILE            ENTRYSECS     
  381.                          SETCOPYBUFFER       ENTRYCOMMENT$ 
  382.                          NAMEFILE            ANALYZEDISK   
  383.                          MAKEDIR             DISKUNIT      
  384.                          MOREENTRIES         DISKERRS      
  385.                          ENTRYNAME$          DISKCAPACITY  
  386.                          ENTRYDIR            DISKUSED      
  387.                          ENTRYBIT$           DISKFREE      
  388.                          ENTRYSIZE           DISKBLOCKS    
  389.                          ENTRYDATE     
  390.  
  391.                                 DIRECTORY EXAMPLE 
  392.  
  393.  
  394.  
  395. Command: CHDIR
  396. --------------------------------------------------------------------------
  397. Syntax: CHDIR "Path:"  -or-  IF CHDIR("Path:") Then...
  398.  
  399. This command will change the current working directory for ALL disk-
  400. related commands.  Used as a function, a value of TRUE will be returned
  401. if the directory change was successful, or FALSE if it was unsuccessful.
  402.  
  403.  
  404. Function: PATHLOCK
  405. --------------------------------------------------------------------------
  406. Syntax: Lock.l=PATHLOCK
  407.  
  408. This function will return the BCPL pointer to the lock of the current
  409. directory.  You should NEVER "Unlock_" this lock, but it is useful to
  410. use command "NameFromLock_" with it to determine the full pathname of
  411. the current directory, for example.  (NOTE: NameFromLock_ requires 2.0
  412. and above!)
  413.  
  414.  
  415. Command: COPYFILE
  416. --------------------------------------------------------------------------
  417. Syntax: COPYFILE "First","SECOND"  -or-  IF COPYFILE("FIRST","SECOND") Then...
  418.  
  419. This command will copy files, much like the CLI command "Copy."  In the
  420. function form, it will return TRUE for success, and FALSE for failure.
  421. Note that the speed at which it copies can be increased by increasing the
  422. "CopyBuffer," which defaults to 8192 bytes.  (See below)
  423.  
  424.  
  425. Statement: SetCopyBuffer
  426. --------------------------------------------------------------------------
  427. Syntax: SetCopyBuffer BUFFERSIZE
  428.  
  429. This statement is used to set the size of the COPYFILE command's memory
  430. buffer.  The default size is 8192 bytes, but this can be adjusted from
  431. 256 bytes to nearly all your free memory.  A larger buffer will normally
  432. increase the speed at which the COPYFILE command operates, but only up to
  433. the size of the largest file you're copying.  For example, if the largest
  434. file you need to copy is 25000 bytes, then it will be useless to set the
  435. COPYBUFFER above 25000.
  436.  
  437.  
  438. Command: NAMEFILE
  439. --------------------------------------------------------------------------
  440. Syntax: NAMEFILE "Oldname","Newname"  -or-
  441.         IF NAMEFILE("Oldname","Newname") Then...
  442.  
  443. This command returns FALSE for failure, TRUE for success:
  444. The file "oldname" is renamed to "newname," if possible, and may be moved
  445. to other directories within the same volume.  It is not yet possible to
  446. use NAMEFILE to move a file from one volume to another, however.
  447.  
  448.  
  449. Command: MAKEDIR
  450. --------------------------------------------------------------------------
  451. Syntax: NAMEFILE "Path:Dir"  -or-  If NAMEFILE("Path:Dir") Then...
  452.  
  453. This command will attempt to create a new directory with the given pathname.
  454. It is only possible to create one level at a time, however.  For example,
  455. MAKEDIR will fail if you attempt to MAKEDIR "RAM:New/Data" if the directory
  456. "RAM:New" does not yet exist.  Used as a function, MAKEDIR returns TRUE for
  457. success, and FALSE for failure.
  458.  
  459.  
  460. Command: MOREENTRIES
  461. --------------------------------------------------------------------------
  462. Syntax: MOREENTRIES  -or-  If MOREENTRIES Then...
  463.  
  464. This command will read the next entry in the current directory for
  465. inspection with other "ENTRY" commands.  Used within a loop, it is easy
  466. to read an entire directory with these commands, similar to the "DIR" or
  467. "LIST" commands of AmigaDOS.  (See below.  An example follows)
  468.  
  469.  
  470. Function: ENTRYNAME$
  471. --------------------------------------------------------------------------
  472. Syntax: n$=ENTRYNAME$
  473.  
  474. This function returns the name of the current directory entry.  If used
  475. before the fist "MOREENTRIES" command, it will return the name of the
  476. current directory.  (Just the current directory's name, not the full
  477. path name)
  478.  
  479.  
  480. Function: ENTRYDIR
  481. --------------------------------------------------------------------------
  482. Syntax: If ENTRYDIR Then...
  483.  
  484. This function returns TRUE if the current entry is a sub-directory, or
  485. FALSE if it is a file.
  486.  
  487.  
  488. Function: ENTRYBITS$
  489. --------------------------------------------------------------------------
  490. Syntax: n$=ENTRYBITS$
  491.  
  492. This function returns a string containing the protection-bits status of
  493. the current file or directory.  An example may be "----RWED"  the same
  494. format as given by the AmigaDOS "LIST" command.  Possible bit settings
  495. are HSARWED:  H=HIDDEN, S=SCRIPT, A=ARCHIVED, R=READABLE, W=WRITEABLE,
  496. E=EXECUTEABLE, D=DELETEABLE.
  497. Any bits that are not set will have the "-" character in their place.
  498.  
  499.  
  500. Function: ENTRYSIZE
  501. --------------------------------------------------------------------------
  502. Syntax: n.l=ENTRYSIZE
  503.  
  504. This function returns the size in bytes of the current directory entry.
  505. Note that sub-directories return a size of zero whether they are empty
  506. or not.
  507.  
  508.  
  509. Function: ENTRYDATE
  510. --------------------------------------------------------------------------
  511. Syntax: d$=DATE$(ENTRYDATE)
  512.  
  513. This function returns the date the current entry was last modified, in
  514. the same format as SYSTEMDATE uses.  (The number of days since 1/1/1978)
  515. Thus, you may use the DATE$ and DATEFORMAT commands to translate it into
  516. a string with a more human-readable string.
  517.  
  518.  
  519. Function: ENTRYHOUR, ENTRYMINS, ENTRYSECS
  520. --------------------------------------------------------------------------
  521. Syntax: h=ENTRYHOUR:m=ENTRYMINS:s=ENTRYSECS
  522.  
  523. ENTRYHOUR:
  524. This function is related to ENTRYDATE, above, but returns the hour of the
  525. day (0-23) at which the entry was last modified.
  526.  
  527. ENTRYMINS:
  528. Returns the minute (0-59) of the time at which the entry was modified.
  529.  
  530. ENTRYSECS:
  531. Returns the second (0-59) of the time at which the entry was modified.
  532.  
  533.  
  534. Function: ENTRYCOMMENT$
  535. --------------------------------------------------------------------------
  536. Syntax: c$=ENTRYCOMMENT$
  537.  
  538. This function will return the string containing the filenote for the
  539. current directory entry, or "" if there is none.
  540.  
  541.  
  542. *********************
  543. * DIRECTORY EXAMPLE *
  544. *********************
  545.  
  546. This example will list the entries in RAM: in a format very similar
  547. to the AmigaDOS "LIST" command.  Note that you need to "ChDir" to
  548. a directory in order to read it from the first entry again.
  549.  
  550.  
  551. ChDir "RAM:"
  552.  
  553. While MoreEntries
  554.   Print LSet$(EntryName$,30)
  555.   If EntryDIR then Print "Dir   " Else Print LSet$(Str$(EntrySize),6)
  556.   Print EntryBits$," ",Date$(EntryDate)," "
  557.   Print EntryHour,":",Right$("0"+Str$(EntryMins),2),":"
  558.   NPrint Right$("0"+Str$(EntrySecs),2)
  559. Wend
  560. MouseWait
  561.  
  562.  
  563. Command: ANALYZEDISK
  564. --------------------------------------------------------------------------
  565. Syntax: ANALYZEDISK "DRIVE:"  -or-  If ANALYZEDISK "DRIVE:" Then...
  566.  
  567. This command returns FALSE if the specified device or pathname was not
  568. valid.  If successful, details about the specified drive can be read with
  569. the following "DISK" functions.  The values for these functions will not
  570. change until ANALYZEDISK is executed again, either on the same drive or
  571. another one.
  572. Note:  If given a full pathname, such as "DF0:System/Utilities" this
  573. command will still know enough to analyze the disk "DF0:"
  574.  
  575.  
  576. Function: DISKUNIT
  577. --------------------------------------------------------------------------
  578. Syntax: n=DISKUNIT
  579.  
  580. This function will return the unit number of the most recently analyzed
  581. disk.  DF0: for example, would return zero, while DF1: would return 1.
  582.  
  583.  
  584. Function: DISKERRS
  585. --------------------------------------------------------------------------
  586. Syntax: n=DISKERRS
  587.  
  588. This function will return the number of soft errors DOS knows about on
  589. the last analyzed disk.  This should normally be zero.
  590.  
  591.  
  592. Function: DISKCAPACITY
  593. --------------------------------------------------------------------------
  594. Syntax: n=DISKCAPACITY
  595.  
  596. This function returns the capacity in bytes of the last analyzed drive.
  597. For example, a fastfilesystem-formatted disk's max capacity is 837K, so
  598. DISKCAPACITY would return 857904, which divided by 1024 is 837.
  599.  
  600.  
  601. Function: DISKUSED
  602. --------------------------------------------------------------------------
  603. Syntax: n=DISKUSED
  604.  
  605. This function returns the number of bytes actually in-use on the last
  606. analyzed drive.
  607.  
  608.  
  609. Function: DISKFREE
  610. --------------------------------------------------------------------------
  611. Syntax: n=DISKFREE
  612.  
  613. The opposite of DISKUSED, DISKFREE returns the number of bytes free
  614. on the disk.  This function would be very useful, for example, in a
  615. program that needed to save information to disk.  You would be able
  616. to first determine if the specified SAVE disk had sufficient space.
  617.  
  618.  
  619. Function: DISKBLOCKS
  620. --------------------------------------------------------------------------
  621. Syntax: n=DISKBLOCKS
  622.  
  623. This function returns the number of bytes each block on a disk uses,
  624. making it possible to convert the byte-values of the above functions
  625. to number of blocks.
  626.  
  627.  
  628.                                  BUM7 MAIN DOC
  629.  
  630.                         Updates and Fixes to Blitz2 v1.9
  631.  
  632.  
  633.  NEW COMMANDS           
  634.  NEW LIBRARY'S INCLUDED 
  635.  
  636.  
  637. Stability
  638. --------------------------------------------------------------------------
  639. Several improvements have been made to the stability of Blitz2 programs.
  640. First up all string commands have been fixed to both work properly with
  641. the null-termination system introduced in v.18 (our apologies here) and
  642. error checking has been added. No longer will system crashes be caused
  643. with illegal size parameters in mid$() etc.
  644.  
  645. Also, the ASMEND command has been added. Using assembler in statements
  646. and functions use to require the use of UNLK A4 and RTS. This system
  647. did not work properly when runtime errors were enabled. A fullproof
  648. method is now available, simply use the ASMEND command in place of any
  649. RTS commands. Blitz2 will look after the unlinking of A4, allow for
  650. runtime errors and then do an RTS. Finally my darts demo runs with
  651. runtime errors enabels (yipeeee!).
  652.  
  653. And finally, runtime error checking has been added for square bracket
  654. arrays. Yup, out of range checking has been incorporated for those of
  655. us whose first guess at why our programs were crashing was to go through
  656. and check such usage manually. This with the new string checking and the
  657. sexy new debugger should return a few people to using Blitz2's runtime
  658. debugging features. Thanks to all those and their abuse for helping us
  659. get these problems resolved.
  660.  
  661. Debugging
  662. --------------------------------------------------------------------------
  663. The debugger is now a separate program that is launched by Blitz2 when a
  664. prgram is run (runtime errors enabled of course).
  665.  
  666. The gadgets in the window allow the programmer access to the standard
  667. debugging features. CtrlAltC can still be used to halt programs, 
  668. especially those using Slices and Displays in Blitz mode.
  669.  
  670. By increasing the size of the window the program listing can be viewed.
  671.  
  672. A PANIC! button has also been introduced once a program is launched from
  673. the editor. Yup, programs are now launched not run so those into weird
  674. system crashes may be able to return to Ted leaving their programs 
  675. disabled in memory. A REBOOT button may have been more useful...
  676.  
  677. The source code for the default debugger is included in the acidlibsrc
  678. directory of the libsdev archive. It is extremely well documented by
  679. Mark so those wanting to extend the functionality of the system are
  680. most welcome. Serial port support for using a remote terminal would
  681. be very nice.
  682.  
  683. Interupts and BlitzKeys
  684. --------------------------------------------------------------------------
  685. BlitzKeys, BlitzKeys, BlitzKeys. A common profanity used by those of us
  686. use to keyboard lock ups in keyboard based Blitz games (especially
  687. SkidMarks). Well no more!
  688.  
  689. Blitz now leaves Amiga interupts enabled in Blitz mode. This means that
  690. not only is the system keyboard interupt still running (thank the lord)
  691. but any SetInts initiated in Amiga mode will continue.
  692.  
  693. Other advantages are that Blitz mode is now more acceptable to the CD32
  694. environment and RawStatus can be used in Amiga mode for keyboard games
  695. not wanting to run in Windows (yuck).
  696.  
  697. Blitzkeys On now does a bit of a "BlitzkeysInput" for one character inputs
  698. only, any other inputs use the previously defined Input channel.
  699.  
  700. Blitzkeys Off no longer exists. BlitzRepeat has gone (no repeating keys).
  701.  
  702. Serial Stuff
  703. --------------------------------------------------------------------------
  704. Peter Tavinor has upgraded the Serial Library. ReadSerial now return a
  705. word (read unsigned byte) so chr$(255) is acceptable. WriteSerialString
  706. includes flags for DoIO and True String (not null terminated). ReadSerial
  707. has a new flag "WaitForChar"
  708.  
  709. GadTools
  710. --------------------------------------------------------------------------
  711. The GTPalette has had several default tags removed as they crashed under
  712. 2.0 (yeh, great, just what tags are suppose to avoid). AttachGTList had
  713. a minor problem in some situations (now fixed).
  714.  
  715. Another bug that has been found in GadTools under 2.0 is that GTLists
  716. actually allocate gadget id's for internal use. Besides being completely
  717. unethical (and fixed in 3.0) it means that programmers should use id
  718. values of greater than 50 to avoid this system bug. Adding GTLists last
  719. in your list should also work although their id's should be more than the
  720. number of lines of text they should display (no I am not going to explain
  721. further).
  722.  
  723. ScreensLib
  724. --------------------------------------------------------------------------
  725. The Screen command now rounds the width up to the nearest multiple of 16
  726. rather than causing the error "Screen Width Must be a multiple of 16".
  727. Common sense I think.
  728.  
  729. ValLib
  730. --------------------------------------------------------------------------
  731. Val() now accepts hex and binary strings (preceeded by "$" and "%" of 
  732. course.) Because Val() returns a float it should not be used to evaluate 
  733. 32 bit integers (longs).
  734.  
  735. Display Library
  736. --------------------------------------------------------------------------
  737. A quick version of the InitCoplist command has been included which 
  738. calculates the number of colours, sprites and size depending on just the 
  739. type parameter.
  740.  
  741. As promised the Display library now sports new commands for palette 
  742. effects and so forth. There are two varieties of copper based commands, 
  743. the first allows the user to insert a new palette or copperstring at a 
  744. certain line of the display, the other allows control of each and every 
  745. line of the display.
  746.  
  747. For line based effects a negative value should be used in combination
  748. with the numcustoms parameter of the InitCopList command. Color splits,
  749. bitmap scrolling, scan doubling/trebling/quadrupling and custom copper
  750. strings can now be acheived on a line by line basis.
  751.  
  752.  
  753. Palette Library.
  754. --------------------------------------------------------------------------
  755. A number of commands have been added to the Palette library for use mainly
  756. with the display library. Fades and Colour cycling can now be performed on
  757. palette objects themselves (rather than on screens and slices) and hence
  758. can be used in conjunction with the DisplayPalette command.
  759.  
  760.  
  761. Banks and Decoding.
  762. --------------------------------------------------------------------------
  763. Decode commands have been added to allow programmers to both include 
  764. shapes, sounds, palettes, music and ILBM's (IFF bitmaps) in their programs 
  765. or from preloaded files (mainly using the LoadBank command or unpacking 
  766. type commands).
  767.  
  768. To include such files in the program the incbin command is used. 
  769. Typically a list of included files will be situated at the bottom of the 
  770. listing (with and End statement just above to be safe). Each IncBin will 
  771. be preceeded by a label and the ?label syntax would be used to pass the 
  772. location of each included file to the appropriate Decode command at the 
  773. top of the program.
  774.  
  775. Those unhappy with the slow but memory unhungry LoadBitMap command can 
  776. take advantage of the fast but memory hungry method of loading iff/ilbm 
  777. files with the code listed in the DecodeILBM command description.
  778.  
  779. Argslib fixes
  780. --------------------------------------------------------------------------
  781. This library processes arguments passed to it.  A few fixes have mainly
  782. been made over the old one.
  783.  
  784. 1)  Quoted arguments count as one argument.  EG "One arg"  will give your
  785.     program both words as one argument, not 2.
  786.  
  787. 2)  Mulitple workbench arguments are allowed now.
  788.  
  789.  
  790. If you are to use workbench arg handling, you MUST have WBSTARTUP at the 
  791. top of your program!!
  792.  
  793.  
  794.  
  795.                Here are all the new library's included with BUM7:
  796.  
  797.                   AARONSICONLIB         RICOMMODITIESLIB   
  798.                   ELMORELIBS            RIENCRYPTLIB       
  799.                   ELMOREINCLIB          RIFXLIB             
  800.                   FUZZIESREQLIB         RIGFXLIB            
  801.                   NEILSCIATRACKERLIB    RIPACKLIB          
  802.                   NEILSPROGRESSLIB      RIREQLIB           
  803.                   NEILSREQTOOLSLIB      RITOOLTYPESLIB         
  804.                   RIAMOSFUNCLIB         RITRACKDISKLIB        
  805.                   RIANIMLIB             RIZONEJOYLIB           
  806.                   RIAPPLIB/WBLIB        ROMULUSLIBS                 
  807.  
  808.  
  809.  
  810.  
  811. Look for these commands in:  CRUNCHLIB    
  812.                  PRINTERLIB   
  813.                              REQUESTERLIB 
  814.                              LOCALE LIB   
  815.                              CONSOLE LIB  
  816.  
  817.  
  818.  
  819. Library Name: riencryptlib #55
  820. Authors     : ReflectiveImages, 17 Mayles Road, Southsea, Portsmouth, 
  821.               Hampshire, UK PO4 8NP
  822. OverView    : Another Reflective Images Library, good for war games?
  823.  
  824.  
  825.                                  Authors Docs:
  826.  
  827.                                 RIEncryptLibrary
  828.  
  829.                             Date sent: 26-AUG-1994 
  830.  
  831. --------------------------------------------------------------------------
  832. You can have this little library if you like.  Sorry there are no full 
  833. docs in the archive - the lib was done in a hurry for someone.  It 
  834. performs Enigma compression and is very cute ;-).
  835. The archive contains the source code for the library.  I'm sure it 
  836. wouldn't take you a second to have a look at it ;-).
  837.  
  838. Commands in the library:
  839.  
  840.   Encrypt memadr,len[,wheel1,wheel2,wheel3]
  841.  
  842. This will encrypt a block of memory starting at the address and running 
  843. through to addresslength-1.  The optional wheel parameters allow you to
  844. specify the start positions of the three wheels.  If you leave these out
  845. then the wheels' start positions will be randomised.
  846.  
  847.   GetWheel n
  848.  
  849. This will tell you the position that wheel n stopped at after encrypting 
  850. a file.  n can range from 1 to 3 - YOU MUST REMEMBER THESE POSITIONS
  851. IF YOU WANT TO DECRYPT THE FILE (at the moment at least).
  852.  
  853.   Decrypt memadr,len,wheel1,wheel2,wheel3
  854.  
  855. Same Encrypt except that it does the opposite and the wheel positions ARE 
  856. NOT OPTIONAL.  The positions should be the ones you wrote down after 
  857. encrypting the file.  I may, in future, change it so that you can also
  858. specify the start wheel positions instead of the end ones (shouldn't be 
  859. tooooo hard ;-)).
  860.  
  861. Oh well, have a look and tell us what you think............
  862.  
  863.  
  864.  
  865. Library:  neilsreqtoolslib #54
  866. Author:   Neil O'Rourke, 6 Victoria St, TAMWORTH, NSW 2340, AUSTRALIA
  867. Overview: Access to the ReqTools library.
  868.  
  869.  
  870.  RTEZREQUEST                   RTEZGETSTRING              
  871.  RTEZFLAGSREQUEST              RTLOCKWINDOW               
  872.  RTEZFONTREQUEST               RTUNLOCKWINDOW             
  873.  RTEZSCREENMODEREQUEST         RTVERSION                  
  874.  RTEZPALETTEREQUEST            RTREVISION                 
  875.  RTEZLOADFILE                  ISREQTOOLSACTIVE           
  876.  RTEZSAVEFILE                  RTASYNCREQUEST             
  877.  RTEZPATHREQUEST               RTCHECKASYNCREQUEST        
  878.  RTEZMULTILOADFILE             RTENDASYNCREQUEST          
  879.  RTEZRNEXTPATHENTRY            RTASYNCPALETTEREQUEST      
  880.  RTEZSETDEFAULTDIRECTORY       RTCHECKASYNCPALETTEREQUEST 
  881.  RTEZSETPATTERN                RTENDASYNCPALETTEREQUEST   
  882.  RTEZFREEPATTERN               RTREQUEST                  
  883.  RTEZGETLONG                   RTFILEREQUEST              
  884.  RTEZGETLONGRANGE            
  885.  
  886.  
  887.                              Author's Documentation
  888.                                ReqToolslib V1.70b
  889.  
  890.                                  Neil O'Rourke
  891.  
  892.                                 ** BETA FOUR **
  893.  
  894.           This is an implementation of Nico Franco's ReqTools library.
  895.  
  896. There are two different implementations of each function, a simple one
  897. (denoted by EZ (pronounced E-Zee) in the command name),  and a complex 
  898. one. The simple implementation has bog standard requesters that the 
  899. programmer has little (if any) control over.  The purpose of these is to 
  900. get your programs working fast (or it could be that you don't need all the
  901. fancy options that are available), with a minimum of setup for the 
  902. requesters. That isn't to say the requesters aren't powerful; on the 
  903. contrary, ReqTools requesters leave ASL requesters in the dust when it 
  904. comes down to sheer power.
  905.  
  906. The more complex implementation requires you to build a TagList and supply
  907. it to the requester.  This shouldn't really be needed, as all the EZ
  908. requesters have a resonable set of defaults and options to avoid this.
  909.  
  910. All the ReqTools requesters attach themselves to the window that DOS 
  911. errors are.  To do this, simply make your window the current window with 
  912. Use Window WindowNum, then CatchDosErrs.  By default, the requesters will 
  913. go to the Workbench.
  914.  
  915.  
  916. Compatibility
  917. ~~~~~~~~~~~~~
  918. All ReqTools requesters, with the exception of the ScreenMode request, are
  919. compatible with KickStart 1.3.
  920.  
  921. DO NOT CALL RTEZSCREENMODEREQUEST IF YOU ARE RUNNING 1.3!! THIS IS YOUR 
  922. RESPONSIBILITY!
  923.  
  924.  
  925. Future Directions
  926. ~~~~~~~~~~~~~~~~~
  927. The recent releases of ReqTools have included a preferences program to
  928. control the behaviour of requesters.  This does not sit well with the
  929. pre-programmed options that my interface code uses.  It could be that
  930. future releases of ReqToolsLib will not set these, but this is early days
  931. and only time and user feed-back will indicate the path to go.
  932.  
  933.  
  934.  
  935. The doc file was so much damaged that I could not convert it....If 
  936. somebody has a good file, please send or mail it to me!
  937.  
  938.  
  939. Function: RTEZRequest
  940. --------------------------------------------------------------------------
  941. Syntax  : result=RTEZRequest(Title$,BodyText$,GadgetText$ [,ReqPosition
  942.                  [, DefaultResponse, Flags]])
  943.  
  944. Description:
  945. Opens a simple requester in the center of your screen.  You can have 
  946. multiple gadgets in Gadget$, seperate the by a bar (|).
  947.  
  948. To have multiple lines in your gadget, seperate them by a Chr$(10).
  949.  
  950. Title$ can be whatever you want.  If it is left blank, the title of the
  951. calling window will be used.
  952.  
  953. The requester auto-adjusts its size to the length of the body text.
  954.  
  955. Also, the requester will block any input to the calling window, and if the
  956. user selects that window he will see the usual wait pointer.
  957.  
  958. The requester returns the number of the gadget selected, gadget zero is 
  959. the extreme right hand gadget (usually Cancel), and numbered from one 
  960. starting from the left hand side of the requester.
  961.  
  962. The optional parameter ReqPos allows relative positioning of the 
  963. requester. You can have the requester open up in the center of the screen
  964. (the default position), or the center of the window, or the TopLeft corner 
  965. of the screen or window.  The valid flags are:
  966.  
  967. #REQPOS_POINTER      =0  Relative to MousePointer
  968. #REQPOS_CENTERWIN    =1  Center of window
  969. #REQPOS_CENTERSCR    =2  Center of screen (default)
  970. #REQPOS_TOPLEFTWIN   =3  TopLeft of the window
  971. #REQPOS_TOPLEFTSCR   =4  TopLeft of the screen (Amiga default)
  972.  
  973. There are two further options:
  974.  
  975. DefaultResponse allows you to change what gadget is selected when the
  976. Return key is hit, and this is by default the left hand gadget (1)
  977.  
  978. Flags controls a few other items in the requester.
  979. #EZREQB_NORETURNKEY  =1   Turns off the return key as positive response
  980. #EZREQB_LAMIGAQUAL   =2   Keyboard shortcuts are limited to LA-V and LA-B
  981. #EZREQB_CENTERTEXT   =4   Centers the text in the requester.
  982.  
  983. You can make keyboard shortcuts for the gadgets by placing an underscore
  984. character '_' before the character you wish to have as the shortcut, for
  985. example your "Ok" gadget could be defined as "_Ok", and Right Amiga-O 
  986. would then satisfy the requester.
  987.  
  988.  
  989. Function: RTEZFlagsRequest
  990. --------------------------------------------------------------------------
  991. Syntax  : result=RTEZFlagsRequest(Title$,BodyText$,GadgetText$,
  992.                  IDCMPFlags[,ReqPos])
  993.  
  994.  
  995. Description:
  996. This requester is similar to the standard RTEZRequest, but it can also be
  997. satisfied by an IDCMP flag (eg DiskInserted).  Either the gadget number or
  998. the IDCMP flag will be returned in result.
  999.  
  1000. This requester also supports no gadgets, by supplying "" as the Gadget
  1001. Text$. Since the window is locked, the user cannot proceed until the 
  1002. request is satisfied.  Use this at your own peril!  This requester can 
  1003. force the user to take an action he may not want to, if you don't supply 
  1004. any gadgets.  Think, have second thoughts, and then think some more.  
  1005. With enough thought, you *will* come to the conclusion that the user 
  1006. needs at least one gadget.
  1007.  
  1008. The ReqPosition flag is also available for this requester, as is the
  1009. keyboard shortcuts.
  1010.  
  1011.  
  1012. Function: RTEZFontRequest
  1013. --------------------------------------------------------------------------
  1014. Syntax  : *MyFont.TextAttr=RTEZFontRequest(Title$)
  1015.  
  1016. Description:
  1017. Brings up the Font requester, and returns a pointer to a TextAttr
  1018. structure.
  1019.  
  1020. The Font requester has had a total rewrite for the V1.7 release of
  1021. ReqToolsLib.  Using it is just the same, but it now returns a saner
  1022. structure.
  1023.  
  1024. The structure is defined:
  1025.  
  1026. NewType.TA
  1027.   Name.s
  1028.   YSize.w
  1029.   Style.b
  1030.   Flags.b
  1031. End Newtype
  1032.  
  1033.  
  1034. Function: RTEZScreenModeRequest
  1035. --------------------------------------------------------------------------
  1036. Syntax  : *MyScreenMode =RTEZScreenModeRequest(Title$ [,DisplayFlags])
  1037.  
  1038. Description:
  1039. Returns a pointer to the following structure:
  1040.  
  1041. NEWTYPE.MyScreenMode
  1042.   DisplayID.l
  1043.   DisplayWidth.w
  1044.   DisplayHeight.w
  1045.   DisplayDepth.w
  1046.   OverscanType.w
  1047.   AutoScroll.l
  1048. End NEWTYPE
  1049.  
  1050. The DisplayFlags field allows you to have control over what options you
  1051. offer the user.  By default, the requester has a resonable set of options,
  1052. but you may wish to add too (or subtract from) these.
  1053.  
  1054. Allowable flags are:
  1055. #SCREQF_OVERSCANGAD  -    Add an overscan cycle gadget to the requester.  
  1056.             After the requester returns you may read the 
  1057.             overscan type in '\OverscanType'  If this is 0 no 
  1058.             overscan is selected
  1059.             (Regular Size), if non-zero it holds one of the
  1060.             OSCAN_... values defined in the include file 
  1061.             'intuition /screens.[h|i]'.
  1062. #SCREQF_AUTOSCROLLGAD-    Add an autoscroll checkbox gadget to the requester.
  1063.             After the requester returns read '\AutoScroll' to 
  1064.             see if the user prefers autoscroll to be on or off.
  1065. #SCREQF_SIZEGADS     -    Add width and height gadgets to the requester.  If
  1066.             you do not add these gadgets the width and height 
  1067.             returned will be the default width and height for 
  1068.             the selected overscan type.
  1069. #SCREQF_DEPTHGAD     -    Add a depth slider gadget to the requester.  If you
  1070.             do not add a depth gadget, the depth returned will 
  1071.             be the maximum depth this mode can be opened in.
  1072. #SCREQF_NONSTDMODES  -    Include all modes. Unless this flag is set
  1073.             RTEZScreenModeRequest() will exclude nonstandard 
  1074.             modes. Nonstandard modes are presently HAM and EHB 
  1075.             (ExtraHalfBrite). So unless you are picking a mode 
  1076.             to do some rendering in leave this flag unset.  
  1077.             Without this flag set the mode returned will be a 
  1078.             normal bitplaned mode.
  1079. #SCREQF_GUIMODES     -    Set this flag if you are getting a screen mode to
  1080.             open a user interface screen in.  The modes shown 
  1081.             will be standard modes with a high enough 
  1082.             resolution (minumum 640 pixels).  If this flag is 
  1083.             set the SCREQF_NONSTDMODES flag is ignored.
  1084.  
  1085. Do not attempt to call this requester under WB1.3.
  1086.  
  1087.  
  1088. Function: RTEZPaletteRequest
  1089. --------------------------------------------------------------------------
  1090. Syntax  : SelectedColour.w=RTEZPaletteRequest(Title$,FirstColour)
  1091.  
  1092. Description:
  1093. Brings up the Palette requester.  Returns the last colour the user
  1094. selected, or -1 if the user hit cancel.  If the user changed the colours,
  1095. they are reflected in the viewport that the window is attached to.
  1096.  
  1097.  
  1098. Function: RTEZLoadFile
  1099. --------------------------------------------------------------------------
  1100. Syntax  : name$=RTEZLoadFile(Title$,FileName$)
  1101.  
  1102. Description:
  1103. This brings up the standard file requester.  The directories are buffered,
  1104. so it doesn't have to reload the directory each time it is called.  Note 
  1105. that FileName$ must be at least 108 characters long (use the MaxLen 
  1106. function of this).
  1107.  
  1108. Note that by default, pattern matching is not enabled.  If you want to
  1109. match a particular pattern, use the RTEZSetPattern command described below.
  1110.  
  1111. Also, the file name isn't copied to FileName$.  You can have a default
  1112. file name by writing to FileName$, but this will be cleared after the call
  1113. finishes.  This is also true of the SaveFile requester.
  1114.  
  1115.  
  1116. Function: RTEZSaveFile
  1117. --------------------------------------------------------------------------
  1118. Syntax  : name$=RTEZSaveFile(Title$,FileName$)
  1119.  
  1120. Description:
  1121. A seperate requester, the SaveFile requester is different from the 
  1122. LoadFile requester in a number of ways.  First, it has a seperate buffer 
  1123. from the LoadFile requester.  Second, the OK text is changed to Save. 
  1124. Third, the user cannot double-click a file to select it, to prevent 
  1125. accidental deletions.  Finally, if the user types in a non-existent 
  1126. directory, he will be asked if he would like that directory created.
  1127.  
  1128. FileName$ must be at least 108 bytes long as well.
  1129.  
  1130. Note that by default, pattern matching is not enabled.  If you want to
  1131. match a particular pattern, use the RTEZSetPattern command described below.
  1132.  
  1133.  
  1134. Function: RTEZPathRequest
  1135. --------------------------------------------------------------------------
  1136. Syntax  : name$=RTEZPathRequest(Title$)
  1137.  
  1138. Description:
  1139. Prompts the user to select a path.  This is also a seperate requester to
  1140. the LoadFile and SaveFile requesters, and maintains its own directory list.
  1141.  
  1142.  
  1143. Function: RTEZMultiLoadFile
  1144. --------------------------------------------------------------------------
  1145. Syntax  : ret.l=RTEZMultiLoadFile(Title$)
  1146.  
  1147. Description:
  1148. Allows the user to select multiple files for loading (this makes no sense
  1149. for saving).  ret is either True for a list having been selected, or False
  1150. if the user cancelled.
  1151.  
  1152. If you call RTEZMultiLoadFile, any previous FileList that was loaded is
  1153. deleted, even if the user cancels the requester.
  1154.  
  1155.  
  1156. Function: RTNextPathEntry
  1157. --------------------------------------------------------------------------
  1158. Syntax  : name$=RTNextPathEntry
  1159.  
  1160. Description:
  1161. This function returns the next file from a RTEZMultiLoadFile call, or a
  1162. null string is there is no entry, so you can safely loop about until an
  1163. empty string is returned.
  1164.  
  1165.  
  1166. Statement: RTEZSetDefaultDirectory
  1167. --------------------------------------------------------------------------
  1168. Syntax   : RTEZSetDefaultDirectory Requester#,Directory$
  1169.  
  1170. Description:
  1171. This can be used to set a default directory for the user. Directory$ is
  1172. the default path, and Requester# is one of the following:
  1173. 0 - EZLoadFile
  1174. 1 - EZSaveFile
  1175. 2 - EZPathRequest
  1176. 3 - EZMultiLoadFile
  1177.  
  1178.  
  1179. Statement: RTEZSetPattern
  1180. --------------------------------------------------------------------------
  1181. Syntax   : RTEZSetPattern Requester#,Pattern$
  1182.  
  1183. Description:
  1184. Enables and sets the pattern matching in LoadFile and SaveFile requesters.
  1185. Valid requesters are:
  1186. 0 - EZLoadFile
  1187. 1 - EZSaveFile
  1188. 3 - EZMultiLoadFile
  1189.  
  1190.  
  1191. Statement: RTEZFreePattern
  1192. --------------------------------------------------------------------------
  1193. Syntax   : RTEZFreePattern Requester#
  1194.  
  1195. Description:
  1196. Turns off pattern matching in the requester.  Valid requester numbers are:
  1197.  
  1198. 0 - EZLoadFile
  1199. 1 - EZSaveFile
  1200. 3 - EZMultiLoadFile
  1201.  
  1202.  
  1203. Function: RTEZGetLong
  1204. --------------------------------------------------------------------------
  1205. Syntax  : result.l=RTEZGetLong(Title$,BodyText$ [,DefaultValue])
  1206.  
  1207. Description:
  1208. This prompts the user for a number.  BodyText$ can be formatted with
  1209. chr$(10) if needed.  DefaultValue can be supplied to suggest a value to 
  1210. the user.
  1211.  
  1212.  
  1213. Function: RTEZGetLongRange
  1214. --------------------------------------------------------------------------
  1215. Syntax  : result.l=RTEZGetLongRange(Title$,BodyText$,Min.l,Max.l 
  1216.                    [,DefaultValue])
  1217.  
  1218. Description:
  1219. Like RTEZGetLong, but this imposes an inclusive minimum and maximum on the
  1220. number entered.  Again, DefaultValue can be used to suggest a value to the
  1221. user.
  1222.  
  1223.  
  1224. Function: RTEZGetString
  1225. --------------------------------------------------------------------------
  1226. Syntax  : returned$=RTEZGetString(Title$,BodyText$,MaxChars 
  1227.           [,DefaultString])
  1228.  
  1229. Description:
  1230. Prompts the user to enter a string (which can be up to MaxChars in length).
  1231. As usual, you can format the BodyText$ with chr$(10) and supply a default
  1232. string.  If you do supply one, then make sure that the length of the string
  1233. is less than MaxChars, otherwise you could corrupt innocent memory.
  1234.  
  1235.  
  1236. Function: RTLockWindow
  1237. --------------------------------------------------------------------------
  1238. Syntax  : WinLock=RTLockWindow(Window#)
  1239.  
  1240. Description:
  1241. This locks the numbered window, blocks all input to that window except
  1242. depth arranging (and the Zip gadget, under 2.0), and put up the standard
  1243. wait pointer.  If you have some utility to make the hands spin or something
  1244. like that, then that happens as well.  WinLock must be saved!
  1245.  
  1246.  
  1247. Statement: RTUnlockWindow
  1248. --------------------------------------------------------------------------
  1249. Syntax   : RTUnlockWindow Window#,WinLock
  1250.  
  1251. Description:
  1252. Unlocks the window that you locked with RTLockWindow.
  1253.  
  1254.  
  1255. Functions: RTVersion and RTRevision
  1256. --------------------------------------------------------------------------
  1257. Syntax   : ver=RTVersion and ver=RTRevision
  1258.  
  1259. Description:
  1260. Both these functions return the version number and revision number of the
  1261. ReqTools library that this code interfaces to.
  1262.  
  1263. Of no real use at the moment, but future developments in ReqTools may
  1264. require a minimum library version to work.  ReqToolsLib will always open
  1265. whatever ReqTools are available.
  1266.  
  1267.  
  1268. Function: IsReqToolsActive
  1269. --------------------------------------------------------------------------
  1270. Syntax  : result=IsReqToolsActive
  1271.  
  1272. Description:
  1273. Returns True if ReqTools was able to initialise, and False if it wasn't (eg
  1274. not available).
  1275.  
  1276.  
  1277. Function: RTASyncRequest
  1278. --------------------------------------------------------------------------
  1279. Syntax  : ret.l=RTASyncRequest(Title$,BodyText$,GadgetText$)
  1280.  
  1281. Description:
  1282. This function puts up a request, locks the window and returns immediately.
  1283. If the requester couldn't be put up, ret is False.  The program is now free
  1284. to continue, but the user can have the option of aborting a lengthy
  1285. operation if required.
  1286.  
  1287. Important Note: Do not attempt to have two asyncronous requesters up.
  1288.  
  1289. Note: As of V1.41b, RTASyncRequest uses the current window for the
  1290. requester.
  1291.  
  1292.  
  1293. Function: RTCheckASyncRequest
  1294. --------------------------------------------------------------------------
  1295. Syntax  : ret.l=RTCheckASyncRequest
  1296.  
  1297. Description:
  1298. Checks the status of the asyncronous requester, and returns True if it is
  1299. still up.
  1300.  
  1301.  
  1302. Statement: RTEndASyncRequest
  1303. --------------------------------------------------------------------------
  1304. Syntax   : RTEndASyncRequest
  1305.  
  1306. Description:
  1307. Ends the asyncronous request, under program control, and unlocks the
  1308. calling window.
  1309.  
  1310. NOTE:  Do not call this finction if the user has hit the gadget in the
  1311. request!  The requester automatically frees its self.
  1312.  
  1313.  
  1314. These three commands require a demonstration to illustrate:
  1315.  
  1316. NoCli:WBStartup
  1317. WbToScreen 0
  1318. Window 0,10,10,100,100,$8|$1000|2|4,"RTTest window",2,1
  1319. CatchDosErrs
  1320. ret.l=RTASyncRequest("Hi There!","Please Wait...","Cancel")
  1321.  
  1322. If ret  ;The requester opened OK
  1323.   For x.w=10 To 1 Step -1
  1324.     WLocate 0,10
  1325.     NPrint "Seconds:",x
  1326.     VWait(50)
  1327.     ret1.l=RTCheckASyncRequest ;Is the requester still up?
  1328.     If NOT ret1 ;No, so end this processing
  1329.       Pop If:Pop For:Pop If
  1330.       Goto cancelled
  1331.     EndIf
  1332.   Next x
  1333.   RTEndASyncRequest ;Normal finish
  1334. EndIf
  1335. End
  1336.  
  1337. cancelled:
  1338. a.l=RTEZRequest("Oi!","You cancelled!?!","Sure Did")
  1339. End
  1340.  
  1341.  
  1342. Function: RTASyncPaletteRequest
  1343. --------------------------------------------------------------------------
  1344. Syntax  : ret.l=RTASyncPaletteRequest(Title$,FirstColour)
  1345.  
  1346. Description:
  1347. Similar to RTEZPaletteRequest, this command puts up a palette requester and
  1348. returns immediatly.  Note, however, that the calling window is NOT locked,
  1349. unlike all other ReqTools requesters.  This allows you to launch a seperate
  1350. palette requester and continue processing.
  1351.  
  1352.  
  1353. Function: RTCheckASyncPaletteRequest
  1354. --------------------------------------------------------------------------
  1355. Syntax  : ret.l=RTCheckASyncPaletteRequest
  1356.  
  1357. Description:
  1358. Returns True if the requester is still up, False if the user hit Ok or
  1359. Cancel.  NOTE: There is no way to detect exactly how the user exited the
  1360. command.
  1361.  
  1362.  
  1363. Statement: RTEndASyncPaletteRequest
  1364. --------------------------------------------------------------------------
  1365. Syntax   : RTEndASyncPaletteRequest
  1366.  
  1367. Description:
  1368. Closes the requester.
  1369.  
  1370. A short demonstration program to illustrate:
  1371.  
  1372. WbToScreen 0
  1373. Window 0,0,0,200,100,$40,"Hi there",2,1
  1374. CatchDosErrs
  1375.  
  1376. ret.l=RTASyncPaletteRequest("Play with these",1)
  1377.  
  1378. count.l=0
  1379. If ret
  1380.   While count<100
  1381.     count+1
  1382.     WLocate 0,0
  1383.     NPrint "Seconds:",count
  1384.     If NOT RTCheckASyncPaletteRequest Then Goto quit
  1385.     Delay_ 60
  1386.   Wend
  1387.   RTEndASyncPaletteRequest
  1388. EndIf
  1389.  
  1390. quit:
  1391. Free Window 0
  1392.  
  1393.  
  1394. Function: RTRequest
  1395. --------------------------------------------------------------------------
  1396. Syntax  : ret=RTRequest(BodyText$,GadgetText$,TagList)
  1397.  
  1398. Description:
  1399. This is the standard form of the ReqTools Requester.  You must supply the
  1400. tag list to control the requester.  The requester title, if not specified
  1401. in the tag list, will be "Information" if you have only one response
  1402. gadget, or "Request" if you have two or more responses.
  1403.  
  1404. If you don't supply a tag list, ReqTools will use its own defaults.
  1405.  
  1406. It is *your* responsibility to ensure the TagList is correctly set up.
  1407.  
  1408. Most of the tags of interest are included in RTEZRequest and
  1409. RTEZFlagsRequest as standard.
  1410.  
  1411. Acceptable tags are:
  1412.    #RT_Window       - *name.Window
  1413.                       Window that will be used to find the screen to put 
  1414.                       the requester on.
  1415.                       You *MUST* supply this if you are a task calling 
  1416.                       this function and not a process! This is because 
  1417.                       tasks don't have a pr_WindowPtr.
  1418.    #RT_IDCMPFlags   - (LONG)
  1419.                       Extra idcmp flags to return on.  If one these IDCMP
  1420.                       flags causes the requester to abort the return code
  1421.                       will equal the flag in question.
  1422.    #RT_ReqPos       - (LONG)
  1423.                       One of the following:
  1424.                       #REQPOS_POINTER    - requester appears where the 
  1425.                                            mouse pointer is (default).
  1426.                       #REQPOS_CENTERSCR  - requester is centered on the
  1427.                                            screen.
  1428.                       #REQPOS_CENTERWIN  - requester is centered in the
  1429.                                            window (only works if the
  1430.                                            pr_WindowPtr of your process is
  1431.                                            valid or if you use RT_Window).
  1432.                                            If RT_Window is NULL the
  1433.                                            requester will be centered on
  1434.                                            the screen.
  1435.                       #REQPOS_TOPLEFTSCR - requester appears at the top 
  1436.                                            left of the screen.
  1437.                       #REQPOS_TOPLEFTWIN - requester appears at the top 
  1438.                                            left of the window (only works
  1439.                                            if the pr_WindowPtr of your 
  1440.                                            process is valid or if you use 
  1441.                                            RT_Window).
  1442.                       The requester will always remain in the visible part
  1443.                       of the screen, so if you use the Workbench 2.0 
  1444.                       ScreenMode preferences editor to enlarge your 
  1445.                       Workbench screen and you scroll around, the 
  1446.                       requester will always appear in the part you can see.
  1447.                       REQPOS_CENTERSCR and REQPOS_TOPLEFTSCR also apply to
  1448.                       the visible part of the screen. So if you use one of
  1449.                       these the requester will be appear in the center or 
  1450.                       the top left off what you can see of the screen as 
  1451.                       opposed to the entire screen.
  1452.                       REQPOS_CENTERWIN and REQPOS_TOPLEFTWIN fall back to
  1453.                       REQPOS_CENTERSCR or REQPOS_TOPLEFTSCR respectively
  1454.                       when there is no parent window.  So you can safely 
  1455.                       use these without worrying about the existence of a 
  1456.                       window.
  1457.    #RT_LeftOffset   - (LONG)
  1458.                       Offset of left edge of requester relative to 
  1459.                       position specified with RT_ReqPos (does not offset 
  1460.                       the requester when RT_ReqPos is REQPOS_POINTER).
  1461.    #RT_TopOffset    - (LONG)
  1462.                       Offset of top edge of requester relative to position
  1463.                       specified with RT_ReqPos (does not offset the 
  1464.                       requester when RT_ReqPos is REQPOS_POINTER).
  1465.    #RT_PubScrName   - (*string)
  1466.                       Name of public screen requester should appear on. 
  1467.                       When this tag is used the RT_Window tag will be  
  1468.                       ignored.
  1469.                       If the public screen is not found the requester will
  1470.                       open on the default public screen.
  1471.                       Only works on Kickstart 2.0!  reqtools.library does
  1472.                       not check this, it is up to you *NOT* to use this 
  1473.                       tag on Kickstart 1.3 or below!
  1474.                       Note that the 1.3 version of reqtools.library also
  1475.                       understands and supports this tag (on 2.0).
  1476.    #RT_Screen       - (*name.Screen)
  1477.                       Address of screen to put requester on.  You should
  1478.                       never use this, use RT_Window or RT_PubScrName.
  1479.    #RT_ReqHandler   - (struct rtHandlerInfo **)
  1480.                       Using this tag you can start an "asynchronous"
  1481.                       requester. ti_TagData of the tag must hold the 
  1482.                       address of a pointer variable to a rtHandlerInfo 
  1483.                       structure.
  1484.                       The requester will initialize this pointer and will
  1485.                       return immediately after its normal initialization.
  1486.                       The return code will not be what you would normally
  1487.                       expect.  If the return code is _not_ equal to
  1488.                       CALL_HANDLER an error occurred and you should take
  1489.                       appropriate steps. If the return code was 
  1490.                       CALL_HANDLER everything went ok and the requester 
  1491.                       will still be up!
  1492.                       See the explanation for rtReqHandlerA() below for  
  1493.                       the following steps you have to take.
  1494.    #RT_WaitPointer  - (BOOL)
  1495.                       If this is TRUE the window calling the requester 
  1496.                       will get a standard wait pointer set while the 
  1497.                       requester is up. This will happen if you used the 
  1498.                       RT_Window tag or if your process's pr_WindowPtr is 
  1499.                       valid.  Note that after the requester has finished 
  1500.                       your window will be ClearPointer()-ed.  If you used
  1501.                       a custom pointer in your window you will have to 
  1502.                       re-set it, or not use the RT_WaitPointer tag and put
  1503.                       up a wait pointer yourself.
  1504.                       If your program requires ReqTools V38 it is advised 
  1505.                       you use RT_LockWindow instead.  Defaults to FALSE.
  1506.    #RT_LockWindow   - (BOOL) [V38]
  1507.                       If this is TRUE the window calling the requester 
  1508.                       will get locked.  It will no longer accept any user 
  1509.                       input and it will get standard wait pointer set.  
  1510.                       This will happen only if you used the RT_Window tag 
  1511.                       or if your process's pr_WindowPtr is valid.  
  1512.                       RT_LockWindow will restore a custom pointer if you 
  1513.                       have used one (unlike RT_WaitPointer).  So you do 
  1514.                       not have to worry about having to restore it  
  1515.                       yourself.  It is advised you use this tag as much as
  1516.                       possible. Defaults to FALSE.
  1517.    #RT_ScreenToFront - (BOOL) [V38]
  1518.                       Boolean indicating whether to pop the screen the
  1519.                       requester will appear on to the front. Default is 
  1520.                       TRUE.
  1521.    #RT_ShareIDCMP   - (BOOL) [V38]
  1522.                       Boolean indicating whether to share the IDCMP port 
  1523.                       of the parent window. Use this tag together with the
  1524.                       RT_Window tag to indicate the window to share IDCMP
  1525.                       with. Sharing the IDCMP port produces less overhead,
  1526.                       so it is advised you use this tag. Defaults to 
  1527.                       FALSE.
  1528.    #RT_Locale       - (struct Locale *) [V38]
  1529.                       Locale to determine what language to use for the
  1530.                       requester text.  If this tag is not used or its data
  1531.                       is NULL, the system's current default locale will be
  1532.                       used. Default NULL.
  1533.    #RT_IntuiMsgFunc - (struct Hook *) [V38]
  1534.                       The requester will call this hook for each IDCMP
  1535.                       message it gets that doesn't belong to its window.
  1536.                       Only applies if you used the RT_ShareIDCMP tag to 
  1537.                       share the IDCMP port with the parent window.  
  1538.                       Parameters are as follows:
  1539.                         A0 - (struct Hook *) your hook
  1540.                         A2 - (struct rtReqInfo *) your requester info
  1541.                         A1 - (struct IntuiMessage *) the message
  1542.                       After you have finished examining the message and 
  1543.                       your hook returns, ReqTools will reply the message.  
  1544.                       So do not reply the message yourself!
  1545.    #RT_Underscore   - (char) [V38]
  1546.                       Indicates the symbol that precedes the character in
  1547.                       the gadget label to be underscored.  This is to 
  1548.                       define a keyboard shortcut for this gadget.  
  1549.                       Example: to define the key 'Q' as a keyboard 
  1550.                       shortcut for "Quit" and 'N' for "Oh, No!" you would 
  1551.                       use the tag RT_Underscore, '_' and pass as gadfmt 
  1552.                       "_Quit|Oh, _No!".  Do not use the symbol '%' as it 
  1553.                       is used for string formatting.  The
  1554.                       usual character to use is '_' like in the example.
  1555.                       IMPORTANT: the shortcuts defined using RT_Underscore
  1556.                       take precedence of the default shortcuts!  It is for
  1557.                       example not wise to use a 'N' for a positive 
  1558.                       response! Pick your shortcuts carefully!
  1559.    #RT_TextAttr     - (struct TextAttr *) [V38]
  1560.                       Use this font for the requester.  Default is to use
  1561.                       the screen font.  Note that the font must already be
  1562.                       opened by you.  ReqTools will call OpenFont() on 
  1563.                       this TextAttr, _not_ OpenDiskFont()!  If the font 
  1564.                       cannot be opened using OpenFont() the default screen
  1565.                       font will be used.
  1566.    #RTEZ_ReqTitle   - (char *)
  1567.                       Title of requester window, default is "Request" 
  1568.                       unless the requester has less than 2 responses, then
  1569.                       the default title is "Information".
  1570.    #RTEZ_Flags      - (ULONG)
  1571.                       Flags for rtEZRequestA():
  1572.                       #EZREQF_NORETURNKEY - turn off the RETURN key as
  1573.                                             shortcut for positive response.
  1574.                       #EZREQF_LAMIGAQUAL  - keyboard shortcuts are limited
  1575.                                             to Left Amiga 'V' and 'B', ESC
  1576.                                             and RETURN.
  1577.                       #EZREQF_CENTERTEXT  - centers each line of body text
  1578.                                             in the requester window. Useful
  1579.                                             for about requesters.
  1580.    #RTEZ_DefaultResponse - (ULONG)
  1581.                       Response value that will be returned when the user
  1582.                       presses the return key.  Will be ignored if the
  1583.                       EZREQF_NORETURNKEY flag is set.  The text for this
  1584.                       response will be printed in bold. Default is 1.
  1585.  
  1586.  
  1587.  
  1588. Function: RTFileRequest
  1589. --------------------------------------------------------------------------
  1590. Syntax  : name$=RTFileRequest(Title$,FileName$,TagList)
  1591.  
  1592. Description:
  1593. This is the standard ReqTools requester, and is seperate from the 
  1594. LoadFile, SaveFile and PathRequest requesters.  No setup is done, but the 
  1595. file name etc is returned as per the above requesters.
  1596.  
  1597. Most of the tags that you would set normally are included as standard in
  1598. the RTREZxFile requesters.
  1599.  
  1600. It is *your* responsibility to ensure that the TagList is correctly set 
  1601. up.
  1602.  
  1603. Acceptable tags are:
  1604.  
  1605.    #RT_Window          - see rtEZRequestA()
  1606.    #RT_ReqPos          - see rtEZRequestA()
  1607.    #RT_LeftOffset      - see rtEZRequestA()
  1608.    #RT_TopOffset       - see rtEZRequestA()
  1609.    #RT_PubScrName      - see rtEZRequestA()
  1610.    #RT_Screen          - see rtEZRequestA()
  1611.    #RT_ReqHandler      - see rtEZRequestA()
  1612.    #RT_WaitPointer     - see rtEZRequestA()
  1613.    #RT_LockWindow      - [V38] see rtEZRequestA()
  1614.    #RT_ScreenToFront   - [V38] see rtEZRequestA()
  1615.    #RT_ShareIDCMP      - [V38] see rtEZRequestA()
  1616.    #RT_Locale          - [V38] see rtEZRequestA()
  1617.    #RT_IntuiMsgFunc    - (struct Hook *) [V38]
  1618.                          The requester will call this hook for each IDCMP
  1619.                          message it gets that doesn't belong to its window.
  1620.                          Only applies if you used the RT_ShareIDCMP tag to
  1621.                          share the IDCMP port with the parent window.
  1622.                          Parameters are as follows:
  1623.                            A0 - (struct Hook *) your hook
  1624.                            A2 - (struct rtFileRequester *) your requester
  1625.                            A1 - (struct IntuiMessage *) the message
  1626.                          After you have finished examining the message and
  1627.                          your hook returns, ReqTools will reply the 
  1628.                          message. So do not reply the message yourself!
  1629.    #RT_Underscore      - (char) [V38]
  1630.                          Indicates the symbol that precedes the character
  1631.                          in a gadget's label to be underscored.  This will
  1632.                          also define the keyboard shortcut for this gadget.
  1633.                          Currently only needed for RTFI_OkText.  Usually 
  1634.                          set to '_'.
  1635.    #RT_DefaultFont     - (struct TextFont *)
  1636.                          This tag allows you to specify the font to be 
  1637.                          used in the requester when the screen font is
  1638.                          proportional. Default is GfxBase->DefaultFont.
  1639.    #RT_TextAttr        - (struct TextAttr *) [V38]
  1640.                          Use this font for the requester.  Must be a fixed
  1641.                          width font, _not_ a proportional one.  Default is 
  1642.                          to use the screen font or the default font (if 
  1643.                          the screen font is proportional).  Note that the 
  1644.                          font must already be opened by you.  ReqTools 
  1645.                          will call OpenFont() on this TextAttr, _not_ 
  1646.                          OpenDiskFont()!
  1647.                          If the font cannot be opened using OpenFont() or 
  1648.                          if the font is proportional the default screen 
  1649.                          font will be used (or the font set with 
  1650.                          RT_DefaultFont).
  1651.    #RTFI_Flags         - (ULONG)
  1652.                          Several flags:
  1653.                          #FREQF_NOBUFFER    - do _not_ use a buffer to
  1654.                                               remember directory contents
  1655.                                               for the next time the file
  1656.                                               requester is used.
  1657.                          #FREQF_MULTISELECT - allow multiple files to be
  1658.                                               selected. rtFileRequest() 
  1659.                                               will return a pointer to an
  1660.                                               rtFileList structure which
  1661.                                               will contain all selected
  1662.                                               files.  Use rtFreeFileList()
  1663.                                               to free the memory used by
  1664.                                               this file list.
  1665.                          #FREQF_SELECTDIRS  - set this flag if you wish to
  1666.                                               enable the selecting of dirs
  1667.                                               as well as files.  You *must*
  1668.                                               also set FREQF_MULTISELECT.
  1669.                                               Directories will be returned
  1670.                                               together with files in
  1671.                                               rtFileList, but with StrLen
  1672.                                               equal to -1.  If you need the
  1673.                                               length of the directory's 
  1674.                                               name use strlen().
  1675.                          #FREQF_SAVE        - Set this if you are using the
  1676.                                               requester to save or delete
  1677.                                               something.  Double-clicking
  1678.                                               will be disabled so it is
  1679.                                               harder to make a mistake and
  1680.                                               select the wrong file.  If 
  1681.                                               the user enters a non-
  1682.                                               existent directory in the 
  1683.                                               drawer string
  1684.                                               gadget, a requester will
  1685.                                               appear asking if the 
  1686.                                               directory should be created.
  1687.                          #FREQF_NOFILES     - Set this if you want to use
  1688.                                               the requester to allow the
  1689.                                               user to select a directory
  1690.                                               rather than a file.  Ideal 
  1691.                                               for getting a destination 
  1692.                                               dir. May be used with FREQF_
  1693.                                               MULTISELECT
  1694.                                               and FREQF_SELECTDIRS.
  1695.                          #FREQF_PATGAD      - When this is set a pattern
  1696.                                               gadget will be added to the
  1697.                                               requester.
  1698.    #RTFI_Height        - (ULONG)
  1699.                          Suggested height of file requester window.
  1700.    #RTFI_OkText        - (char *)
  1701.                          Replacement text for "Ok" gadget, max 6 chars  
  1702.                          long.
  1703.    #RTFI_VolumeRequest - (ULONG) [V38]
  1704.                          The presence of this tag turns the file requester
  1705.                          into a volume/assign disk requester.  This 
  1706.                          requester can be used to get a device name 
  1707.                          ("DF0:", "DH1:",..) or an assign ("C:", "FONTS:",
  1708.                          ...) from the user.
  1709.                          The result of this requester can be found in the
  1710.                          filereq->Dir field.  The volume can also be 
  1711.                          changed with rtChangeReqAttrA() and the RTFI_Dir 
  1712.                          tag.  
  1713.                          Note:
  1714.                          that the user may edit the disk/assign names, or
  1715.                          enter a new one.  Note also that the real device
  1716.                          name is returned, not the name of the volume in 
  1717.                          the device.  For example "DH1:", not "Hard1:".
  1718.                          The tag data (ULONG) is used to set following 
  1719.                          flags:
  1720.                          #VREQF_NOASSIGNS - Do not include the assigns in
  1721.                                             the list, only the real 
  1722.                                             devices.
  1723.                          #VREQF_NODISKS   - Do not include devices, just
  1724.                                             show the assigns.
  1725.                          #VREQF_ALLDISKS  - Show _all_ devices.  Default
  1726.                                             behavior is to show only those
  1727.                                             devices which have valid disks
  1728.                                             inserted into them.  So if you
  1729.                                             have no disk in drive DF0: it
  1730.                                             will not show up.  Set this 
  1731.                                             flag if you do want these 
  1732.                                             devices included.
  1733.                         NOTE: Do *NOT* use { RTFI_VolumeRequest, TRUE }!
  1734.                               You are then setting the VREQF_NOASSIGNS  
  1735.                               flag! Use { RTFI_VolumeRequest, 0 } for a 
  1736.                               normal volume requester.
  1737.                         NOTE: If you use the RTFI_FilterFunc described
  1738.                               below the third parameter will be a pointer
  1739.                               to a rtVolumeEntry structure rather than a
  1740.                               pointer to a FileInfoBlock structure!
  1741.                               Tech note: the DOS device list has been
  1742.                               unlocked, so it is safe to e.g. Lock() this
  1743.                               device and call Info() on this lock.
  1744.                         NOTE: A file requester structure allocated with
  1745.                               rtAllocRequest() should not be used for both
  1746.                               a file and a volume requester. Allocate two
  1747.                               requester structures if you need both a file
  1748.                               and a volume requester in your program!
  1749.    #RTFI_FilterFunc    - (struct Hook *) [V38]
  1750.                          Call this hook for each file in the directory 
  1751.                          being read (or for each entry in the volume 
  1752.                          requester).
  1753.                          Parameters are as follows:
  1754.                            A0 - (struct Hook *) your hook
  1755.                            A2 - (struct rtFileRequester *) your filereq
  1756.                            A1 - (struct FileInfoBlock *) fib of file OR
  1757.                                 (struct rtVolumeEntry *) device or assign
  1758.                                 in case of a volume requester.
  1759.                          If your hook returns TRUE the file will be 
  1760.                          accepted. If it returns FALSE the file will be 
  1761.                          skipped and will not appear in the requester.
  1762.                          IMPORTANT NOTE: If you change your hook's 
  1763.                                          behavior you _MUST_ purge the 
  1764.                                          requester's buffer (using rtFree
  1765.                                          ReqBuffer())!
  1766.                          IMPORTANT NOTE: When this callback hook is called
  1767.                                          from a volume requester the
  1768.                                          pr_WindowPtr of your process will
  1769.                                          be set to -1 so *no* DOS 
  1770.                                          requesters will appear when an 
  1771.                                          error occurs!
  1772.    #RTFI_AllowEmpty    - (BOOL) [V38]
  1773.                          If RTFI_AllowEmpty is TRUE an empty file string 
  1774.                          will also be accepted and returned.  Defaults to 
  1775.                          FALSE, meaning that if the user enters no 
  1776.                          filename the requester will be canceled.  You 
  1777.                          should use this tag as little as possible!
  1778.  
  1779.  
  1780.  
  1781. Library Name: fuzziesreqlib #53
  1782.  
  1783. Author: Peter Tavinor, 22 Tuhangi St, Kamo, Whangarei, New Zealand
  1784.  
  1785. Commands:
  1786.  
  1787.  COLOURREQUEST   
  1788.  CON_BASE        
  1789.  DOS_BASE        
  1790.  FILEFILTER      
  1791.  FILEREQSIZE     
  1792.  FILESTRUCTURE   
  1793.  GETSTRING$      
  1794.  GFX_BASE        
  1795.  INT_BASE        
  1796.  MAXSELECT$      
  1797.  NEXTFILE$       
  1798.  REQCOLOURS      
  1799.  REQFILEREQUEST$ 
  1800.  REQFONTSIZE     
  1801.  REQ_BASE        
  1802.  REX_BASE        
  1803.  TEXTREQUEST     
  1804.  TEXTTIMEOUT     
  1805.  
  1806. OverView:
  1807.   Not only has Peter Tavinor (King Fuzzy) kindly fixed up and added
  1808.   stuff to our own libraries (seriallib especially) he has also sent
  1809.   us this library which is one of three that take advantage of the
  1810.   ReqLibrary.
  1811.   Fuzzy has also cludged up Ted with hotkeys and stuff, if you
  1812.   want to get hold of this version I suggest writing to him
  1813.   at the above address. Anyway, sorry I couldn't fit more of
  1814.   his stuff in this issue.
  1815.  
  1816. Authors Docs:
  1817.  
  1818.  Req   Library  Ver 1.1 By King Fuzzy  No. 201
  1819.  
  1820.  $VER: Req Library extention Docs version 1.1 by King Fuzzy
  1821.  
  1822. The following commands are in the Reqlib library and they require the req.library
  1823. To get the Requests on a custom window use CatchDosErrs (see Reference Manual)
  1824.  
  1825.  
  1826. Function: ColourRequest
  1827. --------------------------------------------------------------------------
  1828. Syntax  : Colour=ColourRequest(Colour)
  1829.  
  1830. Description:
  1831. This function brings up a handy little palette and allows the user to 
  1832. select a colour using Colour as the default.
  1833.  
  1834. Example:
  1835.   c=ColourRequest(1)
  1836.  
  1837.  
  1838. Function: Con_Base
  1839. --------------------------------------------------------------------------
  1840. Syntax  : cl.l=Con_Base
  1841.  
  1842. This Returns pointer to Console.device. Used for jsr calls mainly rawkey 
  1843. to cookedkey 
  1844.  
  1845.  
  1846. Function: Dos_Base
  1847. --------------------------------------------------------------------------
  1848. Syntax  : dl.l=Dos_Base
  1849.  
  1850. This Returns pointer to Dos.Library used in jsr calls
  1851.  
  1852.  
  1853. Statement: FileFilter
  1854. --------------------------------------------------------------------------
  1855. Syntax   : FileFilter Show$,Hide$
  1856.  
  1857. This sets the Hide and Show filters in the req file requester
  1858.  
  1859. FileFilter "Req.*","*.Bak"
  1860.  
  1861. This will show all files starting with 'Req.' but not ones ending with 
  1862. '.Bak'
  1863.  
  1864.  
  1865. Statement: FileReqSize
  1866. --------------------------------------------------------------------------
  1867. Syntax   : FileReqSize Lines High,File Length,Device Length
  1868.  
  1869. Description:
  1870. This sets the size of the Req File Requester. The defaults are 8,16,10
  1871.  
  1872. FileReqSize 20,25,12
  1873.  
  1874.  
  1875. Function: FileStructure
  1876. --------------------------------------------------------------------------
  1877. Syntax  : Fs.l=FileStructure
  1878.  
  1879. Description:
  1880. Returns a pointer to the req file requester structure
  1881.  
  1882.  
  1883. Function: GetString$
  1884. --------------------------------------------------------------------------
  1885. Syntax  : String$=GetString$(Title$,Default$,Visable size,Max length)
  1886.  
  1887. Description:
  1888. This brings up a string requester allowing the user to enter a string
  1889. The maximum length and the visable length are set with Max length and 
  1890. Visable size The default string must have a maximum length of at least 
  1891. Max length Returns a null string if cancel is selected
  1892.  
  1893. MaxLen d$=40
  1894. s$=GetString$("Type something",d$,30,40)
  1895.  
  1896.  
  1897. Function: Gfx_Base
  1898. --------------------------------------------------------------------------
  1899. Syntax  : gl.l=Gfx_Base
  1900.  
  1901. Description:
  1902. This Returns pointer to Graphics.Library used in jsr calls
  1903.  
  1904.  
  1905. Function: Int_Base
  1906. ----------------------------------------------------------------------------
  1907. Syntax  : il.l=Int_Base
  1908.  
  1909. Description:
  1910. This Returns pointer to Intuition.Library used in jsr calls
  1911.  
  1912.  
  1913. Statement: MaxSelect$
  1914. --------------------------------------------------------------------------
  1915. Syntax   : Path$=MaxSelect$(Title$,File$,Path$,Flags,number of files)
  1916.                            
  1917. Select the number of files that can be selected with the extended selector
  1918. see ReqFile Requestor for more information
  1919.  
  1920.  
  1921. Function: NextFile$
  1922. --------------------------------------------------------------------------
  1923. Syntax  : f$=NextFile$
  1924.  
  1925. Description:         
  1926. Returns the next file in the extended file structure
  1927.  
  1928.  
  1929. Statement: ReqColours
  1930. --------------------------------------------------------------------------
  1931. Syntax   : ReqColours Text,Detail,Block[,File,Dir,Device[,GadText,GadBox,
  1932.                       StringName,StringBox,Frame]]
  1933.  
  1934. Description:
  1935. Text,Detail and Block are for both the req file requester and the text 
  1936. requester File,Dir,Device,GadText,GadBox,StringName,StringBox and Frame 
  1937. are only for the req file requester
  1938.  
  1939. Try changing the colours one at a time to see what they change
  1940.  
  1941. ReqColours 1,2,3
  1942. ReqColours 1,2,3,3,2,1
  1943. ReqColours 1,2,3,3,2,1,1,2,3,4,5
  1944.  
  1945.  
  1946. Function: ReqFileRequest$
  1947. --------------------------------------------------------------------------
  1948. Syntax:  selectedfile$=ReqFileRequest$(Title$,File$,Path$,Flags)
  1949.  
  1950. Yes it's another file/font requester, No it won't bring up the blitz 
  1951. requester if it fails the maximum length of File$ must be 32 and Path$ 
  1952. must be 132 The Flags are as follows (Clipped from reqbase.i)
  1953.  
  1954. FRQSHOWINFOB      EQU 0  =   1      ;Set this in Flags if you want .info files to show.  They default to hidden.
  1955. FRQEXTSELECTB     EQU 1  =   2      ;Set this in Flags if you want extended select.  Default is not.
  1956. FRQCACHINGB       EQU 2  =   4      ;Set this in Flags if you want directory caching.  Default is not.
  1957. FRQGETFONTSB      EQU 3  =   8      ;Set this in Flags if you want a font requester rather than a file requester.
  1958. FRQINFOGADGETB    EQU 4  =  16      ;Set this in Flags if you want a hide-info files gadget.
  1959. FRQHIDEWILDSB     EQU 5  =  32      ;Set this in Flags if you DON'T want 'show' and 'hide' string gadgets.
  1960. FRQABSOLUTEXYB    EQU 6  =  64      ;Use absolute x,y positions rather than centering on mouse.
  1961. FRQCACHEPURGEB    EQU 7  = 128      ;Purge the cache whenever the directory date stamp changes if this is set.
  1962. FRQNOHALFCACHEB   EQU 8  = 256      ;Don't cache a directory unless it is completely read in when this is set.
  1963. FRQNOSORTB        EQU 9  = 512      ;Set this in Flags if you DON'T want sorted directories.
  1964. FRQNODRAGB        EQU 10 =1024      ;Set this in Flags if you DON'T want a drag bar and depth gadgets.
  1965. FRQSAVINGB        EQU 11 =2048      ;Set this bit if you are selecting a file to save to.
  1966. FRQLOADINGB       EQU 12 =4096      ;Set this bit if you are selecting a file(s) to load from.
  1967.                                     ;These two bits (save and load) aren't currently used for
  1968.                                     ;anything, but they may be in the future, so you should
  1969.                                     ;remember to set them.  Also, these bits make it easier if
  1970.                                     ;somebody wants to customize the file requester for their
  1971.                                     ;machine.  They can make it behave differently for loading
  1972.                                     ;vs saving.
  1973. FRQDIRONLYB       EQU 13 =8192      ;Allow the user to select a directory, rather than a file.
  1974.  
  1975. Just add together what you want and use it. EG. 6 is Caching and extended 
  1976. select
  1977.  
  1978. Also see:  FILEREQSIZE   
  1979.            FILEFILTER    
  1980.            REQCOLOURS$   
  1981.            FILESTRUCTURE 
  1982.            MAXSELECT$    
  1983.            NEXTFILE$     
  1984.  
  1985. MaxLen fl$=32 : MaxLen dr$=132
  1986. f$=ReqFileRequest$("Select a file",fl$,dr$,4)
  1987.  
  1988. FRQEXTSELECTB is not used
  1989.  
  1990. Returns a null string if user aborts
  1991.  
  1992.  
  1993. Function: ReqFontSize
  1994. --------------------------------------------------------------------------
  1995. Syntax  : sz=ReqFontSize
  1996.  
  1997. This Returns the size of the last font selected with the font requester
  1998.  
  1999.  
  2000. Function: Req_Base
  2001. --------------------------------------------------------------------------
  2002. Syntax  : rl.l=Req_Base
  2003.  
  2004. This Returns pointer to Req.Library used in jsr calls
  2005.  
  2006.  
  2007. Function: Rex_Base
  2008. --------------------------------------------------------------------------
  2009. Syntax  : rxl.l=Rex_Base
  2010.  
  2011. This Returns pointer to RexxSys.Library I think, It says RexxSysBase in 
  2012. the req library docs
  2013.  
  2014.  
  2015. Function: TextRequest
  2016. --------------------------------------------------------------------------
  2017. Syntax  : Button=TextRequest(Text,Title,Left Text[,[Middle Text,]Right Text])
  2018.  
  2019. This brings up a text requester with Text as the message and Title in the 
  2020. titlebar It can have 1, 2 or 3 buttons to select from The requester's 
  2021. colours can be changed: See  REQCOLOURS 
  2022.  
  2023. Left button
  2024. Left and Right buttons
  2025. Left, Middle and Right buttons
  2026.  
  2027. The text in the buttons is determined by Left Text,Middle Text and Right 
  2028. Text
  2029.  
  2030. the value returned is
  2031. 1  left button
  2032. 2  middle button
  2033. 0  right button
  2034.  
  2035. Button=TextRequest("I am a simple requester","Blitz Prog","Left","Middle","Right")
  2036.  
  2037.  
  2038. Statement: TextTimeout
  2039. --------------------------------------------------------------------------
  2040. Syntax   : TextTimeout Timeout Seconds
  2041.  
  2042. Its surpose to set the timeout for the text requester but it don't work 
  2043. yet
  2044.  
  2045.  
  2046. Library Name: elmoreinclib #111
  2047. --------------------------------------------------------------------------
  2048. Author: Richard T Elmore, HeadSoft, 126 STATE ST. #20, 
  2049.         SPEARFISH, SD 57783, USA
  2050.  
  2051. OverView: 
  2052. This is a crippled version of a library which Richard has put a whole 
  2053. heap of time into. It basically allows you to include compressed object
  2054. data into your programs which you can unpack at your leisure. Please see 
  2055. the registration material at the bottom of this file if you like what 
  2056. you see. Demo, util and lh.library are in userlibprogs/elmore.
  2057.  
  2058. Commands:
  2059.  
  2060.  INCSOUND           INCNEXTSHAPE       FREEINCDATA  
  2061.  INCBITMAP          INCTEXT$           SAVEINCDATA  
  2062.  INCMOD             INCDATA      
  2063.  INCMED             INCSIZE      
  2064.  INCSHAPE           INCDATAABS     
  2065.  
  2066.  USING THE INCLUDE-UTIL PROGRAM 
  2067.  
  2068.                                  Author's Docs:
  2069.  
  2070.                             ABOUT INCLUDE.ELMORELIB
  2071.                            =========================
  2072.  
  2073.  
  2074. The Include library by Richard T. Elmore of HeadSoft Software enables
  2075. Blitz2 programmers to make stand-alone files that don't require special
  2076. directories, external IFF files, etc. to run.  To achieve this in the most
  2077. efficient manner possible, the incredible efficiency and speed of the
  2078. LH.Library is used (in the INCLUDE-UTIL tool, which is freely 
  2079. distributeable.)
  2080.  
  2081. At present, the Include library supports Bitmaps, (up to 8 bitplanes!)
  2082. sound effects, MED music modules, IFF brushes for Blitz2 SHAPES, Blitz2 
  2083. SHAPES-FILES for multiple shapes, (as created by the SAVESHAPES command
  2084. or with the SHAPESMAKER utility) entire ASCII text files, or raw binary 
  2085. data which gives the advanced programmer the ability to include other 
  2086. object types or other data such as executeable programs, variable arrays 
  2087. for cosine tables, etc.
  2088.  
  2089. The library was designed with Blitz2's INCBIN compiler directive, but may
  2090. also be used with data loaded with READMEM or similar commands, to 
  2091. conserve disk space when you don't mind having external files, not to 
  2092. mention they will be made next to impossible to "rip" by anyone without 
  2093. the Include Library!
  2094.  
  2095.  
  2096. NOTE:  Your executeables do NOT require the "lh.library" to run...  They
  2097. will have their own self-contained decrunching routine (which is much 
  2098. faster than the crunching routine in lh.library!)
  2099.  
  2100.  
  2101.                          USING THE INCLUDE-UTIL PROGRAM
  2102.                         ================================
  2103.  
  2104. In order to include the above-mentioned data in your Blitz2 executeables,
  2105. the original data files must be converted and packed so that the resulting
  2106. runtime program consumes the least memory possible.  This also allows the 
  2107. data to be stored in public or "fast" memory, not just CHIP ram. The 
  2108. INCLUDE-UTIL program is supplied with the library to convert the data for 
  2109. you.
  2110.  
  2111. First, ensure the "LH.Library" file resides in your LIBS: directory. The
  2112. INCLUDE-UTIL program will crash if it isn't availble.
  2113.  
  2114.  
  2115. In order to run the program, just click on it's icon, and a custom screen
  2116. will appear containing icons representing the types of data you wish to
  2117. convert to includeable data.  Note that the ST/NT Module button is 
  2118. ghosted, as this data type is not supported in the public domain release 
  2119. of the library.
  2120.  
  2121. You may note there is a gadget to "quit" even though there is also a 
  2122. "close" gadget in the top-left of the main window.  Clicking the close-
  2123. gadget will NOT quit the program, it will merely close the window and 
  2124. screen, then an icon will appear on the Workbench screen.  Simply click 
  2125. the icon to reactivate the program.  (While in this idle mode, INCLUDE-
  2126. UTIL uses no processor time and consumes less memory.)
  2127.  
  2128. Upon clicking one of the other icons, a file requester will appear 
  2129. prompting you to select a source file (the IFF, text, MOD, whatever) to 
  2130. convert. Note that you may load either IFF brushes *OR* BB2 shapes-files 
  2131. in the SHAPES filerequester, the appropriate INCLUDE-OBJECT type will be 
  2132. created.
  2133.  
  2134. After the file has been converted to it's INCLUDE-OBJECT form, you will be
  2135. given a filerequester to SAVE the object with.  Note that an INCLUDE-
  2136. OBJECT extension will be appended to the filename to help you more easily 
  2137. recognise the object types in a directory listing.  They are:
  2138.  
  2139.   .ISFX     - Sound effects
  2140.   .IBMP     - Bitmaps
  2141.   .ISHP     - Single shapes
  2142.   .ISHPS    - Multiple shapes
  2143.   .IMED     - MED modules
  2144.   .IBIN     - Either binary or text (IncText$, IncDataABS, IncData, etc.)
  2145.  
  2146.  
  2147. The INCLUDE-UTIL program accepts tooltypes for default paths. Then
  2148. whenever you click on an appropriate gadget the file requester will use
  2149. the path you prefer.  The following keywords identify the paths:
  2150.  
  2151. SOUNDS=pathname
  2152. BITMAPS=pathname
  2153. SHAPES=pathname
  2154. MODULES=pathname
  2155. BINARIES=pathname
  2156. SAVE=pathname     (This is the same path for saving all object types)
  2157.  
  2158.  
  2159. You should keep the name of this utility "INCLUDE-UTIL" or the tooltype 
  2160. preferences will not be available.
  2161.  
  2162.  
  2163. A few features are available under OS2.0 and above only:  Notably,
  2164. when you iconify INCLUDE-UTIL, it uses a real appicon, so you can drag
  2165. objects onto it to have them automatically identified and loaded.  You
  2166. can also simply double-click the icon without dragging anything if you
  2167. just want to wake the program up.
  2168.  
  2169. Now that you have your INCLUDE-OBJECTs, how do you go about making them
  2170. part of your Blitz2 executeables?  It is relatively simple, but you must 
  2171. be careful to follow these guidelines unless you know EXACTLY what you're 
  2172. doing or you'll crash your Amiga!
  2173.  
  2174.  
  2175. 1.  Place a copy of Include.ElmoreLib in your Blitzlibs:Userlibs 
  2176.     directory, then optionally create a new DEFLIBS file.
  2177.  
  2178. 2.  Write and debug your program using normal loading routines until 
  2179.     you're satisfied with it.  No need to use INCLUDE-OBJECTs during 
  2180.     debugging, as it will only slow down development.  (Before being made 
  2181.     executeable, Blitz2 will both load the objects from disk AND decrunch 
  2182.     them.)
  2183.  
  2184. 3.  Go to the end of your sourcecode (usually the safest place) and select
  2185.     a different program label for EACH INCLUDE-OBJECT to be decrunched at
  2186.     run-time.  Directly following the label, enter INCBIN "filename" which
  2187.     should reference the name you saved the INCLUDE-OBJECT as from 
  2188.     INCLUDE-UTIL. See page 8-3 of your Blitz2 reference manual for details 
  2189.     on INCBIN and INCDIR commands if you're not familiar with them.
  2190.  
  2191. 4.  Ensure you have an "END" statement or some such before your fist
  2192.     INCLUDE-OBJECT's label.  If program flow continues into the data, you 
  2193.     will almost surely have a crash.
  2194.  
  2195. 5.  Replace your Blitz2 DOS-based loading commands with the approriate
  2196.     Include library versions.  It's wise to check the results of those 
  2197.     commands that return "success" or "failure" (TRUE or FALSE) so that 
  2198.     your program can exit gracefully if there isn't enough memory, etc. 
  2199.     when its run.
  2200.  
  2201. 6.  That's all!  You should be able to run your program normally, and
  2202.     executeables you create will run fine with graphics, sounds, whatever
  2203.     you want, and *NO* external files needed!!  Of course since all the 
  2204.     data is included in the size of the executeable, it will be much 
  2205.     larger than usual. (Size of INCLUDE-OBJECTs+normal executeable size)
  2206.     You may have some success crunching the entire executeable with 
  2207.     PowerPacker or similar programs, but if the percentage of 
  2208.     INCLUDE-OBJECT data in the executeable is very high, most crunchers 
  2209.     will choke on it, since most of the program is already crunched
  2210.     by INCLUDE-UTIL.
  2211.  
  2212.  
  2213. Function/Statement: Incsound
  2214. --------------------------------------------------------------------------
  2215. Syntax: success=IncSound(Sound#, ?Label)
  2216.         IncSound Sound#, ?Label
  2217.  
  2218. Description:
  2219. Ensure you put the question mark before the label name or you'll have
  2220. errors!  The actual include-object should be INCBINed directly after the
  2221. label, and be careful to put an END statement somewhere above your INCBIN
  2222. data or you'll crash!
  2223.  
  2224. Example:
  2225.  
  2226. If IncSound(0,?Mysound)=False Then End  ;Unpack the sound or end!
  2227.  
  2228. Sound 0,15  ;Play it back!
  2229. Mousewait   ;pause for the user....
  2230. End
  2231.  
  2232. Mysound:
  2233. IncBin "RAM:SoundEffect.isfx"
  2234.  
  2235. NOTE:  In the above example the FUNCTION version was used so you could
  2236. test it with an IF/THEN statement to see if it was successful...  If
  2237. you don't think you'll need to be so careful, the STATEMENT version would
  2238. be:
  2239.  
  2240. Example:
  2241.  
  2242. IncSound 0,?Mysound  ;Unpack the sound (Note no parentheses for 
  2243.                                        statement!)
  2244. Sound 0,15  ;Play it back!
  2245. Mousewait   ;pause for the user....
  2246. End
  2247.  
  2248.  
  2249. Function/Statement: IncBitmap
  2250. --------------------------------------------------------------------------
  2251. Syntax: success=IncBitmap(bitmap#,?Label)
  2252.         IncBitmap bitmap#,?Label
  2253.  
  2254. Description:
  2255. Nearly identical in useage to IncSound (above) Note that if the bitmap 
  2256. already exists, it should be the same dimensions such as 640x256x4 or 
  2257. IncBitmap will return FALSE (for failure) if you don't know for sure, you
  2258. can let IncBitmap create the bitmap exactly like it was Included by doing 
  2259. FREE BITMAP 0 or some such before you INCBITMAP it.
  2260.  
  2261. Example:
  2262.  
  2263. Blitz
  2264. If IncBitmap(0,?Mypicture)=0 Then End
  2265. Slice 0,32,4
  2266. Show 0
  2267. Mousewait:end
  2268.  
  2269. Mypicture:
  2270. IncBin "RAM:Picture.ibmp"
  2271.  
  2272.  
  2273. Function/Statement: IncMod
  2274. --------------------------------------------------------------------------
  2275. Syntax: success=IncMod(ST-NT Module#,?Label)
  2276.         IncMod Module#,?Label
  2277.  
  2278. Description:
  2279. Like the above examples, only for music mods. You could then use 
  2280. StartModule etc. just as if you had loaded it from disk.
  2281.  
  2282. ----------- NOTE: This function is a bit buggy, so it has
  2283.             been temporarily disabled with this release of
  2284.             the library!  (Sorry!) --------------------------------
  2285.  
  2286.  
  2287. Function/Statement: IncMed
  2288. --------------------------------------------------------------------------
  2289. Syntax: success=IncMed(MEDModule#,?Label)
  2290.         IncMed MedModule#,?Label
  2291.  
  2292. Description:
  2293. For including MED modules.  Usage is otherwise the same as IncMod.
  2294.  
  2295.  
  2296. Function/Statement: IncShape
  2297. --------------------------------------------------------------------------
  2298. Syntax: success=IncShape(Shape#,?Label[,Cookiecut?])
  2299.                 IncShape Shape#,?Label[,Cookiecut?]
  2300.                                           ^^^^
  2301.                                    OPTIONAL DUMMY VALUE
  2302.  
  2303. Description:
  2304. The one you've been waiting for!  Will retrieve the shape# for BLITTING...
  2305. Along with the command below, IncNextShape, you can even include several
  2306. shapes in one step!  I will be adding multiple shapes as an option in the
  2307. INCLUDE-UTIL program as well... For now, just INCBIN as many shapes as you
  2308. want (only need label for the first one)
  2309.  
  2310. Note: If you don't need a cookiecut for the shape, you can leave out the
  2311. CookieCut parameter.  Any number placed in the cookiecut parameter will
  2312. cause a cookiecut to be made for the shape when it is made however.  If
  2313. you plan to do BLITs etc. you should always use the cookiecut.
  2314.  
  2315.  
  2316. Function: IncNextShape
  2317. --------------------------------------------------------------------------
  2318. Syntax  : success=IncNextShape [CookieCut?]
  2319.                                ^^^^^^^^^^^^
  2320.                           OPTIONAL DUMMY VALUE
  2321.  
  2322. Example:
  2323.  
  2324. ;Include shape #0
  2325.  IncShape(0,?Shapes,1)
  2326. ;Will loop 3 times from shape #1 to #3 in this case
  2327. While IncNextShape(1):Wend
  2328. ;(Do your blitting stuff etc. here)
  2329. End
  2330.  
  2331. Shapes:
  2332. IncBin "Shape0.ISHP"
  2333. IncBin "Shape1.ISHP"
  2334. IncBin "Shape2.ISHP"
  2335. IncBin "Shape3.ISHP"
  2336.  
  2337. ;(Note this is a FUNCTION only, no statement version)
  2338.  
  2339.  
  2340. Function: IncText$
  2341. --------------------------------------------------------------------------
  2342. Syntax  : string$=IncText$(?Label[,optional length])
  2343.  
  2344. Description:
  2345. Used with BINARY include types....  You can then put whole text files
  2346. into strings.  The optional LENGTH will limit then string length to
  2347. whatever number you want, similar to the LEFT$ function.
  2348. It will only return a null-string "" in case of failure.
  2349.  
  2350. Example:
  2351.  
  2352. a$=IncText$(?text)
  2353. Nprint a$
  2354. b$=IncText$(?text2,32)
  2355. Nprint b$
  2356. Mousewait:End
  2357.  
  2358. text:
  2359. IncBin "Message.IBIN"
  2360.  
  2361. text2:
  2362. IncBin "Greetz.IBIN"
  2363.  
  2364.  
  2365. Function/Statement: SaveIncData
  2366. --------------------------------------------------------------------------
  2367. Syntax: success=SaveIncData(Filename$,?Label)
  2368.         SaveIncData Filename$,?Label
  2369.  
  2370. Description:
  2371. This will write to disk the unpacked version of whatever BINARY
  2372. include-object you specify.  One good use of this is to save
  2373. programs to RAM and then EXECUTE them, and DELETE them again.
  2374.  
  2375. Of course there are hundreds of uses....
  2376.  
  2377.   If SaveIncData("Ram:newfile",?executeable)=0 Then End
  2378.   Execute_ "Ram:Newfile"
  2379.   KillFile "Ram:Newfile"
  2380.   End
  2381.  
  2382.   executeable:
  2383.   IncBin "myprog.ibin"
  2384.  
  2385.  
  2386. Function: IncData
  2387. --------------------------------------------------------------------------
  2388. Syntax  : Address=IncData(?Label,memory type)
  2389.  
  2390. Description:
  2391. This allows you to include BINARY data for any number of uses that
  2392. aren't provided with the other functions.  Memory types are:
  2393.  
  2394. 0-  Any kind of memory (preferably FAST RAM)
  2395. 2-  CHIP RAM ONLY!
  2396.  
  2397. This function will return the address of the binary data in
  2398. memory, or 0 for failure....
  2399.  
  2400.  
  2401. Example of including a pure ASM routine object file for execution:
  2402.  
  2403. asmloc.l=IncData(?mlroutine,0)
  2404. Call asmloc
  2405. End
  2406.  
  2407. mlroutine:
  2408. IncBin "Ram:MLRoutine.IBIN"
  2409.  
  2410.  
  2411. Function: IncSize
  2412. --------------------------------------------------------------------------
  2413. Syntax  : size.l=IncSize(?Label)
  2414.  
  2415. Description:
  2416. Returns the size in bytes of the BINARY object at the specified label
  2417. Among other uses, you need it if you want to FREE the uncrunched
  2418. binary data.  (It will automatically be freed when your program ends)
  2419.  
  2420.  
  2421. Statement: FreeIncData
  2422. --------------------------------------------------------------------------
  2423. Syntax   : FreeIncData Size,Address
  2424.  
  2425. Description:
  2426. If you wanted to free up the memory allocated by the above IncData
  2427. function, here is how you'd do it:
  2428.  
  2429.   FreeIncData IncSize(?mlroutine),asmloc
  2430.  
  2431.  
  2432. Function: IncDataAbs
  2433. --------------------------------------------------------------------------
  2434. Syntax  : bytesize=IncDataAbs(?Label,Destination Address)
  2435.  
  2436. Description:
  2437.  
  2438. ***********************************************************
  2439. **                                                       **
  2440. **  A D V A N C E D :  Use with caution!                 **
  2441. **                                                       **
  2442. ***********************************************************
  2443.  
  2444. This command will unpack the binary data directly to the area of memory
  2445. you specify, so if you're not sure what you're doing you'll probably
  2446. GURU the Amiga!  However, it is very useful to fill arrays, uncrunch data
  2447. directly to Banks, or whatever.  Just be careful!
  2448.  
  2449. It will return zero for failure, or the number of bytes in the binary
  2450. object.  I'll provide a better example of making use of this function
  2451. later....  (Filling up array variables, etc.)
  2452.  
  2453. InitBank 0,1000,0
  2454. size.l=IncDataAbs(?Binary,BankLoc(0))
  2455. Mousewait:End
  2456.  
  2457. Binary:
  2458. IncBin "binarydata.IBIN"
  2459.  
  2460.  
  2461. Library Name: aaronsiconlib #62
  2462.  
  2463. Author      : Aaron Koolen, Vision Software, 
  2464.               15 Day Street, 
  2465.               Newton, Auckland, NZ
  2466.  
  2467. OverView:
  2468.   Not only has Aaron kindly fixed up passing of argumens in our
  2469.   cliargslib but has also donated this library which similar to
  2470.   the Reflective Images version allows access to information
  2471.   from the programs workbench icon.
  2472.  
  2473. Commands:
  2474.  
  2475.                     GETICONINFO  
  2476.                     ICONTOOL$    
  2477.                     ICONSUBTOOL$ 
  2478.                     ICONTYPE     
  2479.                     ICONSTACK    
  2480.                     ICONDEFTOOL$ 
  2481.  
  2482. Authors Documentation:
  2483.  
  2484. AaronsIconLib
  2485. =============
  2486.  
  2487. This library is for processing the icon (.info) files.  It only provides
  2488. routines for reading the data from icons, not for writing or creating new
  2489. icons, which may be added later.  It is most useful when used in 
  2490. conjunction with the ArgsLib.  You can set the maximum number of allowed 
  2491. icon info's in the options.  Also to free an IconInfo object, after a 
  2492. GetIconInfo use Free IconInfo #
  2493.  
  2494.  
  2495.  
  2496. Function: GetIconInfo
  2497. --------------------------------------------------------------------------
  2498. Syntax: boolean.w=GetIconInfo(icon#,iconname$)
  2499.  
  2500. Description:
  2501. This examines a .info file so you can get information about it.
  2502. 'iconname$' is the name of the icon without the .info suffix and icon# is
  2503. the number of the IconInfo object you want to put the data under.  It will
  2504. return FALSE (0) if it failed, or TRUE (-1) if it succeeded.
  2505.  
  2506.  
  2507. Function: IconTool$
  2508. --------------------------------------------------------------------------
  2509. Syntax: tool$=IconTool$(icon#,toolname$)
  2510.  
  2511. Description:
  2512. Returns the respective data of the tooltype specified by 'toolname$' of
  2513. IconInfo object icon#.
  2514.  
  2515. EG
  2516.  
  2517. If IconTool$(0,"CX_POPUP")="YES" Then Gosub PopUpWindow
  2518.  
  2519.  
  2520. Function: IconSubTool$
  2521. --------------------------------------------------------------------------
  2522. Syntax: boolean.w=IconSubTool$(toolname$,subtool$)
  2523.  
  2524. Description:
  2525. Returns TRUE (-1) or FALSE (0) if the sub tool type 'subtool$' exists
  2526. within the tool 'toolname$'
  2527.  
  2528. EG
  2529.  
  2530.   If IconSubTool$(0,IconTool$(0,"FILETYPE"),"ILBM") Then file type of
  2531.   file was ILBM.
  2532.  
  2533. A Subtool (My word) is one that resides in a tool type but is separated by
  2534. bars (|).  EG
  2535.  
  2536. FILETYPE=PaintProgram|ILBM    (PaintProgram and ILBM are "Sub Tools")
  2537.  
  2538. IconTool$ will return the PaintProgram|ILBM part and you can then use
  2539. IconSubtool$ to see if things like ILBM or PaintProgram exist in that
  2540. string.
  2541.  
  2542. NOTE: This does not require the passing if an IconInfo object, it simply
  2543. requires 2 strings, so you can use it for other things too.
  2544.  
  2545.  
  2546. Function: IconType
  2547. --------------------------------------------------------------------------
  2548. Syntax: type.w=IconType(icon#)
  2549.  
  2550. Description:
  2551. Returns the type of IconInfo object icon#.
  2552.  
  2553. EG  NPrint IconType(0)
  2554.  
  2555. 'type' is one of the list from workbench/workbench.bb2.
  2556.  
  2557.  
  2558. Function: IconStack
  2559. --------------------------------------------------------------------------
  2560. Syntax: stackSize.l=IconStack(icon#)
  2561.  
  2562. Description:
  2563. Returns the stack sie setting of the icon.
  2564.  
  2565.  
  2566. Function: IconDefTool$
  2567. --------------------------------------------------------------------------
  2568. Syntax: deftool$.w=IconDefTool$(icon#)
  2569.  
  2570. Description:
  2571. Returns the default tool of the icon.
  2572.  
  2573. EG  NPrint IconDefTool$(icon#)
  2574.  
  2575. May print something like "blitz2:blitz2" if icon# references a Blitz2 
  2576. source program.
  2577.  
  2578.  
  2579.  ALLOCMEM                  FREEMEM             
  2580.  BANK                      FROMCLI             
  2581.  BLOCKSCROLL               GAMEB                   
  2582.  CLIPBLITMODE              GTARROWSIZE              
  2583.  CUSTOMCOLORS              GTSTATUS                 
  2584.  CUSTOMSTRING              INITPALETTE              
  2585.  CYCLEPALETTE              INITSHAPE                
  2586.  DECODEILBM                LOADBANK               
  2587.  DECODEMEDMODULE           NUMPARS             
  2588.  DECODEPALETTE             PALETTERANGE        
  2589.  DECODESHAPES              PAR$                     
  2590.  DECODESOUND               PARPATH$                 
  2591.  DISPLAYDBLSCAN            POPINPUT            
  2592.  DISPLAYRAINBOW            POPOUTPUT           
  2593.  DISPLAYRGB                READSERIALMEM          
  2594.  DISPLAYSCROLL             SAVEPALETTE              
  2595.  DISPLAYUSER               SETPERIOD               
  2596.  DUPLICATEPALETTE          WRITESERIALMEM      
  2597.  FADEPALETTE              
  2598.  
  2599.  
  2600. Function: Bank
  2601. --------------------------------------------------------------------------
  2602. Syntax  : Bank(Bank#)
  2603.  
  2604. Returns the memory location of the given memory Bank, replaces the older
  2605. and more stupidly named BankLoc command.
  2606.  
  2607.  
  2608. Statement: BlockScroll 
  2609. --------------------------------------------------------------------------
  2610. Syntax   : BlockScroll X1,Y1,Width,Height,X2,Y2[,BitMap#] 
  2611.  
  2612. library: scrolllib
  2613.  
  2614. Description:
  2615. Same as the Scroll command except that BlockScroll is much faster but
  2616. only works with 16 bit aligned areas. This means that X1, X2 and Width
  2617. must all be multiples of 16. Useful for block scrolling routines that
  2618. render the same blocks to both sides of the display, the programmer
  2619. can now choose to render just one set and then copy the result to the
  2620. other side with the BlockScroll command.
  2621.  
  2622.  
  2623. Statement: ClipBlitMode
  2624. --------------------------------------------------------------------------
  2625. Syntax   : ClipBlitMode BPLCON0
  2626. Library  : 2dlib
  2627.  
  2628. Description:
  2629. Same as BlitMode except applies to the ClipBlit command. Another oversight
  2630. now fixed.
  2631.  
  2632.  
  2633. Statement: CustomColors
  2634. --------------------------------------------------------------------------
  2635. Syntax   : CustomColors CopList#,CCOffset,YPos,Palette,startcol,numcols 
  2636. Library  : displaylib
  2637.  
  2638. Using the custom copper space in a display, CustomColors will alter the 
  2639. displays palette at the given YPos. The number of customcops required is 
  2640. either 2+numcols for ecs displays and 2+n+n+n/16 for aga displays. In aga, 
  2641. numcols must be a multiple of 32.
  2642.  
  2643. Note that large AGA palette changes may take several lines of the display 
  2644. to be complete.
  2645.  
  2646.  
  2647. Statement: CustomString
  2648. --------------------------------------------------------------------------
  2649. Syntax   : CustomString CopList#,CCOffset,YPos,Copper$
  2650. Library  : displaylib
  2651.  
  2652. Description:
  2653. CustomString allows the user to insert their own copper commands 
  2654. (contained in a string) into the display's copper list at a given vertical
  2655. position. The amount of space required is equal to the number of copper 
  2656. instructions in the Copper$ (length of string divide by 4) plus 2 which of 
  2657. course have to be allocated with InitCopList before CustomString is used.
  2658.  
  2659.  
  2660. Statement: CyclePalette
  2661. --------------------------------------------------------------------------
  2662. Syntax   : CyclePalette Palette# 
  2663. Library  : palettelib
  2664.  
  2665. Description:
  2666. CyclePalette uses the standard color cycling parameters in the palette
  2667. object to cycle the colors. Unlike the Cycle command which copied the
  2668. resulting palette to the current screen the CyclePalette command just
  2669. modifies the palette object and can hence be used with the DisplayBitmap
  2670. command in the new Display library.
  2671.  
  2672.  
  2673. Statement: DecodeILBM
  2674. --------------------------------------------------------------------------
  2675. Syntax   : DecodeILBM BitMap#,MemoryLocation
  2676. Library  : ilbmifflib
  2677.  
  2678. Description:
  2679. A very fast method of unpacking standard iffilbm data to a bitmap. Not
  2680. only does this command allow a faster method of loading standard IFF
  2681. files but allows the programmer to "incbin" iff pictures in their programs.
  2682. See the discussion above for using DecodeILBM on both files and included
  2683. memory.
  2684.  
  2685.  
  2686. Statement: DecodeMedModule
  2687. --------------------------------------------------------------------------
  2688. Syntax   : DecodeMedModule MedModule#,MemoryLocation
  2689. Library  : medlib
  2690.  
  2691. Description:
  2692. DecodeMedModule replaces the cludgemedmodule, as med modules are not 
  2693. packed but used raw, DecodeMedModule simply checks to see the 
  2694. memorylocation passed is in ChipMem (if not it copies the data to chip) 
  2695. and points the Blitz2 MedModule object to that memory.
  2696.  
  2697.  
  2698. Statement: DecodePalette
  2699. --------------------------------------------------------------------------
  2700. Syntax   : DecodePalette Palette#,MemoryLocation[,Palette Offset]
  2701. Library  : palettelib
  2702.  
  2703. Description:
  2704. DecodePalette allows the programmer to unpack included iff palette 
  2705. information to Blitz2 palette objects.
  2706.  
  2707.  
  2708. Statament: DecodeShapes
  2709. --------------------------------------------------------------------------
  2710. Syntax   : DecodeShapes Shape#[,Shape#],MemoryLocation
  2711. Library  : shapeslib
  2712.  
  2713. Description:
  2714. DecodeShapes, similar to DecodeMedModule ensures the data is in chip and
  2715. then configures the Shape object(s) to point to the data.
  2716.  
  2717.  
  2718. Statement: DecodeSound
  2719. --------------------------------------------------------------------------
  2720. Syntax   : DecodeSound Sound#,MemoryLocation
  2721. Library  : audiolib
  2722.  
  2723. Description:
  2724. DecodeSound similar to the other new Decode commands allows the programmer
  2725. to include sound files within their program's object code.
  2726.  
  2727.  
  2728. Statement: DisplayDblScan
  2729. --------------------------------------------------------------------------
  2730. Syntax   : DisplayDblScan CopList#,Mode[,copoffset]
  2731. Library  : displaylib
  2732.  
  2733. Description:
  2734. DisplayDblScan is used to divide the vertical resolution of the display by
  2735. 2,4,8 or 16 using Modes 1,2,3 and 4. This is most useful for fast bitmap
  2736. based zooms. A Mode of 0 will return the display to 100% magnification.
  2737.  
  2738. As with the DisplayRainbow, DisplayRGB, DisplayUser and DisplayScroll
  2739. commands DisplayDblScan uses the new line by line copper control of the
  2740. display library. To initialise this mode a negative parameter is used
  2741. in the CustomCops parameter of the InitCopList command. DisplayDblScan
  2742. requires 2 copper instructions per line (make CustomCops=-2).
  2743.  
  2744.  
  2745. Statement: DisplayRainbow
  2746. --------------------------------------------------------------------------
  2747. Syntax   : DisplayRainbow CopList#,Register,Palette[,copoffset]
  2748. Library  : displaylib
  2749.  
  2750. Description:
  2751. DisplayRainbow is used to alter a certain colour register vertically down
  2752. a display. It simple maps each colour in a palette to the coresponding
  2753. vertical position of the display. ECS displays require one copper 
  2754. instruction per line while AGA displays require 4.
  2755.  
  2756.  
  2757. Statement: DisplayRGB
  2758. --------------------------------------------------------------------------
  2759. Syntax   : DisplayRGB CopList#,Register,line,r,g,b[,copoffset]
  2760. Library  : displaylib
  2761.  
  2762. Description:
  2763. DisplayRGB is a single line version of DisplayRainbow allowing the 
  2764. programmer to alter any register of any particular line. As with 
  2765. DisplayRainbow ECS displays require 1 copper instruction while AGA 
  2766. requires 4.
  2767.  
  2768.  
  2769. Statement: DisplayScroll
  2770. --------------------------------------------------------------------------
  2771. Statement: DisplayScroll CopList#,&xpos.q(n),&xpos.q(n)[,Offset]
  2772. Library  : displaylib
  2773.  
  2774. Description:
  2775. DisplayScroll allows the program to dynamically display any part of a 
  2776. bitmap on any line of the display. DisplayScroll should always follow the 
  2777. DisplayBitMap command. The parameters are two arrays holding a list of 
  2778. xoffsets that represent the difference in horizontal position from the line 
  2779. above. AGA machines are able to use the fractional part of each entry for 
  2780. super hiresolution positioning of the bitmap. Three instructions per line 
  2781. are required for the DisplayScroll command.
  2782.  
  2783.  
  2784. Statement: DisplayUser
  2785. --------------------------------------------------------------------------
  2786. Syntax   : DisplayUser CopList#,Line,String[,Offset]
  2787. Library  : displaylib
  2788.  
  2789. Description:
  2790. DisplayUser allows the programmer to use their own Copper$ at any line of
  2791. the display. Of course copper instructions have to be allocated with the
  2792. number of copper instructions in the InitCoplist multiplied by -1.
  2793.  
  2794.  
  2795. Statement: DuplicatePalette
  2796. --------------------------------------------------------------------------
  2797. Syntax   : DuplicatePalette SrcPalette#,DestPalette#
  2798. Library  : palettelib
  2799.  
  2800. Description:
  2801. DuplicatePalette simply creates a new Palette which exactly matches the
  2802. SrcPalette.
  2803.  
  2804.  
  2805. Statement: FadePalette
  2806. --------------------------------------------------------------------------
  2807. Syntax   : FadePalette SrcPalette#,DestPalette#,Brightness.q
  2808. Library  : palettelib
  2809.  
  2810. Description:
  2811. FadePalette multiplies all colours in a Palette by the Brightness argument
  2812. and places the result in the DestPalette.
  2813.  
  2814.  
  2815. Statement: FreeMem
  2816. --------------------------------------------------------------------------
  2817. Syntax   : FreeMem location,size
  2818. Library  : banklib
  2819.  
  2820. Description:
  2821. Used to free any memory allocated with the AllocMem command.
  2822.  
  2823.  
  2824. Function: FromCLI
  2825. --------------------------------------------------------------------------
  2826. Function: FromCLI 
  2827. Library : cliargslib
  2828.  
  2829. Description:
  2830. Returns TRUE (-1) if your program was run from the CLI, or FALSE (0) if run
  2831. from the WorkBench.
  2832.  
  2833.  
  2834. Function: GameB
  2835. --------------------------------------------------------------------------
  2836. Syntax  : GameB(por#) 
  2837. Library : gameiolib
  2838.  
  2839. Description:
  2840. Returns button state of cd32 style game controllers - values returned are:
  2841.  
  2842. 1  = play/pause
  2843. 2  = reverse
  2844. 4  = forward
  2845. 8  = green
  2846. 16 = yellow
  2847. 32 = red
  2848. 64 = blue
  2849.  
  2850. If more than one button is held down, values are added together. For 
  2851. example, a value of 6 means both the forward (4) and reverse (2) buttons 
  2852. are held down. Use an 'and' to isolate the status of a single button, like
  2853. this -
  2854.  
  2855. ;check RED button on port 1...
  2856. ;
  2857. if gameb(1) & 32
  2858.   ;
  2859.   ;RED button is down...
  2860.   ;
  2861. else
  2862.   ;
  2863.   ;RED button is NOT down...
  2864.   ;
  2865. endif
  2866.  
  2867.  
  2868. Statement: GTArrowSize
  2869. --------------------------------------------------------------------------
  2870. Syntax   : GTArrowSize size
  2871. Library  : bbgtlib
  2872.  
  2873. Description:
  2874. Allows the size of GTScroller arrows to be preset. Default size is 16.
  2875.  
  2876.  
  2877. Function: GTStatus
  2878. --------------------------------------------------------------------------
  2879. Syntax  : GTStatus(GTList#,Id)
  2880. Library : bbgtlib
  2881.  
  2882. Description:
  2883. GTStatus returns the status of and gadtools toggle gadgets, a value
  2884. of 1 means the the gadget is selected, 0 deselected.
  2885.  
  2886.  
  2887.  
  2888. Statement: InitPalette
  2889. --------------------------------------------------------------------------
  2890. Syntax   : InitPalette Palette#,NumColors
  2891. Library  : palettelib
  2892.  
  2893. Description:
  2894. InitPalette simply initialises a palette object to hold NumColors. All 
  2895. colors will be set to black.
  2896.  
  2897.  
  2898. Statement: InitShape
  2899. --------------------------------------------------------------------------
  2900. Syntax   : InitShape Shape#,Width,Height,Depth
  2901. Library  : shapeslib
  2902.  
  2903. Description:
  2904. InitShape has been added to simple create blank shape objects. Programmers
  2905. who make a habit of using ShapesBitMap to render graphics to a shape 
  2906. object will appreciate this one for sure.
  2907.  
  2908.  
  2909. Statement: LoadBank
  2910. --------------------------------------------------------------------------
  2911. Syntax   : LoadBank Bank#,FileName$[,MemType]
  2912.  
  2913. Description:
  2914. The LoadBank command has been modified, instead of having to initialise
  2915. the bank before loading a file, LoadBank will now initialise the bank
  2916. to the size of the file if it is not already large enough or has not been
  2917. initialised at all.
  2918.  
  2919.  
  2920. Function: NumPars
  2921. --------------------------------------------------------------------------
  2922. Syntax  : NumPars 
  2923. Library : cliargslib
  2924.  
  2925. Description:
  2926. Returns the number of parameters passed to your program.
  2927.  
  2928.  
  2929.  
  2930. Statement: PaletteRange
  2931. --------------------------------------------------------------------------
  2932. Syntax   : PaletteRange Palette#,StartCol,EndCol,r0,g0,b0,r1,g1,b1
  2933. Library  : palettelib
  2934.  
  2935. Description:
  2936. PaletteRange creates a spread of colors within a palette. Similar to 
  2937. DPaint's spread function PaletteRange takes a start and end colour and 
  2938. creates the color tweens between them.
  2939.  
  2940.  
  2941. Function: Par$
  2942. --------------------------------------------------------------------------
  2943. Syntax  : Par$(parameter#) 
  2944. Library : cliargslib
  2945.  
  2946. Description:
  2947. Returns the string value of a parameter.  
  2948.  
  2949. NOTE: If the parameter asked for is a directory/device/volume etc
  2950. (IE NOT A FILE) then Par$(#) will return an empty string.  This is a one
  2951. way you can check to see if a file was passed or not.
  2952.  
  2953.  
  2954. Function: ParPath$
  2955. --------------------------------------------------------------------------
  2956. Syntax  : ParPath$ (parameter,type)
  2957. Library : cliargslib
  2958.  
  2959. Description:
  2960. This returns the path that this parameter resides in. 'type' specifies 
  2961. how you want the path returned.
  2962.  
  2963. 0 You want only the directory of the parameter returned.
  2964. 1 You want the directory along with the parameter name returned.
  2965.  
  2966. EG:
  2967.  
  2968. If you passed the parameter "FRED" to your program from WorkBench, and 
  2969. FRED resides in the directory "work:mystuff/myprograms" then ParPath$(0,0)
  2970. will return "work:mystuff/myprograms", but ParPath$(0,1) will return
  2971. "work:mystuff/myprograms/FRED".
  2972.  
  2973. CAVEAT
  2974. The way WB handles argument passing of directories is different to that 
  2975. of files.  When a directory is passed as an argument, ArgsLib gets an 
  2976. empty string for the name, and the directory string holds the path to the
  2977. passed directory AND the directory name itself.  EG
  2978.  
  2979. Passing the blitz2 directory to a program will result in:
  2980.  
  2981. Par$(x)     Being an empty string.
  2982. ParPath$(x,0)   Being something like work:Basic/blitz2.
  2983. ParPath$(x,1) Being work:Basic/blitz2/
  2984.  
  2985. YES!  The / is appended!  This is because to keep things simpler, and more
  2986. uniform ParPath$(x,1) Is the concatenation of
  2987.  
  2988. 1)  The directory string passed by Workbench
  2989.  
  2990. AND
  2991.  
  2992. 2)  A / followed by the name given by WorkBench.
  2993.  
  2994. So you can see why the / followed by the empty string occurs.
  2995.  
  2996. The easy way around this is simply to check Par$(x), if it is empty, then
  2997. use ParPath$(x,0), if it isn't (IE a file was passed) use ParPath$(x,1) 
  2998. and you will have the entire pathname of the file OR directory.
  2999.  
  3000. See the demo program, which handles both cases.
  3001.  
  3002. NOTE 2: Is only useable from WorkBench, you will get an error if your 
  3003. program was run from the CLI and you try to call ParPath$.
  3004.  
  3005.  
  3006. Statement: PopInput & PopOutput
  3007. --------------------------------------------------------------------------
  3008. Library  : inputoutputlib
  3009.  
  3010. Description:
  3011. After input or output has been re-directed (eg using windowoutput/
  3012. fileoutput), these two commands may be used to return the channel to it's 
  3013. previous condition. 
  3014.  
  3015.  
  3016. Statement: ReadSerialMem
  3017. --------------------------------------------------------------------------
  3018. Syntax   : ReadSerialMem Unit#,Address,Length
  3019. Library  : seriallib
  3020.  
  3021. Description:
  3022. ReadSerialMem will fill the given memory space with data from the
  3023. given serial port.
  3024.  
  3025.  
  3026. Statement: SavePalette
  3027. --------------------------------------------------------------------------
  3028. Syntax   : SavePalette Palette#,FileName$
  3029. Library  : iffmakelib
  3030.  
  3031. Description:
  3032. Creates a standard IFF "CMAP" file using the given Palette's colors.
  3033.  
  3034.  
  3035. Statement: SetPeriod
  3036. --------------------------------------------------------------------------
  3037. Syntax   : SetPeriod Sound#,Period
  3038. Library  : audiolib
  3039.  
  3040. Description:
  3041. Hmmm, not sure why we never included this command in the original 
  3042. audiolib, SetPeriod simply allows the user to override the frequence 
  3043. information (period) of the sound object after it has been loaded. To 
  3044. alter a sound's pitch while playing programmers should hit the audio 
  3045. hardware direct (hardware locations are listed at the back of the 
  3046. reference manual).
  3047.  
  3048.  
  3049. Statement: WriteSerialMem
  3050. --------------------------------------------------------------------------
  3051. Syntax   : WriteSerialMem Unit#,Address,Length
  3052. Library  : seriallib
  3053.  
  3054. Description:
  3055. WriteSerialMem send the given memory space out the given serial port.
  3056.  
  3057.  
  3058.           All the commands are now sorted, few that was a lot of work!
  3059.        But what the hell, it's finished now (until a new BUM is released)
  3060.  
  3061.                                 Choose a letter:
  3062.  
  3063.                                 A             N    
  3064.                                 B             O    
  3065.                                 C             P    
  3066.                                 D             Q    
  3067.                                 E             R    
  3068.                                 F             S    
  3069.                                 G             T    
  3070.                                 H             U    
  3071.                                 I             V    
  3072.                                 J             W    
  3073.                                 K             X    
  3074.                                 L             Y    
  3075.                                 M             Z    
  3076.  
  3077.  
  3078. - A -
  3079.  
  3080.  ACTIVESCREEN              ANIMLOOP            
  3081.  ACTIVEWINDOW              APPEVENT            
  3082.  ADDAPPICON                APPICONEVENT        
  3083.  ADDAPPMENU                APPICONFILE         
  3084.  ADDAPPWINDOW              APPICONHIT          
  3085.  ADDVALUE                  APPMENUEVENT        
  3086.  AGABLUE                   APPMENUFILE         
  3087.  AGAFILLPALETTE            APPMENUHIT              
  3088.  AGAGREEN                  APPWINDOWEVENT      
  3089.  AGAPALBLUE                APPWINDOWFILE       
  3090.  AGAPALGREEN               ASLFILEREQUEST      
  3091.  AGAPALRED                 ASLFONTREQUEST      
  3092.  AGAPALRGB                 ASLSCREENREQUEST$   
  3093.  AGARED                    ATTACHGTLIST        
  3094.  AGARGB                    AVG                 
  3095.  ALLFIRE                   AVG.L                
  3096.  ALLOCMEM                  AVG.Q                             
  3097.  ANALYZEDISK         
  3098.  
  3099.  
  3100. - B -
  3101.  
  3102.  BANK                     
  3103.  BEEPSCREEN          
  3104.  BIN#                
  3105.  BITMAPTOWINDOW      
  3106.  BITPLANESBITMAP     
  3107.  BLITCOLL            
  3108.  BLOAD                    
  3109.  BLOCK               
  3110.  BLOCKSCROLL              
  3111.  BSAVE                    
  3112.  BUTTONGROUP         
  3113.  BUTTONID            
  3114.  
  3115.  
  3116. - C -
  3117.  
  3118.  CACHEOFF                  CLOSEDISK                 CRMDECRUNCH         
  3119.  CACHEPCF                  CLOSESCREEN               CUSTOMCOLORS          
  3120.  CHARCOUNT                 CLOSESERIAL               CUSTOMSTRING           
  3121.  CHDIR                     CLOSEWINDOW               CXAPPEAR              
  3122.  CHECKAGA                  CLUDGESHAPES              CXCHANGELIST          
  3123.  CHECKPRT                  CLUDGESOUND               CXDISABLE              
  3124.  CHECKSUM                  COLOURREQUEST             CXDISAPPEAR           
  3125.  CHIPFREE                  COMMODITIEBASE            CXENABLE              
  3126.  CHUNKHEADER               COMMODITYEVENT            CXKILL                  
  3127.  CHUNKYTOPLANAR            CON_BASE                  CXUNIQUE              
  3128.  CIPHER$                   COPYBYTE                  CYCLEPALETTE              
  3129.  CLEARBITMAP               COPYFILE                             
  3130.  CLEARREXXMSG              COPYLONG                     
  3131.  CLEARTOOLTYPES            COPYWORD                     
  3132.  CLICKMOUSE                CREATEARGSTRING      
  3133.  CLIPBLIT                  CREATEDISPLAY                
  3134.  CLIPBLITMODE              CREATEMSGPORT             
  3135.  CLOSECONSOLE              CREATEREXXMSG           
  3136.  
  3137.  
  3138. - D -
  3139.  
  3140.  DATE$                     DEREZ                     DISPLAYUSER              
  3141.  DATEFORMAT                DISABLE                   DOSBASE                         
  3142.  DAYS                      DISKBLOCKS                DOS_BASE                
  3143.  DECODEILBM                DISKCAPACITY              DUPLICATEPALETTE      
  3144.  DECODEMEDMODULE           DISKERRS               
  3145.  DECODEPALETTE             DISKFONTBASE         
  3146.  DECODESHAPES              DISKFREE             
  3147.  DECODESOUND               DISKUNIT            
  3148.  DECRYPT                   DISKUSED            
  3149.  DEICE                     DISPLAYADJUST       
  3150.  DELAPPICON                DISPLAYBITMAP         
  3151.  DELAPPMENU                DISPLAYCONTROLS      
  3152.  DELAPPWINDOW              DISPLAYDBLSCAN      
  3153.  DELETEARGSTRING           DISPLAYPALETTE      
  3154.  DELETEMSGPORT             DISPLAYRAINBOW       
  3155.  DELETEREXXMSG             DISPLAYRGB                    
  3156.  DEPLODE                   DISPLAYSCROLL        
  3157.  DEPTH                     DISPLAYSPRITE         
  3158.  
  3159.  
  3160. - E -
  3161.  
  3162.  EASYREQUEST               EXCHANGEDISABLE     
  3163.  ENABLE                    EXCHANGEDISAPPEAR   
  3164.  ENCRYPT                   EXCHANGEENABLE      
  3165.  ENTRYBIT$                 EXCHANGEKILL        
  3166.  ENTRYCOMMENT$             EXCHANGEMESSAGE     
  3167.  ENTRYDATE                 EXCHANGEUNIQUE      
  3168.  ENTRYDIR                  EXECVERSION         
  3169.  ENTRYHOUR                 EXISTS                  
  3170.  ENTRYMINS                   
  3171.  ENTRYNAME$                  
  3172.  ENTRYSECS                 
  3173.  ENTRYSIZE                  
  3174.  ERASE                       
  3175.  ERASEALL                     
  3176.  EVENTCODE                 
  3177.  EVENTQUALIFIER            
  3178.  EXCHANGEAPPEAR           
  3179.  EXCHANGECHANGELIST  
  3180.  
  3181.  
  3182. - F -
  3183.  
  3184.  FADEINBITMAP         FNSLENGTH            FREEINCDATA    
  3185.  FADEPALETTE          FNSLOAD              FREEMEM        
  3186.  FASTFREE             FNSORIGIN            FREEPCFCACHE     
  3187.  FFPBASE              FNSOUTPUT            FREEZONETABLE  
  3188.  FILEFILTER           FNSPREFS             FREQ                     
  3189.  FILEREQSIZE          FNSPRINT             FROMCLI               
  3190.  FILESIZE             FNSSETTAB            
  3191.  FILESTRUCTURE        FNSSLOT              
  3192.  FILLMEM              FNSUNDERLINE       
  3193.  FILLPALETTE          FNSUNLOAD            
  3194.  FILLREXXMSG          FNSVERSION         
  3195.  FINDTOOLNUMBER       FNSWIDTH         
  3196.  FINDTOOLTYPE         FORCENTSC          
  3197.  FINDTOOLVALUE        FORCEPAL          
  3198.  FNSCLIP              FORMATTRACK    
  3199.  FNSCLIPOUTPUT        FRAMES            
  3200.  FNSHEIGHT            FREECATALOG    
  3201.  FNSINK               FREEICONOBJECT   
  3202.  
  3203.  
  3204. - G -
  3205.  
  3206.  GAGETSTATUS           GTCHANGELIST    
  3207.  GAMEB                 GTGADPTR            
  3208.  GETICONINFO           GTSETATTRS       
  3209.  GETICONOBJECT         GTSTATUS           
  3210.  GETLOCALESTR          GTTAGS                
  3211.  GETMEDINSTR        
  3212.  GETMEDNOTE      
  3213.  GETMEDVOLUME    
  3214.  GETRESULTSTRING 
  3215.  GETREXXCOMMAND   
  3216.  GETREXXRESULT     
  3217.  GETSTRING$      
  3218.  GETSUPERBITMAP  
  3219.  GETWHEEL        
  3220.  GFX_BASE        
  3221.  GRAPHICSBASE    
  3222.  GTARROWSIZE          
  3223.  GTBEVELBOX      
  3224.  
  3225.  
  3226. - H -
  3227.  
  3228.  HARDCOPY            
  3229.  HEX#                
  3230.  HIDESCREEN          
  3231.  HOTKEYHIT           
  3232.  HOURS               
  3233.  
  3234.  
  3235. - I -
  3236.  
  3237.  ICONBASE               INCSHAPE         
  3238.  ICONDEFAULTTOOL        INCSIZE            
  3239.  ICONDEFTOOL$           INCSOUND           
  3240.  ICONRENDER             INCTEXT$         
  3241.  ICONSTACK              INITANIM          
  3242.  ICONSUBTOOL$           INITCOPLIST       
  3243.  ICONTOOL$              INITPALETTE      
  3244.  ICONTYPE               INITSHAPE        
  3245.  ILBMGRAB               INITZOOMXY       
  3246.  ILBMPALETTE            INSTALLFNS         
  3247.  ILBMVIEWMODE           INTUITIONBASE    
  3248.  IMPLODE                INT_BASE         
  3249.  INCBITMAP              ISEVEN           
  3250.  INCDATA                ISLOCALE         
  3251.  INCDATAABS             ISREQTOOLSACTIVE 
  3252.  INCMED                 ISREXXMSG           
  3253.  INCMOD                  
  3254.  INCNEXTSHAPE        
  3255.  
  3256.  
  3257. - J -
  3258.  
  3259.  JFIRE               
  3260.  JHORIZ              
  3261.  JOYC                
  3262.  JUMPMED                      
  3263.  JVERT               
  3264.  
  3265.  
  3266. - K -
  3267.  
  3268.  KEYCODE                        
  3269.  
  3270.  
  3271. - L -
  3272.  
  3273.  LARGEST             
  3274.  LARGEST.L           
  3275.  LARGEST.Q           
  3276.  LARGESTFREE         
  3277.  LENGTH                          
  3278.  LISA                              
  3279.  LOADANIM             
  3280.  LOADFONT            
  3281.  LOADIFF             
  3282.  LOADIFF             
  3283.  LOADMEDMODULE                
  3284.  LOADPCF             
  3285.  LOADSHAPE           
  3286.  
  3287.  
  3288. - M -
  3289.  
  3290.  MAKECOMMODITY       
  3291.  MAKEDIR                  
  3292.  MATCHTOOLVALUE      
  3293.  MAX                                     
  3294.  MEMFREE                             
  3295.  MIN                                     
  3296.  MINS                
  3297.  MONTHS              
  3298.  MOREENTRIES              
  3299.  MOTOROFF            
  3300.  MOTORON             
  3301.  MOVESCREEN          
  3302.  
  3303.  
  3304. - N -
  3305.  
  3306.  NAMEFILE              
  3307.  NEWPALETTEMODE    
  3308.  NEWTOOLTYPE    
  3309.  NEWZONETABLE   
  3310.  NEXTBANK              
  3311.  NEXTFILE$      
  3312.  NEXTFRAME      
  3313.  NPRINTCON      
  3314.  NULL           
  3315.  NUMDAYS        
  3316.  NUMPARS        
  3317.  
  3318.  
  3319. - O -
  3320.  
  3321.  OPENCONSOLE         
  3322.  OPENDISK            
  3323.  OPENSERIAL          
  3324.  
  3325.  
  3326. - P -
  3327.  
  3328.  PALADJUST                 PLOAD               
  3329.  PALBLUE                   POLY                
  3330.  PALETTEINFO               POLYF               
  3331.  PALETTERANGE              POPINPUT             
  3332.  PALGREEN                  POPOUTPUT           
  3333.  PALRED                    POSITIONSUPERBITMAP 
  3334.  PAR$                      PPDECRUNCH          
  3335.  PARPATH$                  PRINTCON            
  3336.  PATHLOCK                  PROCESSOR           
  3337.  PCFDEPTH                  PRTCOMMAND          
  3338.  PCFHEIGHT                 PRTTEXT             
  3339.  PCFINFO                   PUTICONOBJECT       
  3340.  PCFVERSION                PUTSUPERBITMAP        
  3341.  PCFWIDTH               
  3342.  PEEKTO$                     
  3343.  PHONETICSPEAK         
  3344.  PLANARTOCHUNKY               
  3345.  PLAYMED                   
  3346.  
  3347.  
  3348. - Q -
  3349.  
  3350.  QUIET               
  3351.  
  3352.  
  3353. - R -
  3354.  
  3355.  READSECTOR          REQUEST                       RTEZFLAGSREQUEST            RTREQUEST        
  3356.  READSERIAL          REQ_BASE                      RTEZFONTREQUEST             RTREVISION               
  3357.  READSERIALMEM       RESERVE                       RTEZFREEPATTERN             RTUNLOCKWINDOW   
  3358.  READSERIALMEM       RESETTIMER                    RTEZGETLONG                 RTVERSION        
  3359.  READSERIALSTRING    REXXERROR                     RTEZGETLONGRANGE            RUNERRSOFF       
  3360.  REBOOT              REXXEVENT                     RTEZGETSTRING               RUNERRSON                 
  3361.  REDUCEX2            REXXSYSBASE                   RTEZLOADFILE                         
  3362.  REMAP               REX_BASE                      RTEZMULTILOADFILE         
  3363.  REMOVEFNS           RIANIMINIT                    RTEZPALETTEREQUEST        
  3364.  RENAME              RINEXTANIMFRAME               RTEZPATHREQUEST           
  3365.  REPEATS             RRANDOMIZE                    RTEZREQUEST               
  3366.  REPLYREXXMSG        RRND                          RTEZRNEXTPATHENTRY       
  3367.  REQCOLOURS          RTASYNCPALETTEREQUEST         RTEZSAVEFILE              
  3368.  REQFILELOC          RTASYNCREQUEST                RTEZSCREENMODEREQUEST     
  3369.  REQFILEREQUEST      RTCHECKASYNCPALETTEREQUEST    RTEZSETDEFAULTDIRECTORY  
  3370.  REQFILEREQUEST$     RTCHECKASYNCREQUEST           RTEZSETPATTERN           
  3371.  REQFONTSIZE         RTENDASYNCPALETTEREQUEST      RTFILEREQUEST            
  3372.  REQOUTPUT           RTENDASYNCREQUEST             RTLOCKWINDOW             
  3373.  
  3374.  
  3375. - S -
  3376.  
  3377.  SAVEINCDATA        SETMEDVOLUME       SPACE$         
  3378.  SAVEPALETTE        SETPERIOD          SPEAK            
  3379.  SCREENHEIGHT       SETSERIALBUFFER    SPRITEMODE     
  3380.  SCREENTAGS         SETSERIALLENS      START          
  3381.  SCREENWIDTH        SETSERIALPARAMS    STARTMEDMODULE   
  3382.  SEARCHBEGIN        SETSTATUS          STOPMED        
  3383.  SEARCHEND          SETTOOLVALUE       SYSTEMDATE         
  3384.  SEARCHSTRING       SETVOICE            
  3385.  SECS               SETZONE              
  3386.  SENDREXXCOMMAND    SHAPEGADGET        
  3387.  SERIALEVENT        SHAPETOICON     
  3388.  SETBPLCON0         SHOWBITMAP      
  3389.  SETCOPYBUFFER      SHOWPALETTE      
  3390.  SETGADGETSTATUS    SHOWREQUESTORS    
  3391.  SETHOTKEY          SMALLEST        
  3392.  SETICONHIT         SMALLEST.L      
  3393.  SETICONTYPE        SMALLEST.Q      
  3394.  SETMEDMASK         SORTLIST               
  3395.  
  3396.  
  3397. - T -
  3398.  
  3399.  TEXTREQUEST     
  3400.  TEXTTIMEOUT     
  3401.  TICKS           
  3402.  TIMER                                  
  3403.  TRANSLATE$      
  3404.  
  3405.  
  3406. - U -
  3407.  
  3408.  UNPACKIFF           
  3409.  UNPACKPCF           
  3410.  USECATALOG          
  3411.  USEZONETABLE        
  3412.  
  3413.  
  3414. - V -
  3415.  
  3416.  VOICELOC            
  3417.  VPOS                
  3418.  VWAITPOS            
  3419.  
  3420.  
  3421. - W -
  3422.  
  3423.  WAIT                
  3424.  WAITFOR             
  3425.  WBDEPTH             
  3426.  WBHEIGHT            
  3427.  WBLIT               
  3428.  WBVIEWMODE          
  3429.  WBWIDTH             
  3430.  WEEKDAY             
  3431.  WINDOW              
  3432.  WPRINTSCROLL        
  3433.  WRITEBOOT           
  3434.  WRITESECTOR         
  3435.  WRITESERIAL         
  3436.  WRITESERIALMEM      
  3437.  WRITESERIALMEM      
  3438.  WRITESERIALSTRING   
  3439.  WTITLE              
  3440.  
  3441.  
  3442. - X -
  3443.  
  3444.  XOR                 
  3445.  XOR                 
  3446.  
  3447.  
  3448. - Y -
  3449.  
  3450.  YEARS               
  3451.  
  3452.  
  3453. - Z -
  3454.  
  3455.  ZONE                
  3456.  ZONEINIT            
  3457.  ZONETABLE           
  3458.  ZONETABLESIZE       
  3459.  ZONETEST            
  3460.  ZOOMX2              
  3461.  ZOOMX4              
  3462.  ZOOMX8              
  3463.  ZOOMXY              
  3464.