You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+7-7
Original file line number
Diff line number
Diff line change
@@ -28,13 +28,13 @@ Despite AutoHotKey (1.1.28 at the moment) supporting Arrays and Function Objects
28
28
* unshift
29
29
30
30
### Installation
31
-
There are two options for using importing these functions, either as global functions stored in **array_.ahk** or by extending the built-in Array object stored in **array_base.ahk**. The sorting function in both files depends on the object defined in **array_quicksort.ahk**. This object must be present for sorting to work properly.
31
+
There are two options for using these functions, either as global functions stored in **array_.ahk** or by extending the built-in Array object with the object stored in **array_base.ahk**. The sorting function in both files depend on the object defined in **array_quicksort.ahk**. This object must be present for sorting to work properly.
32
32
33
-
Some dislike extending built-in objects. For that reason **array_base.ahk**'s base object does not automatically extend Array. Extending Array, or a custom collections object, is left to the implementer (See _**Extend Array Object**_ below).
33
+
Some dislike extending built-in objects. For that reason **array_base.ahk**'s object does not automatically extend Array. Extending Array, or a custom collections object, is left to the implementer (See _**As Array Object Extension**_ below).
34
34
35
35
### Usage
36
36
_**As Global Functions**_
37
-
**array_.ahk** contains each ported function as a global function declaration in the form of *array_<func>*. The input array is always located in the first parameter position.
37
+
**array_.ahk** contains each ported function as a global function declaration in the form of *array_\<func\>*. The input array is always located in the first parameter position.
38
38
39
39
Usage: `array_<fn>(array[, params*])`
40
40
```autohotkey
@@ -57,9 +57,9 @@ get_name(obj) {
57
57
```
58
58
59
59
_**As Array Object Extension**_
60
-
**array_base.ahk** contains each ported function as a method of a single object.
60
+
**array_base.ahk** contains each ported function as a method of the object *_Array*. The most intuitive use case is extending the built-in Array object (assigning it's base object). Some environments avoid modifying built-ins and prefer using custom collection objects.
61
61
62
-
Usage: `Array.<fn>([params*])`
62
+
Usage: `Array.<fn>([params*])` (Assuming Array's base object was extended)
63
63
```autohotkey
64
64
#include array_base.ahk
65
65
@@ -88,8 +88,8 @@ get_name(obj) {
88
88
_**Sorting**_
89
89
**array_quicksort.ahk** contains the sorting logic. The quicksort behavior is wrapped in a callable function object to avoid cluttering the global namespace.
90
90
91
-
Indirect Usage: `array_sort(array, [params*])` or `array.sort([params*])`
92
-
Direct Usage: `Array_Quicksort.Call(array, [params*])`
91
+
Indirect Usage: `array_sort(Array, [params*])` or `Array.sort([params*])`
92
+
Direct Usage: `Array_Quicksort.Call(Array, [params*])`
0 commit comments