aboutsummaryrefslogtreecommitdiff
path: root/core/.command_entry.lua
diff options
context:
space:
mode:
Diffstat (limited to 'core/.command_entry.lua')
-rw-r--r--core/.command_entry.lua38
1 files changed, 30 insertions, 8 deletions
diff --git a/core/.command_entry.lua b/core/.command_entry.lua
index c1a06f45..09622b8d 100644
--- a/core/.command_entry.lua
+++ b/core/.command_entry.lua
@@ -3,16 +3,38 @@
-- global textadept.command_entry table.
---
--- Textadept's Lua command entry.
--- [Dummy file]
+-- Textadept's Command entry.
module('textadept.command_entry')
----
--- Textadept's Lua command entry table.
--- @class table
--- @name textadept.command_entry
--- @field entry_text The text in the entry.
-command_entry = { entry_text = nil }
+-- Markdown:
+-- ## Fields
+--
+-- * `entry_text`: The text in the entry.
+--
+-- ## Overview
+--
+-- Access to the Lua state is available through this command entry. It is useful
+-- for debugging, inspecting, and entering buffer or view commands. If you try
+-- cause instability in Textadept's Lua state, you might very well succeed. Be
+-- careful.
+--
+-- Tab-completion for functions, variables, tables, etc. is available. Press the
+-- `Tab` key to display a list of available completions. Use the arrow keys to
+-- make a selection and press `Enter` to insert it.
+--
+-- Note: Use [`textadept.print()`][textadept_print] instead of the global
+-- `print()` function. The former prints to a new buffer, the latter to standard
+-- out (`STDOUT`).
+--
+-- [textadept_print]: ../modules/textadept.html#print
+--
+-- ## Extending
+--
+-- You can extend the command entry to do more than enter Lua commands. An
+-- example of this is [incremental search][inc_search]. See `core/ext/find.lua`
+-- for the implementation.
+--
+-- [inc_search]: ../modules/textadept.find.html#incremental
--- Focuses the command entry.
function focus() end