home *** CD-ROM | disk | FTP | other *** search
/ Merciful 1 / Merciful - Disc 1.iso / software / a / asm_one / asm-onev1.25a.dms / in.adf / Release3.1 / AutoDocs3.1.lha / doc / utility.doc < prev    next >
Encoding:
Text File  |  1993-08-12  |  39.9 KB  |  1,391 lines

  1. TABLE OF CONTENTS
  2.  
  3. utility.library/AddNamedObject
  4. utility.library/AllocateTagItems
  5. utility.library/AllocNamedObjectA
  6. utility.library/Amiga2Date
  7. utility.library/ApplyTagChanges
  8. utility.library/AttemptRemNamedObject
  9. utility.library/CallHookPkt
  10. utility.library/CheckDate
  11. utility.library/CloneTagItems
  12. utility.library/Date2Amiga
  13. utility.library/FilterTagChanges
  14. utility.library/FilterTagItems
  15. utility.library/FindNamedObject
  16. utility.library/FindTagItem
  17. utility.library/FreeNamedObject
  18. utility.library/FreeTagItems
  19. utility.library/GetTagData
  20. utility.library/GetUniqueID
  21. utility.library/MapTags
  22. utility.library/NamedObjectName
  23. utility.library/NextTagItem
  24. utility.library/PackBoolTags
  25. utility.library/PackStructureTags
  26. utility.library/RefreshTagItemClones
  27. utility.library/ReleaseNamedObject
  28. utility.library/RemNamedObject
  29. utility.library/SDivMod32
  30. utility.library/SMult32
  31. utility.library/SMult64
  32. utility.library/Stricmp
  33. utility.library/Strnicmp
  34. utility.library/TagInArray
  35. utility.library/ToLower
  36. utility.library/ToUpper
  37. utility.library/UDivMod32
  38. utility.library/UMult32
  39. utility.library/UMult64
  40. utility.library/UnpackStructureTags
  41. utility.library/AddNamedObject                 utility.library/AddNamedObject
  42.  
  43.    NAME
  44.     AddNamedObject -- add a named object to the given namespace. (V39)
  45.  
  46.    SYNOPSIS
  47.     success = AddNamedObject(nameSpace, object);
  48.     D0             A0         A1
  49.  
  50.     BOOL AddNamedObject(struct NamedObject *, struct NamedObject *);
  51.  
  52.    FUNCTION
  53.     Adds a new item to a NameSpace.  If the NameSpace doesn't support
  54.     duplicate names, a search for a duplicate will be made, and
  55.     0 (failure) will be returned.  Otherwise, the entry will be
  56.     Enqueue()ed to the NameSpace.
  57.  
  58.    INPUTS
  59.     nameSpace - the name space to add to (NULL for root namespace)
  60.     object - the object to add  (If NULL, will return failure)
  61.  
  62.    RESULT
  63.     success - whether the operation succeeded.  Check this always!
  64.  
  65.    SEE ALSO
  66.     AttemptRemNamedObject(), RemNamedObject()
  67.  
  68. utility.library/AllocateTagItems             utility.library/AllocateTagItems
  69.  
  70.    NAME
  71.     AllocateTagItems -- allocate a tag list. (V36)
  72.  
  73.    SYNOPSIS
  74.     tagList = AllocateTagItems(numTags);
  75.     D0                   D0
  76.  
  77.     struct TagItem *AllocateTagItems(ULONG);
  78.  
  79.    FUNCTION
  80.     Allocates the specified number of usable TagItems slots.
  81.  
  82.     Note that to access the TagItems in 'tagList', you should use
  83.     the function NextTagItem(). This will insure you respect any
  84.     chaining (TAG_MORE) and secret hiding places (TAG_IGNORE) that
  85.     this function might generate.
  86.  
  87.    INPUTS
  88.     numTags - the number of TagItem slots you want to allocate.
  89.  
  90.    RESULTS
  91.     tagList    - the allocated chain of TagItem structures, or NULL if
  92.               there was not enough memory. An allocated tag list must
  93.               eventually be freed using FreeTagItems().
  94.  
  95.    SEE ALSO
  96.     <utility/tagitem.h>, FreeTagItems(), CloneTagItems()
  97.  
  98. utility.library/AllocNamedObjectA           utility.library/AllocNamedObjectA
  99.  
  100.    NAME
  101.     AllocNamedObjectA -- allocate a named object. (V39)
  102.  
  103.    SYNOPSIS
  104.     object = AllocNamedObjectA(name, tagList);
  105.     D0                         A0    A1
  106.  
  107.     struct NamedObject *AllocNamedObjectA(STRPTR, struct TagItem *);
  108.  
  109.     object = AllocNamedObject(name, Tag1, ...);
  110.  
  111.     struct NamedObject *AllocNamedObject(STRPTR, ULONG, ...);
  112.  
  113.    FUNCTION
  114.     Allocates a NamedObject and initializes it as needed to the
  115.     name given. This object can then be used as an object in the
  116.     namespaces. Tags can be given to make an object contain a
  117.     namespace such that nested namespaces can be built.
  118.     When the object is allocated, it automatically has one use.
  119.     If you later wish to release this object such that others may
  120.     remove it from the namespace you must do a ReleaseNamedObject().
  121.  
  122.    INPUTS
  123.     name - name for the object (must not be NULL)
  124.     tagList - tags with additional information for the allocation or NULL
  125.  
  126.    TAGS
  127.     ANO_NameSpace - BOOL tag, default FALSE.  If this tag is
  128.                     TRUE, the named object will also have a
  129.                     name space attached to it.
  130.     ANO_UserSpace - ULONG tag, default 0.  If this tag is non-NULL
  131.                     it defines the size (in bytes) of the user
  132.                     space to be allocated with the named object
  133.                     and that will be pointed to by the no_Object
  134.                     pointer.  This memory is long-word aligned.
  135.                     If no space is defined, no_Object will be NULL.
  136.     ANO_Priority  - BYTE tag, default 0.  This tag lets you pick
  137.                     a priority for the named object for when it is
  138.                     placed into a name space.
  139.     ANO_Flags     - ULONG tag, default 0.  This tag lets you set
  140.                     the flags of the NameSpace (if you allocated
  141.                     one)  There currently are only TWO flags.
  142.                     Do *NOT* set *any* other bits as they are for
  143.                     future use!!!  (You can't read them anyway)
  144.                     The flags are:
  145.                     NSF_NODUPS    - Name space must be unique.
  146.                     NSF_CASE    - Name space is case sensitive
  147.  
  148.    RESULT
  149.     object - the object allocated, or NULL for failure. The object
  150.              is defined as a pointer to a pointer.  You can do what you
  151.              wish with the pointer. (It may be NULL or contain a pointer
  152.              to memory that you had asked for in the tags.)
  153.  
  154.    SEE ALSO
  155.     FreeNamedObject(), <utility/name.h>
  156.  
  157. utility.library/Amiga2Date                         utility.library/Amiga2Date
  158.  
  159.    NAME
  160.     Amiga2Date -- fill in a ClockData structure based on a system
  161.               time stamp (V36)
  162.  
  163.    SYNOPSIS
  164.     Amiga2Date(seconds,result);
  165.                D0      A0
  166.  
  167.     VOID Amiga2Date(ULONG,struct ClockData *);
  168.  
  169.    FUNCTION
  170.     Fills in a ClockData structure with the date and time calculated
  171.     from a ULONG containing the number of seconds from 01-Jan-1978
  172.     to the date.
  173.  
  174.    INPUTS
  175.     seconds - the number of seconds from 01-Jan-1978.
  176.     result - a pointer to a ClockData structure that will be altered
  177.          by this function
  178.  
  179.    SEE ALSO
  180.     CheckDate(), Date2Amiga()
  181.  
  182. utility.library/ApplyTagChanges               utility.library/ApplyTagChanges
  183.  
  184.    NAME
  185.     ApplyTagChanges -- change a tag list based on a second tag list. (V39)
  186.  
  187.    SYNOPSIS
  188.     ApplyTagChanges(list,changeList);
  189.             A0   A1
  190.  
  191.     VOID ApplyTagChanges(struct TagItem *, struct TagItem *);
  192.  
  193.    FUNCTION
  194.     For any tag that appears in both 'list' and 'changeList', this
  195.     function will change the ti_Data field of the tag in 'list' to
  196.     match the ti_Data field of the tag in 'changeList'. In effect,
  197.     'changeList' contains a series of new values for tags already in
  198.     'list'. Any tag in 'changeList' that is not in 'list' is ignored.
  199.  
  200.    INPUTS
  201.     list - a list of existing tags (may be NULL)
  202.     changeList - a list of tags to modify 'list' with (may be NULL)
  203.  
  204.    SEE ALSO
  205.     <utility/tagitem.h>, FilterTagChanges()
  206.  
  207. utility.library/AttemptRemNamedObject   utility.library/AttemptRemNamedObject
  208.  
  209.    NAME
  210.     AttemptRemNamedObject -- attempt to remove a named object. (V39)
  211.  
  212.    SYNOPSIS
  213.     result = AttemptRemNamedObject(object);
  214.     D0                             A0
  215.  
  216.     LONG AttemptRemNamedObject(struct NamedObject *);
  217.  
  218.    FUNCTION
  219.     Attempts to remove an object from whatever NameSpace it's in.
  220.     You must have found the object first (in order to get a use count)
  221.     before trying to remove it.  If the object is in use or is
  222.     in the process of being removed, this function will return
  223.     a failure code.  If the object is fully removed, the object will
  224.     then be available to be FreeNamedObject().
  225.  
  226.    INPUTS
  227.     object - the object to attempt to remove  The object must be valid
  228.  
  229.    RESULT
  230.     success - FALSE if object is still in use (somewhere)
  231.               TRUE if object was removed
  232.  
  233.    SEE ALSO
  234.     RemNamedObject(), AddNamedObject(), ReleaseNamedObject()
  235.  
  236. utility.library/CallHookPkt                       utility.library/CallHookPkt
  237.  
  238.    NAME
  239.     CallHookPkt -- invoke a Hook function callback. (V36)
  240.  
  241.    SYNOPSIS
  242.     return = CallHookPkt(hook,object,message);
  243.     D0             A0   A2     A1
  244.  
  245.     ULONG CallHookPkt(struct Hook *,APTR,APTR);
  246.  
  247.    FUNCTION
  248.     Performs the callback standard defined by a Hook structure.
  249.     This function is really very simple; it effectively performs
  250.     a JMP to Hook->h_Entry.
  251.  
  252.     It is probably just as well to do this operation in an
  253.     assembly language function linked in to your program, possibly
  254.     from a compiler supplied library or a builtin function.
  255.  
  256.     It is anticipated that C programs will often call a 'varargs'
  257.     variant of this function which will be named CallHook. This
  258.     function must be provided in a compiler specific library, but
  259.     an example of use would be:
  260.  
  261.     result = CallHook(hook,dataobject,COMMAND_ID,param1,param2);
  262.  
  263.     The function CallHook() can be implemented in many C compilers
  264.     like this:
  265.  
  266.     ULONG CallHook(struct Hook *hook, APTR object, ULONG command, ... )
  267.     {
  268.         return(CallHookPkt(hook,object,(APTR)&command));
  269.     }
  270.  
  271.    INPUTS
  272.     hook - pointer to an initialized Hook structure as defined in
  273.            <utility/hooks.h>
  274.     object - useful data structure in the particular context the hook is
  275.          being used for.
  276.     message - pointer to a message to be passed to the hook. This is not
  277.           an Exec Message structure, but is a message in the OOP sense.
  278.  
  279.    RESULTS
  280.     return - the value returned by the hook function.
  281.  
  282.    WARNING
  283.     The functions called through this function should follow normal
  284.     register conventions unless EXPLICITLY documented otherwise (and
  285.     they have a good reason too).
  286.  
  287.    SEE ALSO
  288.     <utility/hooks.h>
  289.  
  290. utility.library/CheckDate                           utility.library/CheckDate
  291.  
  292.    NAME
  293.     CheckDate -- checks a ClockData structure for legal date. (V36)
  294.  
  295.    SYNOPSIS
  296.     seconds = CheckDate(date);
  297.     D0                  A0
  298.  
  299.     ULONG CheckDate(struct ClockData *);
  300.  
  301.    FUNCTION
  302.     Determines if the ClockData structure contains legal date information
  303.     and returns the number of seconds from 01-Jan-1978 to that date, or 0
  304.     if the ClockData structure contains illegal data.
  305.  
  306.    INPUTS
  307.     date - a filled-in ClockData structure
  308.  
  309.    RESULTS
  310.     seconds    - 0 if date is invalid, otherwise the number of seconds from
  311.           01-Jan-1978 to the date
  312.  
  313.    BUGS
  314.     The wday field of the ClockData structure is not checked.
  315.  
  316.    SEE ALSO
  317.     Amiga2Date(), Date2Amiga()
  318.  
  319. utility.library/CloneTagItems                   utility.library/CloneTagItems
  320.  
  321.    NAME
  322.     CloneTagItems -- copy a tag list. (V36)
  323.  
  324.    SYNOPSIS
  325.     clone = CloneTagItems(original);
  326.     D0              A0
  327.  
  328.     struct TagItem *CloneTagItems(struct TagItem *);
  329.  
  330.    FUNCTION
  331.     Copies the essential contents of a tag list into a new tag list.
  332.  
  333.     The cloning is such that calling FindTagItem() with a given tag on
  334.     the original or cloned tag lists will always return the same
  335.     tag value. That is, the ordering of the tags is maintained.
  336.  
  337.    INPUTS
  338.     original - tag list to clone. May be NULL, in which case an
  339.            empty tag list is returned.
  340.  
  341.    RESULTS
  342.     clone - copy of the original tag list, or NULL if there was not enough
  343.         memory. This tag list must eventually by freed by calling
  344.         FreeTagItems().
  345.  
  346.    SEE ALSO
  347.     <utility/tagitem.h>, AllocateTagItems(), FreeTagItems(),
  348.     RefreshTagItemClones()
  349.  
  350. utility.library/Date2Amiga                         utility.library/Date2Amiga
  351.  
  352.    NAME
  353.     Date2Amiga -- calculate seconds from 01-Jan-1978. (V36)
  354.  
  355.    SYNOPSIS
  356.     seconds = Date2Amiga(date);
  357.     D0                   A0
  358.  
  359.     ULONG Date2Amiga(struct ClockData *);
  360.  
  361.    FUNCTION
  362.     Calculates the number of seconds from 01-Jan-1978 to the date
  363.     specified in the ClockData structure.
  364.  
  365.    INPUTS
  366.     date - pointer to a ClockData structure containing the date of
  367.            interest.
  368.  
  369.    RESULTS
  370.     seconds    - the number of seconds from 01-Jan-1978 to the date specified.
  371.  
  372.    WARNING
  373.     This function does no sanity checking of the data in the ClockData
  374.     structure.
  375.  
  376.    SEE ALSO
  377.     Amiga2Date(), CheckDate()
  378.  
  379. utility.library/FilterTagChanges             utility.library/FilterTagChanges
  380.  
  381.    NAME
  382.     FilterTagChanges -- eliminate tags which specify no change. (V36)
  383.  
  384.    SYNOPSIS
  385.     FilterTagChanges(changeList,originalList,apply);
  386.              A0        A1           D0
  387.  
  388.     VOID FilterTagChanges(struct TagItem *, struct TagItem *, ULONG);
  389.  
  390.    FUNCTION
  391.     This function goes through changeList. For each item found in
  392.     changeList, if the item is also present in originalList, and their
  393.     data values are identical, then the tag is removed from changeList.
  394.     If the two tag's data values are different and the 'apply' value is
  395.     non-zero, then the tag data in originalList will be updated to match
  396.     the value from changeList.
  397.  
  398.    INPUTS
  399.     changeList - list of new tags (may be NULL)
  400.     originalList - a list of existing tags (may be NULL)
  401.     apply - boolean specification as to whether the data values in
  402.         originalList are to be updated to the data values in
  403.         changeList.
  404.  
  405.    EXAMPLE
  406.     Assume you have an attribute list for an object (originalList)
  407.     which looks like this:
  408.  
  409.         {ATTR_Size,  "large"},
  410.         {ATTR_Color, "orange"},
  411.         {ATTR_Shape, "square"}
  412.  
  413.     If you receive a new tag list containing some changes (changeList),
  414.     which looks like this:
  415.  
  416.         {ATTR_Size,  "large"},
  417.         {ATTR_Shape, "triangle"}
  418.  
  419.     If you call FilterTagChanges(), changeList will be modified to
  420.     contain only those attributes which are different from those
  421.     in originalList. All other items will have their tag values set to
  422.     TAG_IGNORE. The resulting changeList will become:
  423.  
  424.         {TAG_IGNORE, "large"},
  425.         {ATTR_Shape, "triangle"}
  426.  
  427.     If 'apply' was set to 0, originalList would be unchanged. If 'apply'
  428.     was non-zero, originalList would be changed to:
  429.  
  430.         {ATTR_Size,  "large"},
  431.         {ATTR_Color, "orange"},
  432.         {ATTR_Shape, "triangle"}
  433.  
  434.    SEE ALSO
  435.     <utility/tagitem.h>, ApplyTagChanges()
  436.  
  437. utility.library/FilterTagItems                 utility.library/FilterTagItems
  438.  
  439.    NAME
  440.     FilterTagItems -- remove selected items from a tag list. (V36)
  441.  
  442.    SYNOPSIS
  443.     numValid = FilterTagItems(tagList,filterArray,logic);
  444.     D0                  A0      A1          D0
  445.  
  446.     ULONG FilterTagItems(struct TagItem *,Tag *,ULONG);
  447.  
  448.    FUNCTION
  449.     Removes tag items from a tag list (by changing ti_Tag to
  450.     TAG_IGNORE) depending on whether its ti_Tag value is
  451.     found in an array of tag values.
  452.  
  453.     If the 'logic' parameter is TAGFILTER_AND, then all items
  454.     not appearing in 'tagArray' are excluded from 'tagList'.
  455.  
  456.     If 'logic' is TAGFILTER_NOT, then items not found in 'tagArray'
  457.     are preserved, and the ones in the array are cast out.
  458.  
  459.    INPUTS
  460.     tagList    - input list of tag items which is to be filtered by having
  461.           selected items changed to TAG_IGNORE.
  462.     filterArray - an array of tag values, terminated by TAG_DONE, as
  463.               specified in the documentation for TagInArray().
  464.     logic - specification whether items in 'tagArray' are to be included
  465.         or excluded in the filtered result.
  466.  
  467.    RESULTS
  468.     numValid - number of valid items left in resulting filtered list.
  469.  
  470.    SEE ALSO
  471.     <utility/tagitem.h>, TagInArray()
  472.  
  473. utility.library/FindNamedObject               utility.library/FindNamedObject
  474.  
  475.    NAME
  476.     FindNamedObject -- find the next object of a given name. (V39)
  477.  
  478.    SYNOPSIS
  479.     object = FindNamedObject(nameSpace, name, lastObject);
  480.     D0                       A0         A1    A2
  481.  
  482.     struct NamedObject *FindNamedObject(struct NamedObject *, STRPTR,
  483.                         struct NamedObject *);
  484.  
  485.    FUNCTION
  486.     Finds an object and adds to the open count of the object. The
  487.     object is guaranteed not to be freed until ReleaseNamedObject() is
  488.     called. The name comparison is caseless, using the current
  489.     locale string comparison routines.
  490.  
  491.     If name is NULL, then all objects will be matched.
  492.  
  493.     If lastObject is non-NULL, it must be an object from the same
  494.     NameSpace found on a previous call to FindNamedObject(). It
  495.     will not be freed by this call. The search will start at the
  496.     node after lastobject, if non-NULL.
  497.  
  498.     nameSpace is the name space from the named object given
  499.     or the root name space if NULL is given.
  500.  
  501.    INPUTS
  502.     nameSpace - the name space to search
  503.     name - the name of the object to search for
  504.     lastObject - the starting point for the search or NULL
  505.  
  506.    RESULT
  507.     object - the first match found, or NULL for no match
  508.  
  509.    SEE ALSO
  510.     ReleaseNamedObject(), <utility/name.h>
  511.  
  512. utility.library/FindTagItem                       utility.library/FindTagItem
  513.  
  514.    NAME
  515.     FindTagItem -- scan a tag list for a specific tag. (V36)
  516.  
  517.    SYNOPSIS
  518.     tag = FindTagItem(tagValue,tagList);
  519.     D0          D0       A0
  520.  
  521.     struct TagItem *FindTagItem(Tag,struct TagItem *);
  522.  
  523.    FUNCTION
  524.     Scans a tag list and returns a pointer to the first item with
  525.     ti_Tag matching the 'tagValue' parameter.
  526.  
  527.    INPUTS
  528.     tagValue - tag value to search for
  529.     tagList    - tag item list to search (may be NULL)
  530.  
  531.    RESULTS
  532.     tag - a pointer to the item with ti_Tag matching 'tagValue' or NULL
  533.           if no match was found.
  534.  
  535.    SEE ALSO
  536.     <utility/tagitem.h>, GetTagData(), PackBoolTags(), NextTagItem()
  537.  
  538. utility.library/FreeNamedObject               utility.library/FreeNamedObject
  539.  
  540.    NAME
  541.     FreeNamedObject -- frees a name object. (V39)
  542.  
  543.    SYNOPSIS
  544.     FreeNamedObject(object);
  545.             A0
  546.  
  547.     VOID FreeNamedObject(struct NamedObject *);
  548.  
  549.    FUNCTION
  550.     Free one of a number of structures used by utility.library.
  551.     The item must not be a member of any NameSpace, and no one
  552.     may have it open other than yourself. If the object also
  553.     contained a NameSpace, that namespace must be empty.
  554.     Any additional space allocated via the datasize parameter
  555.     for AllocNamedObject() is also released.
  556.  
  557.    INPUTS
  558.     object - the object to be freed
  559.  
  560.    SEE ALSO
  561.     AllocNamedObjectA()
  562.  
  563. utility.library/FreeTagItems                     utility.library/FreeTagItems
  564.  
  565.    NAME
  566.     FreeTagItems -- free an allocated tag list. (V36)
  567.  
  568.    SYNOPSIS
  569.     FreeTagItems(tagList);
  570.              A0
  571.  
  572.     VOID FreeTagItems(struct TagItem *);
  573.  
  574.    FUNCTION
  575.     Frees the memory of a TagItem list allocated either by
  576.     AllocateTagItems() or CloneTagItems().
  577.  
  578.    INPUTS
  579.     tagList - list to free, must have been obtained from
  580.           AllocateTagItems() or CloneTagItems() (may be NULL)
  581.  
  582.    SEE ALSO
  583.     <utility/tagitem.h>, AllocateTagItems(), CloneTagItems()
  584.  
  585. utility.library/GetTagData                         utility.library/GetTagData
  586.  
  587.    NAME
  588.     GetTagData -- obtain the data corresponding to a tag. (V36)
  589.  
  590.    SYNOPSIS
  591.     value = GetTagData(tagValue,defaultVal,tagList);
  592.     D0           D0        D1           A0
  593.  
  594.     ULONG GetTagData(Tag,ULONG,struct TagItem *);
  595.  
  596.    FUNCTION
  597.     Searches a tag list for a matching tag, and returns the
  598.     corresponding ti_Data value for the TagItem found. If no match is
  599.     found, this function returns the value passed in as 'default'.
  600.  
  601.    INPUTS
  602.     tagValue - tag value to search for.
  603.     defaultVal - value to be returned if tagValue is not found.
  604.     tagList - the tag list to search.
  605.  
  606.    RESULTS
  607.     value - the ti_Data value for the first matching TagItem, or 'default'
  608.         if a ti_Tag matching 'Tag' is not found.
  609.  
  610.    SEE ALSO
  611.     <utility/tagitem.h>, FindTagItem(), PackBoolTags(), NextTagItem()
  612.  
  613. utility.library/GetUniqueID                       utility.library/GetUniqueID
  614.  
  615.    NAME
  616.     GetUniqueID -- return a relatively unique number. (V39)
  617.  
  618.    SYNOPSIS
  619.     id = GetUniqueID();
  620.     D0
  621.  
  622.     ULONG GetUniqueID(VOID);
  623.  
  624.    FUNCTION
  625.     Returns a unique value each time it is called. This is useful for
  626.     things that need unique ID such as the GadgetHelp ID, etc.
  627.     Note that this is only unique for 4,294,967,295 calls to this
  628.     function. Under normal use this is not a problem.
  629.     This function is safe in interrupts.
  630.  
  631.    RESULT
  632.     id - a 32-bit value that is unique.
  633.  
  634. utility.library/MapTags                               utility.library/MapTags
  635.  
  636.    NAME
  637.     MapTags    -- convert ti_Tag values in a list via map pairing. (V36)
  638.  
  639.    SYNOPSIS
  640.     MapTags(tagList,mapList,mapType);
  641.         A0    A1      D0
  642.  
  643.     VOID MapTags(struct TagItem *,struct TagItem *,ULONG);
  644.  
  645.    FUNCTION
  646.     Apply a "mapping list" mapList to tagList.
  647.  
  648.     If the ti_Tag field of an item in tagList appears as ti_Tag in some
  649.     item in mapList, overwrite ti_Tag with the corresponding ti_Data
  650.     from the map list.
  651.  
  652.     The mapType parameter specifies how the mapping operation is to
  653.     proceed, with the following available types:
  654.  
  655.         MAP_REMOVE_NOT_FOUND
  656.         If a tag in tagList does not appear in the mapList, remove
  657.         it from tagList.
  658.  
  659.         MAP_KEEP_NOT_FOUND
  660.         To have items which do not appear in the mapList survive the
  661.         mapping process as-is.
  662.  
  663.     MapTags() is central to BOOPSI gadget interconnections where you want
  664.     to convert the tag values from one space (the sender) to another (the
  665.     receiver).
  666.  
  667.     The procedure will change the values of the input tag list
  668.     tagList (but not mapList).
  669.  
  670.     You can "filter" a list by passing MAP_REMOVE_NOT_FOUND as mapType,
  671.     and having the data items in mapList equal the corresponding tags.
  672.  
  673.     You can perform the inverse filter ("everything but") by passing
  674.     a mapType of MAP_KEEP_NOT_FOUND, and creating a map item for every tag
  675.     you want to filter out, pairing it with a mapped data value of
  676.     TAG_IGNORE.
  677.  
  678.     For safety and "order independence" of tag item arrays, if you
  679.     attempt to map some tag to the value TAG_DONE, the value TAG_IGNORE
  680.     will be substituted instead.
  681.  
  682.    INPUTS
  683.     tagList    - input list of tag items which is to be mapped to tag values
  684.           as specified in mapList.
  685.     mapList - a "mapping list" tag list which pairs tag values expected to
  686.           appear in tagList with new values to be substituted in the
  687.           ti_Tag fields of tagList (may be NULL)
  688.     mapType - one of the available mapping types as defined in
  689.           <utility/tagitem.h>
  690.  
  691.    EXAMPLE
  692.     /* Consider this source list: */
  693.         struct TagItem list[] =
  694.         {
  695.         {MY_SIZE,     71},
  696.         {MY_WEIGHT,     200},
  697.         {TAG_DONE,    }
  698.            };
  699.  
  700.     /* And the mapping list: */
  701.         struct TagItem map[] =
  702.         {
  703.         {MY_SIZE,     HIS_TALL},
  704.         {TAG_DONE,    }
  705.         };
  706.  
  707.     /* Then after MapTags(list,map,MAP_REMOVE_NOT_FOUND), 'list' will
  708.        become: */
  709.         {HIS_TALL,71},
  710.         {TAG_IGNORE,},
  711.         {TAG_DONE,}
  712.  
  713.     /* Or after MapTags(list,map,MAP_KEEP_NOT_FOUND), 'list' will
  714.        become: */
  715.         {HIS_TALL,  71},
  716.         {MY_WEIGHT, 200},
  717.         {TAG_DONE,  }
  718.  
  719.    BUGS
  720.     Prior to V39, the mapType parameter did not work. The function
  721.     always behaved as if the parameter was set to MAP_KEEP_NOT_FOUND.
  722.  
  723.    SEE ALSO
  724.     <utility/tagitem.h>, ApplyTagChanges(), FilterTagChanges()
  725.  
  726. utility.library/NamedObjectName               utility.library/NamedObjectName
  727.  
  728.    NAME
  729.     NamedObjectName -- return the name of the object. (V39)
  730.  
  731.    SYNOPSIS
  732.     name = NamedObjectName(object);
  733.     D0                     A0
  734.  
  735.     STRPTR NamedObjectName(struct NamedObject *);
  736.  
  737.    FUNCTION
  738.     Returns the name of the object passed in...
  739.     Note that the name string is passed back as just a pointer to
  740.     a read-only name. If the object goes away, so does the name.
  741.  
  742.    INPUTS
  743.     object - the object, may be NULL in which case this function
  744.          returns NULL.
  745.  
  746.    RESULT
  747.     name - pointer to the name string, or NULL if 'object' is NULL.
  748.  
  749.    SEE ALSO
  750.     FindNamedObject(), RemNamedObject()
  751.  
  752. utility.library/NextTagItem                       utility.library/NextTagItem
  753.  
  754.    NAME
  755.     NextTagItem -- iterate through a tag list. (V36)
  756.  
  757.    SYNOPSIS
  758.     tag = NextTagItem(tagItemPtr);
  759.     D0          A0
  760.  
  761.     struct TagItem *NextTagItem(struct TagItem **);
  762.  
  763.    FUNCTION
  764.     Iterates through a tag list, skipping and chaining as dictated by
  765.     system tags. TAG_SKIP will cause it to skip the entry and a number
  766.     of following tags as specified in ti_Data. TAG_IGNORE ignores that
  767.     single entry, and TAG_MORE has a pointer to another array of tags (and
  768.     terminates the current array!). TAG_DONE also terminates the current
  769.     array. Each call returns either the next tagitem you should examine,
  770.     or NULL when the end of the list has been reached.
  771.  
  772.    INPUTS
  773.     tagItemPtr - doubly-indirect reference to a TagItem structure.
  774.              The pointer will be changed to keep track of the
  775.              iteration.
  776.  
  777.    RESULTS
  778.     nextTag    - each TagItem in the array or chain of arrays that should be
  779.           processed according to system tag values defined in
  780.           <utility/tagitem.h>) is returned in turn with successive
  781.           calls.
  782.  
  783.    EXAMPLE
  784.     Iterate(struct TagItem *tags);
  785.     {
  786.     struct TagItem *tstate;
  787.     struct TagItem *tag;
  788.  
  789.         tstate = tags;
  790.         while (tag = NextTagItem(&tstate))
  791.         {
  792.         switch (tag->ti_Tag)
  793.         {
  794.              case TAG1: ...
  795.                    break;
  796.  
  797.              case TAG2: ...
  798.                    break;
  799.  
  800.             ...
  801.         }
  802.         }
  803.        }
  804.  
  805.    WARNING
  806.     Do NOT use the value of *tagItemPtr, but rather use the pointer
  807.     returned by NextTagItem().
  808.  
  809.    SEE ALSO
  810.     <utility/tagitem.h>, GetTagData(), PackBoolTags(), FindTagItem()
  811.  
  812. utility.library/PackBoolTags                     utility.library/PackBoolTags
  813.  
  814.    NAME
  815.     PackBoolTags -- builds a "flag" word from a tag list. (V36)
  816.  
  817.    SYNOPSIS
  818.     flags = PackBoolTags(initialFlags,tagList,boolMap);
  819.     D0             D0          A0      A1
  820.  
  821.     ULONG PackBoolTags(ULONG,struct TagItem *,struct TagItem *);
  822.  
  823.    FUNCTION
  824.     Picks out the boolean tag items in a tag list and converts
  825.     them into bit-flag representations according to a correspondence
  826.     defined by the tag list 'boolMap'.
  827.  
  828.     A boolean tag item is one where only the logical value of
  829.     the ti_Data is relevant. If this field is 0, the value is
  830.     FALSE, otherwise TRUE.
  831.  
  832.    INPUTS
  833.     initialFlags - a starting set of bit-flags which will be changed
  834.                by the processing of TRUE and FALSE boolean tags
  835.                in tagList.
  836.     tagList    - a TagItem list which may contain several tag items defined to
  837.           be boolean by their presence in boolMap. The logical value of
  838.           ti_Data determines whether a tag item causes the bit-flag
  839.           value related by boolMap to be set or cleared in the returned
  840.           flag longword.
  841.     boolMap    - a tag list defining the boolean tags to be recognized, and
  842.           the bit (or bits) in the returned longword that are to be set
  843.           or cleared when a boolean Tag is found to be TRUE or FALSE in
  844.           tagList.
  845.  
  846.    RESULTS
  847.     flags - the accumulated longword of bit-flags, starting with
  848.         initialFlags and modified by each boolean tag item
  849.         encountered.
  850.  
  851.    EXAMPLE
  852.     /* define some nice user tag values ... */
  853.     enum mytags { tag1 = TAG_USER+1, tag2, tag3, tag4, tag5 };
  854.  
  855.     /* this TagItem list defines the correspondence between boolean tags
  856.      * and bit-flag values.
  857.      */
  858.     struct TagItem boolMap[] =
  859.     {
  860.         {tag1,     0x0001},
  861.         {tag2,     0x0002},
  862.         {tag3,     0x0004},
  863.         {tag4,     0x0008},
  864.         {TAG_DONE, }
  865.     };
  866.  
  867.     /* You are probably passed these by some client, and you want
  868.      * to "collapse" the boolean content into a single longword.
  869.      */
  870.  
  871.     struct TagItem boolExample[] =
  872.     {
  873.         {tag1,     TRUE},
  874.         {tag2,     FALSE},
  875.         {tag5,     Irrelevant},
  876.         {tag3,     TRUE},
  877.         {TAG_DONE, }
  878.     };
  879.  
  880.     /* Perhaps 'boolFlags' already has a current value of 0x800002. */
  881.     boolFlags = PackBoolTags(boolFlags,boolExample,boolMap);
  882.  
  883.     /* The resulting new value of 'boolFlags' will be 0x80005. /*
  884.  
  885.    WARNING
  886.     In a case where there is duplication of a tag in tagList, the
  887.     last of the identical tags will hold sway.
  888.  
  889.    SEE ALSO
  890.     <utility/tagitem.h>, GetTagData(), FindTagItem(), NextTagItem()
  891.  
  892. utility.library/PackStructureTags           utility.library/PackStructureTags
  893.  
  894.    NAME
  895.     PackStructureTags -- pack a structure with values from taglist. (V39)
  896.  
  897.    SYNOPSIS
  898.     num = PackStructureTags(pack,packTable,tagList);
  899.     D0                      A0   A1        A2
  900.  
  901.     ULONG PackStructureTags(APTR,ULONG *,struct TagItem *);
  902.  
  903.    FUNCTION
  904.     For each table entry, a FindTagItem() will be done and if the
  905.     matching tag is found in the taglist, the data field will be
  906.     packed into the given structure based on the packtable
  907.     definition.
  908.  
  909.    INPUTS
  910.     pack - a pointer to the data area to fill in.
  911.     packTable - a pointer to the packing information table.
  912.             See <utility/pack.h> for definition and macros.
  913.     tagList - a pointer to the taglist to pack into the structure
  914.  
  915.    RESULTS
  916.     num - the number of tag items packed
  917.  
  918.    SEE ALSO
  919.     <utility/pack.h>, FindTagItem(), UnpackStructureTags()
  920.  
  921. utility.library/RefreshTagItemClones     utility.library/RefreshTagItemClones
  922.  
  923.    NAME
  924.     RefreshTagItemClones -- rejuvenate a clone from the original. (V36)
  925.  
  926.    SYNOPSIS
  927.     RefreshTagItemClones(clone,original)
  928.                  A0       A1
  929.  
  930.     VOID RefreshTagItemClones(struct TagItem *,struct TagItem *);
  931.  
  932.    FUNCTION
  933.     If (and only if) the tag list 'clone' was created from 'original' by
  934.     CloneTagItems(), and if 'original' has not been changed in any way,
  935.     you can reset the clone list to its original state by using this
  936.     function.
  937.  
  938.    INPUTS
  939.     clone - return value from CloneTagItems(original)
  940.     original - a tag list that hasn't changed since CloneTagItems()
  941.  
  942.    SEE ALSO
  943.     <utility/tagitem.h>, CloneTagItems(), AllocateTagItems(),
  944.     FreeTagItems(), ApplyTagChanges()
  945.  
  946. utility.library/ReleaseNamedObject         utility.library/ReleaseNamedObject
  947.  
  948.    NAME
  949.     ReleaseNamedObject -- free a named object. (V39)
  950.  
  951.    SYNOPSIS
  952.     ReleaseNamedObject(object);
  953.                A0
  954.  
  955.     VOID ReleaseNamedObject(struct NamedObject *);
  956.  
  957.    FUNCTION
  958.     Decrements the open count of the object. If the object has been
  959.     removed, and the count goes to 0, the remover will be notified
  960.     that the object is now free.
  961.  
  962.    INPUTS
  963.     object - the object to release.  (No action if NULL)
  964.  
  965.    SEE ALSO
  966.     FindNamedObject(), RemNamedObject()
  967.  
  968. utility.library/RemNamedObject                 utility.library/RemNamedObject
  969.  
  970.    NAME
  971.     RemNamedObject -- remove a named object. (V39)
  972.  
  973.    SYNOPSIS
  974.     RemNamedObject(object, message);
  975.                    A0      A1
  976.  
  977.     VOID RemNamedObject(struct NamedObject *, struct Message *);
  978.  
  979.    FUNCTION
  980.     This function will post a request to release the object
  981.     from whatever NameSpace it is in.  It will reply the message
  982.     when the object is fully removed.  The message.mn_Node.ln_Name
  983.     field will contain the object pointer or NULL if the object
  984.     was removed by another process.
  985.  
  986.     This function will effectively do a ReleaseNamedObject()
  987.     thus you must have "found" the object first.
  988.  
  989.    INPUTS
  990.     object - the object to remove: Must be a valid NamedObject.
  991.     message - message to ReplyMsg() (must be supplied)
  992.  
  993.    RESULT
  994.     The message is replied with the ln_Name field either being
  995.     the object or NULL. If it contains the object, the object
  996.     is completely removed.
  997.  
  998.    SEE ALSO
  999.     AttemptRemNamedObject(), AddNamedObject(), ReleaseNamedObject()
  1000.  
  1001. utility.library/SDivMod32                           utility.library/SDivMod32
  1002.  
  1003.    NAME
  1004.     SDivMod32 -- signed 32 by 32 bit division and modulus. (V36)
  1005.  
  1006.    SYNOPSIS
  1007.     quotient:remainder = SDivMod32(dividend,divisor);
  1008.     D0       D1                    D0       D1
  1009.  
  1010.     LONG:LONG SDivMod32(LONG,LONG);
  1011.  
  1012.    FUNCTION
  1013.     Divides the signed 32 bit dividend by the signed 32 bit divisor
  1014.     and returns a signed 32 bit quotient and remainder.
  1015.  
  1016.    INPUTS
  1017.     dividend - signed 32 bit dividend.
  1018.     divisor - signed 32 bit divisor.
  1019.  
  1020.    RESULTS
  1021.     quotient - signed 32 quotient of the division.
  1022.     remainder - signed 32 remainder of the division.
  1023.  
  1024.    NOTES
  1025.     Unlike other Amiga library function calls, the utility.library
  1026.     32 bit math routines do NOT require A6 to be loaded with a
  1027.     pointer to the library base. A6 can contain anything the application
  1028.     wishes. This is in order to avoid overhead in calling them.
  1029.  
  1030.     In addition, the utility.library math routines preserve all
  1031.     address registers including A0 and A1
  1032.  
  1033.    SEE ALSO
  1034.     SMult32(), UDivMod32(), UMult32(), SMult64(), UMult64()
  1035.  
  1036. utility.library/SMult32                               utility.library/SMult32
  1037.  
  1038.    NAME
  1039.     SMult32 -- signed 32 by 32 bit multiply with 32 bit result. (V36)
  1040.  
  1041.    SYNOPSIS
  1042.     result = SMult32(arg1,arg2);
  1043.     D0               D0   D1
  1044.  
  1045.     LONG SMult32(LONG,LONG);
  1046.  
  1047.    FUNCTION
  1048.     Returns the signed 32 bit result of multiplying arg1 by arg2.
  1049.  
  1050.    INPUTS
  1051.     arg1, arg2 - numbers to multiply
  1052.  
  1053.    RESULTS
  1054.     result - the signed 32 bit result of multiplying arg1 by arg2.
  1055.  
  1056.    NOTES
  1057.     Unlike other Amiga library function calls, the utility.library
  1058.     32 bit math routines do NOT require A6 to be loaded with a
  1059.     pointer to the library base. A6 can contain anything the application
  1060.     wishes. This is in order to avoid overhead in calling them.
  1061.  
  1062.     In addition, the utility.library math routines preserve all
  1063.     address registers including A0 and A1
  1064.  
  1065.    SEE ALSO
  1066.     SDivMod32(), UDivMod32(), UMult32(), SMult64(), UMult64()
  1067.  
  1068. utility.library/SMult64                               utility.library/SMult64
  1069.  
  1070.    NAME
  1071.     SMult64 -- signed 32 by 32 bit multiply with 64 bit result. (V39)
  1072.  
  1073.    SYNOPSIS
  1074.     result = SMult64(arg1,arg2);
  1075.     D0:D1            D0   D1
  1076.  
  1077.     LONG SMult64(LONG,LONG);
  1078.  
  1079.    FUNCTION
  1080.     Returns the signed 64 bit result of multiplying arg1 by arg2.
  1081.  
  1082.    INPUTS
  1083.     arg1, arg2 - numbers to multiply
  1084.  
  1085.    RESULTS
  1086.     result - the signed 64 bit result of multiplying arg1 by arg2.
  1087.  
  1088.    NOTES
  1089.     Unlike other Amiga library function calls, the utility.library
  1090.     32 bit math routines do NOT require A6 to be loaded with a
  1091.     pointer to the library base. A6 can contain anything the application
  1092.     wishes. This is in order to avoid overhead in calling them.
  1093.  
  1094.     In addition, the utility.library math routines preserve all
  1095.     address registers including A0 and A1
  1096.  
  1097.    SEE ALSO
  1098.     SDivMod32(), UDivMod32(), UMult32(), UMult64()
  1099.  
  1100. utility.library/Stricmp                               utility.library/Stricmp
  1101.  
  1102.    NAME
  1103.     Stricmp    -- case-insensitive string comparison. (V37)
  1104.  
  1105.    SYNOPSIS
  1106.     result = Stricmp(string1,string2);
  1107.     D0         A0      A1
  1108.  
  1109.     LONG Stricmp(STRPTR,STRPTR);
  1110.  
  1111.    FUNCTION
  1112.     This function compares two strings, ignoring case using a generic
  1113.     case conversion routine. If the strings have different lengths,
  1114.     the shorter is treated as if it were extended with zeros.
  1115.  
  1116.    INPUTS
  1117.     string1, string2 - strings to be compared
  1118.  
  1119.    RESULTS
  1120.     result - relationship between string1 and string2
  1121.             <0 means string1 < string2
  1122.             =0 means string1 = string2
  1123.             >0 means string1 > string2
  1124.  
  1125.    NOTES
  1126.     Whenever locale.library is installed in a system, this function is
  1127.     replaced by language-specific code. This means that depending on
  1128.     which language the user has currently selected, identical pairs of
  1129.     strings may return different values when passed to this function.
  1130.     This fact must be taken into consideration when using this function.
  1131.  
  1132.    SEE ALSO
  1133.     Strnicmp(), locale.library/StrnCmp()
  1134.  
  1135. utility.library/Strnicmp                             utility.library/Strnicmp
  1136.  
  1137.    NAME
  1138.     Strnicmp -- length-limited case-insensitive string compare. (V37)
  1139.  
  1140.    SYNOPSIS
  1141.     result = Strnicmp(string1,string2,length);
  1142.     D0          A0      A1      D0
  1143.  
  1144.     LONG Strnicmp(STRPTR,STRPTR,LONG);
  1145.  
  1146.    FUNCTION
  1147.     This function compares two strings, ignoring case using a generic
  1148.     case conversion routine. If the strings have different lengths,
  1149.     the shorter is treated as if it were extended with zeros. This function
  1150.     never compares more than 'length' characters.
  1151.  
  1152.    INPUTS
  1153.     string1, string2 - strings to be compared
  1154.     length - maximum number of characters to examine
  1155.  
  1156.    RESULTS
  1157.     result - relationship between string1 and string2
  1158.             <0 means string1 < string2
  1159.             =0 means string1 = string2
  1160.             >0 means string1 > string2
  1161.  
  1162.    NOTES
  1163.     Whenever locale.library is installed in a system, this function is
  1164.     replaced by language-specific code. This means that depending on
  1165.     which language the user has currently selected, identical pairs of
  1166.     strings may return different values when passed to this function.
  1167.     This fact must be taken into consideration when using this function.
  1168.  
  1169.    SEE ALSO
  1170.     Stricmp(), locale.library/StrnCmp()
  1171.  
  1172. utility.library/TagInArray                         utility.library/TagInArray
  1173.  
  1174.    NAME
  1175.     TagInArray -- check if a tag value appears in an array of tag values.
  1176.               (V36)
  1177.  
  1178.    SYNOPSIS
  1179.     result = TagInArray(tagValue,tagArray);
  1180.     D0                D0         A0
  1181.  
  1182.     BOOL TagInArray(Tag,Tag *);
  1183.  
  1184.    FUNCTION
  1185.     Performs a quick scan to see if a tag value appears in an array
  1186.     terminated with TAG_DONE. Returns TRUE if the value is found.
  1187.  
  1188.     The 'tagArray' must be terminated by TAG_DONE. Note that this is an
  1189.     array of tag values, NOT an array of TagItems.
  1190.  
  1191.    INPUTS
  1192.     tagValue - tag value to search array for in array.
  1193.     tagArray - a simple array of tag values terminated by TAG_DONE.
  1194.  
  1195.    RESULTS
  1196.     result - TRUE if tagValue was found in tagArray.
  1197.  
  1198.    SEE ALSO
  1199.     <utility/tagitem.h>, FilterTagItems()
  1200.  
  1201. utility.library/ToLower                               utility.library/ToLower
  1202.  
  1203.    NAME
  1204.     ToLower -- convert a character to lower case. (V37)
  1205.  
  1206.    SYNOPSIS
  1207.     char = ToLower(char);
  1208.     D0           D0
  1209.  
  1210.     UBYTE ToLower(UBYTE);
  1211.  
  1212.    FUNCTION
  1213.     Converts a character to lower case, handling international character
  1214.     sets.
  1215.  
  1216.    INPUTS
  1217.     char - character to be converted.
  1218.  
  1219.    RESULTS
  1220.     char - lower case version of the input character.
  1221.  
  1222.    NOTES
  1223.     Whenever locale.library is installed in a system, this function is
  1224.     replaced by language-specific code. This means that depending on
  1225.     which language the user has currently selected, a given character may
  1226.     return different results when passed to this function. This fact must
  1227.     be taken into consideration when using this function.
  1228.  
  1229.    SEE ALSO
  1230.     ToUpper(), locale.library/ConvToLower()
  1231.  
  1232. utility.library/ToUpper                               utility.library/ToUpper
  1233.  
  1234.    NAME
  1235.     ToUpper -- convert a character to upper case. (V37)
  1236.  
  1237.    SYNOPSIS
  1238.     char = ToUpper(char);
  1239.     D0           D0
  1240.  
  1241.     UBYTE ToUpper(UBYTE);
  1242.  
  1243.    FUNCTION
  1244.     Converts a character to upper case, handling international character
  1245.     sets.
  1246.  
  1247.    INPUTS
  1248.     char - character to be converted.
  1249.  
  1250.    RESULTS
  1251.     char - upper case version of input character.
  1252.  
  1253.    NOTES
  1254.     Whenever locale.library is installed in a system, this function is
  1255.     replaced by language-specific code. This means that depending on
  1256.     which language the user has currently selected, a given character may
  1257.     return different results when passed to this function. This fact must
  1258.     be taken into consideration when using this function.
  1259.  
  1260.    SEE ALSO
  1261.     ToUpper(), locale.library/ConvToLower()
  1262.  
  1263. utility.library/UDivMod32                           utility.library/UDivMod32
  1264.  
  1265.    NAME
  1266.     UDivMod32 -- unsigned 32 by 32 bit division and modulus. (V36)
  1267.  
  1268.    SYNOPSIS
  1269.     quotient:remainder = UDivMod32(dividend,divisor);
  1270.     D0       D1                    D0       D1
  1271.  
  1272.     ULONG:ULONG UDivMod32(ULONG,ULONG);
  1273.  
  1274.    FUNCTION
  1275.     Divides the unsigned 32 bit dividend by the unsigned 32 bit divisor
  1276.     and returns an unsigned 32 bit quotient and remainder.
  1277.  
  1278.    INPUTS
  1279.     dividend - unsigned 32 bit dividend.
  1280.     divisor - unsigned 32 bit divisor.
  1281.  
  1282.    RESULTS
  1283.     quotient - unsigned 32 quotient of the division.
  1284.     remainder - unsigned 32 remainder of the division.
  1285.  
  1286.    NOTES
  1287.     Unlike other Amiga library function calls, the utility.library
  1288.     32 bit math routines do NOT require A6 to be loaded with a
  1289.     pointer to the library base. A6 can contain anything the application
  1290.     wishes. This is in order to avoid overhead in calling them.
  1291.  
  1292.     In addition, the utility.library math routines preserve all
  1293.     address registers including A0 and A1
  1294.  
  1295.    SEE ALSO
  1296.     SDivMod32(), SMult32(), UMult32()
  1297.  
  1298. utility.library/UMult32                               utility.library/UMult32
  1299.  
  1300.    NAME
  1301.     UMult32 -- unsigned 32 by 32 bit multiply with 32 bit result. (V36)
  1302.  
  1303.    SYNOPSIS
  1304.     result = UMult32(arg1,arg2);
  1305.     D0               D0   D1
  1306.  
  1307.     ULONG UMult32(ULONG,ULONG);
  1308.  
  1309.    FUNCTION
  1310.     Returns the unsigned 32 bit result of multiplying arg1 by arg2.
  1311.  
  1312.    INPUTS
  1313.     arg1, arg2 - numbers to multiply
  1314.  
  1315.    RESULTS
  1316.     result - the unsigned 32 bit result of multiplying arg1 by arg2.
  1317.  
  1318.    NOTES
  1319.     Unlike other Amiga library function calls, the utility.library
  1320.     32 bit math routines do NOT require A6 to be loaded with a
  1321.     pointer to the library base. A6 can contain anything the application
  1322.     wishes. This is in order to avoid overhead in calling them.
  1323.  
  1324.     In addition, the utility.library math routines preserve all
  1325.     address registers including A0 and A1
  1326.  
  1327.    SEE ALSO
  1328.     SDivMod32(), SMult32(), UDivMod32(), SMult64(), UMult64()
  1329.  
  1330. utility.library/UMult64                               utility.library/UMult64
  1331.  
  1332.    NAME
  1333.     UMult64 -- unsigned 32 by 32 bit multiply with 64 bit result. (V39)
  1334.  
  1335.    SYNOPSIS
  1336.     result = UMult64(arg1,arg2);
  1337.     D0:D1               D0   D1
  1338.  
  1339.     ULONG UMult64(ULONG,ULONG);
  1340.  
  1341.    FUNCTION
  1342.     Returns the unsigned 64 bit result of multiplying arg1 by arg2.
  1343.  
  1344.    INPUTS
  1345.     arg1, arg2 - numbers to multiply
  1346.  
  1347.    RESULTS
  1348.     result - the unsigned 64 bit result of multiplying arg1 by arg2.
  1349.  
  1350.    NOTES
  1351.     Unlike other Amiga library function calls, the utility.library
  1352.     32 bit math routines do NOT require A6 to be loaded with a
  1353.     pointer to the library base. A6 can contain anything the application
  1354.     wishes. This is in order to avoid overhead in calling them.
  1355.  
  1356.     In addition, the utility.library math routines preserve all
  1357.     address registers including A0 and A1
  1358.  
  1359.    SEE ALSO
  1360.     SDivMod32(), SMult32(), UDivMod32(), SMult64()
  1361.  
  1362. utility.library/UnpackStructureTags       utility.library/UnpackStructureTags
  1363.  
  1364.    NAME
  1365.     UnpackStructureTags -- unpack a structure to values in taglist. (V39)
  1366.  
  1367.    SYNOPSIS
  1368.     num = UnpackStructureTags(pack,packTable,tagList);
  1369.     D0                        A0   A1        A2
  1370.  
  1371.     ULONG UnpackStructureTags(APTR,ULONG *,struct TagItem *);
  1372.  
  1373.    FUNCTION
  1374.     For each table entry, a FindTagItem() will be done and if the
  1375.     matching tag is found in the taglist, the data in the structure
  1376.     will be placed into the memory pointed to by the tag's ti_Data.
  1377.     ti_Data *must* point to a LONGWORD.
  1378.  
  1379.    INPUTS
  1380.     pack - a pointer to the data area to be unpacked
  1381.     packTable - a pointer to the packing information table.
  1382.             See <utility/pack.h> for definition and macros
  1383.     tagList - a pointer to the taglist to unpack into
  1384.  
  1385.    RESULTS
  1386.     num - the number of tag items unpacked
  1387.  
  1388.    SEE ALSO
  1389.     <utility/pack.h>, FindTagItem(), PackStructureTags()
  1390.  
  1391.