home *** CD-ROM | disk | FTP | other *** search
/ Otherware / Otherware_1_SB_Development.iso / amiga / programm / libs / reqtools.lha / ReqTools / README < prev    next >
Encoding:
Text File  |  1992-06-29  |  22.8 KB  |  481 lines

  1.  
  2.                       **********************************
  3.  
  4.                           reqtools.library
  5.  
  6.                           The requester toolkit.
  7.  
  8.                           Release 2.0
  9.  
  10.                           (c) 1991/1992 Nico Franτois
  11.  
  12.                       **********************************
  13.  
  14.  
  15.    First of all read the DISTRIBUTION file for information on... er well...
  16. distribution :-)
  17.  
  18.    If you have suggestions or remarks about ReqTools, or if you find any
  19. bugs, please let me know.
  20.  
  21.    Contacting the author:
  22.  
  23.      Fido:  2:292/603.10 (Nico Francois)
  24.  
  25.      UUCP:  Nico.Francois@p10.f603.n292.z2.FidoNet.Org
  26.  
  27.      Mail:  Nico Franτois
  28.             Corbielaan 13
  29.             B-3060 Bertem
  30.             BELGIUM
  31.  
  32.    If you can please use e-mail.  That way you'll stand a much better chance
  33. of getting a reply quickly.
  34.  
  35.  
  36. Contents
  37. ========
  38.  
  39. 1. Introduction
  40.  
  41. 2. Features
  42.  
  43. 3. Installation
  44.  
  45. 4. Using reqtools.library
  46.  
  47.  
  48. 1. Introduction
  49. ===============
  50.  
  51.     reqtools.library is a standard Amiga shared, runtime library.  The purpose
  52. of ReqTools is to make it a lot quicker and easier to build standard requesters
  53. into your programs.  ReqTools is designed with Commodore's style guidelines in
  54. mind, all requesters have the look-and-feel of AmigaDOS Release 2.
  55.  
  56.     If you use ReqTools in your programs you do not have to worry about
  57. requesters too much.  You'll have a lot more time to concentrate on the
  58. really important stuff your program does.
  59.  
  60.     The library has been inspired by req.library (by Colin Fox & Bruce Dawson)
  61. and Commodore's own asl.library.  You will find it shares a lot of the
  62. features with these two libraries, while it has some additional ones as well.
  63. While asl.library was great in look-and-feel I felt it lacked quite a bit in
  64. the power department.  This power _is_ mostly available in req.library, but
  65. this doesn't fit in too well with AmigaDOS Release 2.  So the idea for a new
  66. requester library was born.
  67.  
  68.     I tried to make all requesters in ReqTools very powerful, easy to use and 
  69. with a very nice new-look 3D interface.  Efficiency was also considered very
  70. important.  The 2.0 version of the library is about 34K large.  I'm sure you
  71. will agree this is not too much considering what ReqTools offers.
  72.  
  73.     ReqTools features the following requesters:  a query requester, a string
  74. requester, a number requester, a file requester, a font requester, a palette
  75. requester and new in release 2.0 of ReqTools a volume requester and a screen
  76. mode requester.
  77.  
  78.  
  79. 2. Features
  80. ===========
  81.  
  82.    The requesters have following features (features marked with *NEW* are new
  83. features for release 2.0, version 38 of ReqTools):
  84.  
  85.    All requesters:
  86.  
  87.       o have a pixel-perfect Workbench 2.0 3D look, also on Kickstart 1.3.
  88. *NEW* o Completely localized!  If you are using Workbench 2.1 or higher the
  89.         text in ReqTools requesters will appear in the language of your
  90.         Workbench (if the catalog for this language is available).
  91.       o adjust to interlaced screens and to the screen's font (rtEZRequest,
  92.         rtGetLong, rtGetString) or to any fixed-width font if the screen's
  93.         font is proportional (rtPaletteRequest/rtFileRequest/rtFontRequest).
  94. *NEW*   Requesters can also use any suitable font you specify.
  95.       o can appear under the mouse pointer, centered on the
  96.         screen/in a window or at the top left of the screen/a window.
  97.       o can be used asynchronously.
  98.       o check pr_WindowPtr of your process is to find the screen they should
  99.         appear on (can be overridden).
  100.       o use tags for maximum future extendibility.  All standard 2.0 tags are
  101.         supported (like TAG_SKIP, TAG_MORE, etc.).
  102.       o bring the screen they appear on to the front.  The screen that was
  103.         in front previously will be put in front again when the requester
  104.         finishes (if it is still open).
  105. *NEW*   This behaviour can be switched off.
  106.       o will always appear in the visible portion of the screen (support of
  107.         virtual screens).
  108.       o are extensively tested using enforcer and mungwall debugging tools.
  109. *NEW* o have the ability to lock the parent window from all user input and
  110.         give it a standard wait pointer automatically.
  111. *NEW* o can share the IDCMP port of the parent window.
  112. *NEW* o support a callback hook for handling IDCMP messages from a shared
  113.         IDCMP port.
  114. *NEW* o have keyboard shortcuts for gadgets (key underlined in gadget label).
  115.         Use Right Amiga key with shortcut if a string gadget is active.
  116.  
  117.    rtEZRequest, the query requester:
  118.  
  119.       o easy keyboard shortcuts:
  120.         - Left Amiga V and Left Amiga B (like the standard requesters).
  121.         - Y for positive response.
  122.         - N, R, Esc for negative response.
  123.         - Return can also be used as a shortcut and can be
  124.           associated with any response.  The gadget in question
  125.           will have its text printed bold.
  126.           Default response for Return is the positive response.
  127.         - buttons give visual feedback when keyboard shortcuts
  128.           are used.
  129.         - keyboard shortcuts can be canceled by pressing Shift
  130.           before releasing the key.
  131. *NEW*   - keyboard shortcuts can be defined to be any character in the
  132.           button's label.  The character in question will be underlined.
  133.       o number of responses only limited by screen width.
  134.       o allows for multiple lines of text.
  135.       o text can be centered in requester (great for about requesters).
  136.       o supports the use of 'printf' formatting codes in text
  137.         and in responses.
  138.       o can be terminated by IDCMP events.
  139.  
  140.    rtFileRequest, the file requester:
  141.  
  142.       o similar in use and look-and-feel as Asl file requester.
  143.       o buffers directories in memory.
  144.       o files and directories can be added or removed from the buffer
  145.         by the calling program.
  146.       o can be put in save mode, disabling double-clicks and asking you if
  147.         directories that can't be found (entered manually) should be created.
  148.       o optional callback hook for verification of files before they are
  149.         added to the buffer.
  150.       o supports multiple selection of files and optionally of directories.
  151.       o when multi-select is on All, Clear and Match.. buttons are available.
  152.         All selects, and Clear unselects all files.  Match.. brings up a
  153.         requester where the user can enter a pattern to select files.
  154.       o can be used as a directory requester (showing no files).
  155.       o optional pattern gadget to match files on.
  156.       o shows all devices (with volume names) and all assigns made.
  157.       o supports TABCYCLE under 2.0
  158.       o pattern matching supports _ALL_ AmigaDOS 2.0 patterns.
  159. *NEW* o can be used as a volume requester to get a device or an assign
  160.         from the user.
  161. *NEW* o can be resized in height to show more files.
  162. *NEW* o Shows disk percentage used next to volume names.
  163. *NEW* o Allows you to enter paths in the filename string gadget.  If the
  164.         requester finds a path in the filename it will change the directory
  165.         to that path.  So if you e.g. enter 'Devs:mountlist' in the filename
  166.         gadget the requester will read the 'Devs:' directory and set the
  167.         filename gadget to 'mountlist'.  If you enter 'printers/' it will go
  168.         into the printers directory. Enter '/' to go to the parent directory.
  169. *NEW* o Completely keyboard controlable: use up and down cursor keys to
  170.         select files or directories.  Use Shift-Up and Shift-Down to jump
  171.         by one window-full.
  172.  
  173.    rtFontRequest, the font requester:
  174.  
  175.       o buffers all fonts in memory.
  176.       o shows sample of font you click on.
  177.       o can be also be used to select the font's style.
  178.       o supports color fonts, can change the screen's palette.
  179.       o supports scaled fonts (AmigaOS Release 2 only).
  180.       o optional callback hook for verification of fonts before they are
  181.         added to the buffer.
  182.       o supports TABCYCLE under 2.0
  183. *NEW* o can be resized in height to show more fonts.
  184. *NEW* o makes sure selected font is visible in listview when it comes up.
  185.  
  186. *NEW* rtScreenModeRequest, the display mode requester (Kickstart 2.0+ only!):
  187.  
  188. *NEW* o all modes in the DisplayInfo database can be displayed.
  189. *NEW* o displays visible and nominal size.
  190. *NEW* o user may enter prefered size or choose to get the defaults.
  191. *NEW* o number of colors selectable.
  192. *NEW* o can be put up with the attributes from a given screen.
  193. *NEW* o optional callback hook for examining a display mode before it is
  194.         added to the requester.
  195. *NEW* o can be resized in height to show more modes.
  196. *NEW* o makes sure selected mode is visible in listview when it comes up.
  197.  
  198.    rtPaletteRequest, the palette requester:
  199.  
  200.       o features Copy, Swap and Spread functions.
  201.       o current values of red, green and blue are displayed.
  202.       o returns the selected color.
  203.  
  204.    rtGetLong, the long integer requester:
  205.  
  206.       o width of requester can be set by caller.
  207.       o a minimum and maximum can be supplied and will be displayed
  208.         in the requester.
  209.       o a value to show up when the requester appears can be supplied.
  210. *NEW* o can display buttons with several possible responses.
  211. *NEW* o invisible entry is possible (useful for getting a code number).
  212. *NEW* o patterned backfill of requester can be switched on or off.
  213. *NEW* o some line(s) of (centered) text may be displayed above the entry
  214.         gadget to give the user some extra information.
  215.  
  216.    rtGetString, the string requester:
  217.  
  218.       o width of requester can be set by caller.
  219.       o a string to show up when the requester appears can be supplied.
  220. *NEW* o can display buttons with several possible responses.
  221. *NEW* o invisible entry is possible (useful for getting a password).
  222. *NEW* o patterned backfill of requester can be switched on or off.
  223. *NEW* o some line(s) of (centered) text may be displayed above the entry
  224.         gadget to give the user some extra information.
  225.  
  226.  
  227. 3. Installation
  228. ===============
  229.  
  230.    To install reqtools.library copy it to your Libs: directory by hand, or
  231. run the installation script 'Install' (by using 'Execute' from the Shell or
  232. by double-clicking its icon).
  233.  
  234.    reqtools.library is provided in two versions (that are 100% equivalent,
  235. meaning you don't have to care which version the user installed):  one for
  236. Kickstart 1.2 (or higher) and one for Kickstart 2.0 and higher.
  237.  
  238.    The version for Kickstart 2.0 uses 2.0 ROM functions for stuff like
  239. pattern matching, parsing tags, the 3D look, while a lot in the Kickstart 1.3
  240. version is emulated.  It issuggested you use the 2.0 version of the library if
  241. you have Kickstart 2.0 in ROM
  242.  
  243.    If you are running Workbench 2.1 or higher you will have the possiblity to
  244. use ReqTools in different languages.  Just use the appropriate install script
  245. in the Install/Workbench_2.1+ directory.
  246.  
  247.  
  248. 4. Using reqtools.library
  249. =========================
  250.  
  251.    If you are a C programmer all you need to do is include the correct
  252. headers and open reqtools.library. After that you can use the functions in
  253. the library as if they were C functions. If your program quits it must of
  254. course close the library again.  See 'demo.c' for an example.
  255.  
  256.    Glue code for several compilers/languages is included with ReqTools 2.0.
  257. Look in the Glue directory of the ReqTools distribution to see if glue code
  258. exists for your compiler and/or programming language.  If it doesn't and you
  259. write your own please send it to me and I'll include it in the next release
  260. of ReqTools.
  261.     Note that the source for the Manx C libraries is the same as for the SAS/C
  262. libraries.  See the README.Manx file in the archive
  263. 'Glue/Sas-C/LibSource.lha'.
  264.  
  265.    Functions allowing a variable number of arguments can't be called using
  266. pragmas (in-line library calls, no glue code required).  So if you use these
  267. you must always link with LIB:reqtools.lib or LIB:reqtoolsnb.lib (for SAS-C,
  268. or with the specific libraries for your compiler/language).
  269.  
  270.    Assembly programmers should also include the correct files and open
  271. reqtools.library.  To call a function they must load A6 with the library base,
  272. put the arguments in the appropriate registers and jump to the library vector
  273. offset of the function they want to call.
  274.  
  275.    All library functions are explained in the autodoc file 'reqtools.doc'.
  276.  
  277.                                                        Enjoy.
  278.  
  279.  
  280.                                LIBRARY HISTORY:
  281.  
  282. *****************************************************************************
  283. RELEASE 1.0 (Library version 37.556 [1.3] - 37.670 [2.0])
  284.  
  285.     First release.
  286.  
  287. *****************************************************************************
  288. RELEASE 1.0a (Library version 37.557 [1.3] - 37.673 [2.0])
  289.  
  290.     Fixed two minor bugs:
  291.       - if a directory could not be found and you re-invoked the file
  292.         requester it wouldn't check the directory again.
  293.       - devices like PRT:, CON:, etc. now no longer show up in the device
  294.         list of the 2.0 file requester.
  295.  
  296. *****************************************************************************
  297. RELEASE 1.0b (Library version 37.566 [1.3] - 37.678 [2.0])
  298.  
  299.     Fixed bug: entering a pattern when a file requester's directory was
  300.       invalid could cause a crash.
  301.     rtGetString() and rtGetLong() 2.0 requester windows no longer have close
  302.       gadgets.
  303.     Font requester entries are "release verify" instead of "immediate".
  304.     If no minimum or maximum is given for the GetLong requester it will not
  305.       be displayed (1.0 and 1.0a displayed MAXINT or MININT).
  306.     Minor cosmetic adjustments to file, font and palette requesters.
  307.     Oberon interface to the library included.
  308.  
  309. *****************************************************************************
  310. RELEASE 1.0c (Library version 37.592 [1.3] - 37.718 [2.0])
  311.  
  312.     Boopsi dispatch function for rtEZRequestA() buttons optimized (ReqTools
  313.       for Kickstart 2.0).  Occasional flicker just about eliminated.
  314.     Enlarged buttons a bit in rtGetLongA(), rtGetStringA() and the file, font
  315.       and palette requesters.
  316.     Width of scroller gadget in file requester window increased.
  317.     File string gadget is cleared when 'All' or 'Match..' is used.  This
  318.       wasn't done before and could result in unexpected multi-select results.
  319.     Visual feedback for keyboard shortcuts improved (rtEZRequestA()).  Button
  320.       stays depressed as long as the key in question is held down, but still
  321.       for a minumum of 1/10 sec.  New feature:  shortcuts can be canceled by
  322.       pressing Shift before releasing the key.
  323.     Minor bug fix: keyboard shortcuts V and B now really only work together
  324.       with the Left Amiga key.  Used to work without the qualifier.
  325.     rtEZRequestA(), rtGetLongA() and rtGetStringA() will no longer call the
  326.       DOS function Delay(), so they may from now on be called by tasks.
  327.       Every ReqTools requester, except the file and font requesters (they use
  328.       DOS for obvious reasons), can be called from a task.
  329.     EZRequest with only one button now responds to the Return key, whether
  330.       EZREQF_NORETURNKEY is set or not.
  331.     Fixed small bug in libraries/reqtools.i include file.  rtfi_Hook and
  332.       rtfo_Hook were followed by a ; and this could lead to problems.
  333.     Libraries (reqtoolss.lib and reqtoolssr.lib) for Dice C included.
  334.     Pre-release (0.91▀) of RTPatch patcher program included.
  335.  
  336. *****************************************************************************
  337. RELEASE 1.0d (Library version 37.600 [1.3] - 37.726 [2.0])
  338.  
  339.     rtEZRequestA(), rtGetStringA() and rtGetLongA() now switch the processor
  340.       stack to ensure sufficient stack space for the function to succeed.
  341.     Fixed bug in rtGetLong() requester in 2.0 version of ReqTools.  Used to
  342.       return TRUE and a random value if the user pressed Ok when the integer
  343.       gadget was empty.
  344.     File requester is somewhat larger by default.
  345.     Improved automatic requester resizing (if requester would become too big
  346.       for the screen).
  347.     File requester (in save mode) no longer asks "Create drawer?" when you
  348.       entered a drawer string containing a non-existing volume (e.g. 'FOO:').
  349.     Entries in file requester are now sorted immediately when you select the
  350.       slider gadget and not when you release it (1.3 version of ReqTools).
  351.     Latest revision of Oberon interface included.
  352.     Modula-2 interface to the library included.
  353.     Manx C interface to the library included.
  354.  
  355. *****************************************************************************
  356. RELEASE 1.0e (Library version 37.600 [1.3] - 37.726 [2.0])
  357.  
  358.     Rearranged directories a bit.  All glue code now in one directory.
  359.     Installation script now uses Commodore's Installer utility.
  360.     Two Modula-2 interfaces to the library are now included, one for M2Sprint
  361.       and one for M2Amiga.
  362.     Some bugs in the Dice C libs have been fixed (thanks to Magnus Holmgren).
  363.     Interface for HiSoft's HighSpeed Pascal included.
  364.  
  365. *****************************************************************************
  366. RELEASE 2.0 (Library version 38.347 [1.3] - 38.693 [2.0])
  367.  
  368.     All requesters now have keyboard shortcuts.
  369.     Kickstart 2.0 version of ReqTools has been localized.  As long as the
  370.       appropriate catalog file exists ReqTools will appear in the user's
  371.       selected langauge.
  372.     New requester: rtScreenModeRequestA().  A screen mode requester. Can be
  373.       used to get a screen mode, size, depth and overscan type from the user.
  374.       This requester is only available on Kickstart 2.0 or higher, but also
  375.       present in the Kickstart 1.3 version of ReqTools.
  376.     File, font and screenmode requesters are now resizable (in height).
  377.     Font, volume and screen mode requesters will now make sure the current
  378.       entry is visible in the listview when the requester first comes up.
  379.     Improved DOWILDFUNC hook interface.  New tag: RTxx_FilterFunc. Old hook
  380.       interface (using req->Hook and FREQF_DOWILDFUNC flag) is still
  381.       supported, but declared obsolete.  Don't use in new code.
  382.     Several new tags:
  383.       o RT_Locale:  specify a locale to be used instead of the default one.
  384.         Ignored if locale.library isn't present in the system or you are
  385.         using the Kickstart 1.3 version of ReqTools.
  386.       o RT_ShareIDCMP and RT_IntuiMsgFunc:  All requesters can now share
  387.         their IDCMP port with the parent window.  A callback hook for
  388.         intuition messages received not concerning the requester can also be
  389.         set using the RT_IntuiMsgFunc tag.
  390.       o RT_LockWindow:  Enables you to make ReqTools lock the parent window
  391.         from all user input and give the window a standard wait pointer.
  392.         After the requester returns the window will be unlocked and will get
  393.         its original pointer back.
  394.       o RT_Underscore:  With this tag it is possible to define keyboard
  395.         shortcuts for buttons.  You can ask ReqTools to underline a character
  396.         in the button's label and use this as a shortcut.
  397.       o for rtGetString() and rtGetLong(): RTGS_GadFmt, RTGS_GadFmtArgs,
  398.         RTGL_GadFmt and RTGL_GadFmtArgs.  With these tags you may give the
  399.         user several ways out of the string/long requester.
  400.       o for rtGetString() and rtGetLong(): RTGS_Invisible and RTGL_Invisible.
  401.         Can be used to switch on invisible typing to get a password or a code
  402.         number from the user.
  403.       o RTGS_TextFmt, RTGL_TextFmt, RTGS_TextFmtArgs and RTGL_TextFmtArgs:
  404.         These tags allow you to supply some line(s) of text that should be
  405.         printed above the string/integer gadget in the rtGetString() or
  406.         rtGetLong() requesters.
  407.       o RTGS_Flags and RTGL_Flags:  Set certain flags for rtGetString() and
  408.         rtGetLong() requesters.  Used to set the GSREQF_CENTERTEXT or
  409.         GLREQF_CENTERTEXT flags.
  410.       o RTGS_Backfill and RTGL_Backfill:  Switch the patterned backfill in
  411.         the rtGetString() and rtGetLong() requesters on or off.
  412.       o RT_ScreenToFront:  Allows you to switch of the default behaviour of
  413.         popping the screen the requester appears on to the front.
  414.       o RT_TextAttr:  Allows you to specify a font a requester should use
  415.         instead of the screen or default font.
  416.       o RTFI_VolumeRequest:  New flavor of file requester: volume requester.
  417.         Allows you to easily get a device/assign from the user.
  418.       o RTFI_AllowEmpty:  Enables you to allow the file requester to accept
  419.         an empty filename.  Normally cancels the requester if no filename
  420.         was entered.
  421.     Changes to file requester:
  422.       o Shows disk percentage used next to volume names.
  423.       o 'Hide .info' cycle gadget gadget in file requester replaced by
  424.         '.info' toggle gadget next to filename string gadget.
  425.       o Will no longer automatically change directories to their full
  426.         pathname.  Will only do so when needed (e.g. parent of an assign).
  427.       o Allows you to enter paths in the filename string gadget.  If the
  428.         requester finds a path in the filename it will change the directory
  429.         to that path.
  430.       o Completely keyboard controlable: use up and down cursor keys to
  431.         select files or directories.  Use Shift-Up and Shift-Down to jump
  432.         by one window-full.
  433.       o 1.3 version has a 2.0-look sizing gadget and bottom border.
  434.       o Changed 'Disks' to 'Volumes'.
  435.       o Changed '(dir)' to 'Drawer' (right justified).
  436.       o Assigns now displayed differently (with 'Assign' right justified).
  437.       o Added an indicator for number of selected files (if multiselect on).
  438.       o No longer shows 'Add', 'Match..' and 'Clear' gadgets if no multi-
  439.         select is possible.
  440.     New library functions:
  441.       o rtLockWindow() and rtUnlockWindow():  easily lock a window from user
  442.         input and give it a standard wait pointer.
  443.       o rtCloseWindowSafely():  close a window with a shared IDCMP port.
  444.     Updated glue code:
  445.       o Oberon interface updated for ReqTools V38.
  446.       o SAS/C, Manx C and Dice glue code updated for ReqTools V38.
  447.       o New HighSpeed Pascal (for ReqTools V38) interface written by
  448.         Gunter Indenhoek included.
  449.     Demo updated to demonstrate new features of ReqTools 2.0.
  450.     Version 1.0 of RTPatch patcher program included.  Patches req.library,
  451.       arp.library and asl.library to use ReqTools requesters instead.
  452.  
  453. *****************************************************************************
  454.  
  455. reqtools.library written by Nico Franτois (Yes, Nico is my first name :-)
  456.  
  457. Thanks to o Kai Bolay for writing the Oberon interface,
  458.           o Frank L÷mker and Michael Griebling for writing the Modula-2
  459.             interfaces,
  460.           o Jan van den Baard for writing the Dice libraries,
  461.           o Martin Steppler for writing the Manx C libraries,
  462.           o Richard Waspe and Gunter Indenhoek for writing the HighSpeed
  463.             Pascal interfaces,
  464.           o Federico Giannici for the useful suggestions
  465.           o Peter Stuer, Gunter Indenhoek, Jorrit Tyberghein and Ives Aerts
  466.             for beta-testing.
  467.           o Herman Stevens for being my Fido boss node and having such a
  468.             great Amiga BBS.
  469.           o All registered ReqTools users/developers.
  470.  
  471.  
  472. "What you got buried? In your backyard
  473.  What secret do you sleep with when the black moon comes?" - The Black Crowes
  474.  
  475.  
  476. (C) 1991/1992 Nico Franτois
  477.  
  478.                                    //
  479.                        Thanks to \X/ Amiga for being the best computer ever !
  480.  
  481.