aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2015-10-01 10:09:57 -0400
committermitchell <70453897+667e-11@users.noreply.github.com>2015-10-01 10:09:57 -0400
commit25117b668b41ccec995809e7b6ff6e9cf4e0d825 (patch)
tree79558ad3330164859cb13a0c1938c9a1e72ef0b7 /modules
parent74e5eba1e75d758deaf0c71735c8167dbe489a55 (diff)
downloadtextadept-25117b668b41ccec995809e7b6ff6e9cf4e0d825.tar.gz
textadept-25117b668b41ccec995809e7b6ff6e9cf4e0d825.zip
Updated Lua autocompletion and documentation; modules/lua/api
Diffstat (limited to 'modules')
-rw-r--r--modules/lua/api2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/lua/api b/modules/lua/api
index 16120cf7..d48d5396 100644
--- a/modules/lua/api
+++ b/modules/lua/api
@@ -1055,7 +1055,7 @@ snippets _G.snippets (table)\nMap of snippet triggers with their snippet text, w
snippets textadept.snippets (module)\nSnippets for Textadept.
sort table.sort(list [, comp])\nSorts list elements in a given order, *in-place*, from `list[1]` to\n`list[#list]`. If `comp` is given, then it must be a function that receives\ntwo list elements and returns true when the first element must come before\nthe second in the final order (so that `not comp(list[i+1],list[i])` will be\ntrue after the sort). If `comp` is not given, then the standard Lua operator\n`<` is used instead.\n\nThe sort algorithm is not stable; that is, elements considered equal by the\ngiven order may have their relative positions changed by the sort.
space lexer.space (pattern)\nA pattern that matches any whitespace character ('\t', '\v', '\f', '\n',\n'\r', space).
-spawn _G.spawn(argv, cwd, stdout_cb, stderr_cb, exit_cb)\nSpawns an interactive child process *argv* in a separate thread, returning\na handle to that process.\nAt the moment, only the Win32 terminal version spawns processes in the same\nthread.\n@param argv A command line string containing the program's name followed by\n arguments to pass to it. `PATH` is searched for program names.\n@param cwd Optional current working directory (cwd) for the child\n process. The default value is `nil`, which inherits the parent's cwd.\n@param stdout_cb Optional Lua function that accepts a string parameter for a\n block of standard output read from the child. Stdout is read asynchronously\n in 1KB or 0.5KB blocks (depending on the platform), or however much data is\n available at the time.\n At the moment, only the Win32 terminal version sends all output, whether it\n be stdout or stderr, to this callback after the process finishes.\n@param stderr_cb Optional Lua function that accepts a string parameter for a\n block of standard error read from the child. Stderr is read asynchronously\n in 1KB or 0.5kB blocks (depending on the platform), or however much data is\n available at the time.\n@param exit_cb Optional Lua function that is called when the child process\n finishes. The child's exit status is passed.\n@usage spawn('lua buffer.filename', nil, print)\n@usage proc = spawn('lua -e "print(io.read())"', nil, print)\n proc:write('foo\n')\n@return proc
+spawn _G.spawn(argv, cwd, env, stdout_cb, stderr_cb, exit_cb)\nSpawns an interactive child process *argv* in a separate thread, returning\na handle to that process.\nAt the moment, only the Win32 terminal version spawns processes in the same\nthread.\n@param argv A command line string containing the program's name followed by\n arguments to pass to it. `PATH` is searched for program names.\n@param cwd Optional current working directory (cwd) for the child\n process. The default value is `nil`, which inherits the parent's cwd.\n@param env Optional list of environment variables for the child process.\n Each element in the list is a 'KEY=VALUE' string. The default value is\n `nil`, which inherits the parent's environment.\n This parameter should be omitted completely instead of specifying `nil`.\n@param stdout_cb Optional Lua function that accepts a string parameter for a\n block of standard output read from the child. Stdout is read asynchronously\n in 1KB or 0.5KB blocks (depending on the platform), or however much data is\n available at the time.\n At the moment, only the Win32 terminal version sends all output, whether it\n be stdout or stderr, to this callback after the process finishes.\n@param stderr_cb Optional Lua function that accepts a string parameter for a\n block of standard error read from the child. Stderr is read asynchronously\n in 1KB or 0.5kB blocks (depending on the platform), or however much data is\n available at the time.\n@param exit_cb Optional Lua function that is called when the child process\n finishes. The child's exit status is passed.\n@usage spawn('lua buffer.filename', nil, print)\n@usage proc = spawn('lua -e "print(io.read())"', nil, print)\n proc:write('foo\n')\n@return proc or nil plus an error message on failure
split view.split(view, vertical)\nSplits the view into top and bottom views (unless *vertical* is `true`),\nfocuses the new view, and returns both the old and new views.\nIf *vertical* is `false`, splits the view vertically into left and\nright views.\nEmits a `VIEW_NEW` event.\n@param view The view to split.\n@param vertical Optional flag indicating whether or not to split the view\n vertically. The default value is `false`, for horizontal.\n@return old view and new view.\n@see events.VIEW_NEW
sqrt math.sqrt(x)\nReturns the square root of `x`. (You can also use the expression `x^0.5`\nto compute this value.)
standard_dropdown ui.dialogs.standard_dropdown(options)\nPrompts the user with a drop-down item selection dialog defined by dialog\noptions table *options* and with localized "Ok" and "Cancel" buttons,\nreturning the selected button's index along with the selected item's index.\nIf *options*.`string_output` is `true`, returns the selected button's label\nalong with the selected item's text.\nIf the dialog closed due to *options*.`exit_onchange`, returns `4` along with\neither the selected item's index or its text. If the dialog timed out,\nreturns `0` or `"timeout"`. If the user canceled the dialog, returns `-1` or\n`"delete"`.\n@param options Table of key-value option pairs for the drop-down dialog.\n\n * `title`: The dialog's title text.\n * `text`: The dialog's main message text.\n * `items`: The list of string items to show in the drop-down.\n * `no_cancel`: Do not display the "Cancel" button. The default value is\n `false`.\n * `exit_onchange`: Close the dialog after selecting a new item. The default\n value is `false`.\n * `select`: The index of the initially selected list item. The default\n value is `1`.\n * `string_output`: Return the selected button's label (instead of its\n index) and the selected item's text (instead of its index). If no item\n was selected, returns the dialog's exit status (instead of its exit\n code). The default value is `false`.\n * `width`: The dialog's pixel width.\n * `height`: The dialog's pixel height.\n * `float`: Show the dialog on top of all desktop windows. The default value\n is `false`.\n * `timeout`: the integer number of seconds the dialog waits for the user to\n select a button before timing out. Dialogs do not time out by default.\n@return selected button or exit code, selected item