update to arrayReplacesArglist4.diff
[nedit-bw.git] / enhanced-hooks-docs.patch
blobc3ad4bf7433ac2a3e1e2a12f0bd6ff581ce56d6c
1 ---
3 doc/help.etx | 61 +++++++++++++++++++++++++++++++++++++----------------------
4 1 files changed, 39 insertions(+), 22 deletions(-)
6 diff --quilt old/doc/help.etx new/doc/help.etx
7 --- old/doc/help.etx
8 +++ new/doc/help.etx
9 @@ -2750,15 +2750,15 @@ Macro Subroutines
11 **replace_in_string( string, search_for, replace_with [, type, "copy"] )**
12 Replaces all occurrences of a search string in a string with a replacement
13 string. Arguments are 1: string to search in, 2: string to search for, 3:
14 replacement string. There are two optional arguments. One is a search type,
15 - either "literal", "case", "word", "caseWord", "regex", or "regexNoCase".
16 - The default search type is "literal". If the optional "copy" argument is
17 - specified, a copy of the input string is returned when no replacements were
18 - performed. By default an empty string ("") will be returned in this case.
19 - Returns a new string with all of the replacements done.
20 + either "literal", "case", "word", "caseWord", "regex", "regexNoCase", or
21 + "regexSmartCase". The default search type is "literal". If the optional
22 + "copy" argument is specified, a copy of the input string is returned when no
23 + replacements were performed. By default an empty string ("") will be returned
24 + in this case. Returns a new string with all of the replacements done.
26 **replace_range( start, end, string )**
27 Replaces all the text between two positions in the current window. If the
28 cursor position is between start and end it will be set to start.
30 @@ -2776,23 +2776,24 @@ Macro Subroutines
31 Searches silently in a window without dialogs, beeps, or changes to the
32 selection. Arguments are: 1: string to search for, 2: starting position.
33 Optional arguments may include the strings: "wrap" to make the search wrap
34 around the beginning or end of the string, "backward" or "forward" to change
35 the search direction ("forward" is the default), "literal", "case", "word",
36 - "caseWord", "regex", or "regexNoCase" to change the search type (default is
37 - "literal"). Returns the starting position of the match, or -1 if nothing
38 - matched. Also returns the ending position of the match in $search_end.
39 + "caseWord", "regex", "regexNoCase", or "regexSmartCase" to change the search
40 + type (default is "literal"). Returns the starting position of the match, or
41 + -1 if nothing matched. Also returns the ending position of the match in
42 + $search_end.
44 **search_string( string, search_for, start [, search_type, direction] )**
45 Built-in macro subroutine for searching a string. Arguments are 1: string to
46 search in, 2: string to search for, 3: starting position. Optional arguments
47 may include the strings: "wrap" to make the search wrap around the beginning
48 or end of the string, "backward" or "forward" to change the search direction
49 ("forward" is the default), "literal", "case", "word", "caseWord", "regex",
50 - or "regexNoCase" to change the search type (default is "literal"). Returns
51 - the starting position of the match, or -1 if nothing matched. Also returns
52 - the ending position of the match in $search_end.
53 + "regexNoCase", or "regexSmartCase" to change the search type (default is
54 + "literal"). Returns the starting position of the match, or -1 if nothing
55 + matched. Also returns the ending position of the match in $search_end.
57 **select( start, end )**
58 Selects (with the primary selection) text in the current buffer between a
59 starting and ending position.
61 @@ -2874,14 +2875,14 @@ Macro Subroutines
63 **typeof( value )**
64 Returns a string indicating the type of a macro value. The value can be
65 any NEdit macro language value except for the return value of functions
66 without a return value. Examples:
67 - typeof(2) # -> "INTEGER"
68 - typeof($empty_array) # -> "ARRAY"
69 - typeof(get_range(10, 20)) # -> "STRING"
70 - typeof(myArray["doesnotexist"]) # -> "UNDEFINED"
71 +* typeof(2) # -> "INTEGER"
72 +* typeof($empty_array) # -> "ARRAY"
73 +* typeof(get_range(10, 20)) # -> "STRING"
74 +* typeof(myArray["doesnotexist"]) # -> "UNDEFINED"
76 **valid_number( string )**
77 Returns 1 if the string can be converted to a number without error
78 following the same rules that the implicit conversion would. Otherwise 0.
80 @@ -3350,11 +3351,12 @@ Action Routines
82 ~search-direction~
83 Either "forward" or "backward".
85 ~search-type~ Either "literal", "case", "word",
86 - "caseWord", "regex", or "regexNoCase".
87 + "caseWord", "regex", "regexNoCase",
88 + or "regexSmartCase".
90 ~search-wrap~ Either "wrap" or "nowrap".
92 ~shell-menu-item-name~
93 Name of the command exactly as specified in
94 @@ -3772,16 +3774,31 @@ Hooks
95 simply skipped.
97 **file_open_hook()**
98 Called when an existing file is opened.
100 -..**file_name_hook(filename)**
101 -.. Called before NEdit opens a file using a certain name. The parameter is
102 -.. the filename NEdit intends to open.
104 -.. Return a string to use instead of the original filename. Return 0 to tell
105 -.. NEdit to use the original filename.
106 +**file_name_hook(~filename~)**
107 + Called before NEdit opens a file using a certain name. The parameter is
108 + the filename NEdit intends to open.
110 + Return a string to use instead of the original filename. Return 0 to tell
111 + NEdit to use the original filename.
113 +**post_save_hook(~filename~)**
114 + Called after an file was closed.
116 +**cursor_moved_hook()**
117 + Called when the was cursor moved.
119 +**modified_hook()**
120 + Called when the text buffer changed.
122 +**focus_hook()**
123 + Called when a document gets the input focus.
125 +**losing_focus_hook()**
126 + Called before a document lost the input focus.
128 ----------------------------------------------------------------------
130 Customizing
131 ===========