diff options
Diffstat (limited to 'core')
-rw-r--r-- | core/._M.luadoc | 23 | ||||
-rw-r--r-- | core/.buffer.luadoc | 3 | ||||
-rw-r--r-- | core/init.lua | 4 | ||||
-rw-r--r-- | core/keys.lua | 10 |
4 files changed, 19 insertions, 21 deletions
diff --git a/core/._M.luadoc b/core/._M.luadoc index 9eb70f64..fada7185 100644 --- a/core/._M.luadoc +++ b/core/._M.luadoc @@ -12,18 +12,17 @@ -- script. However, the script may load additional Lua files present in the -- directory. (For an example, see *modules/textadept/init.lua*.) -- --- Loaded modules, regardless of whether they are generic or language-specific, --- persist in Textadept's Lua State; Textadept never unloads them. Therefore, --- modules should define functions or variables within the module itself, not --- globally. --- --- ### Language-Specific --- --- To fully take advantage of Textadept's features, language-specific modules --- should have at a minimum: a block comment string, run and/or compile --- commands, an event handler for setting buffer properties like indentation, --- and if possible, an Adeptsense. Optional features are extra snippets and --- commands and a context menu. +-- Loaded modules, even language modules, persist in Textadept's Lua State; +-- Textadept never unloads them. Therefore, modules should define functions or +-- variables within the module itself, not globally. +-- +-- ### Language Modules +-- +-- To fully take advantage of Textadept's features, language modules should have +-- at a minimum: a block comment string, run and/or compile commands, an event +-- handler for setting buffer properties like indentation, and if possible, an +-- Adeptsense. Optional features are extra snippets and commands and a context +-- menu. -- -- #### Block Comment -- diff --git a/core/.buffer.luadoc b/core/.buffer.luadoc index 2b925504..3f39956c 100644 --- a/core/.buffer.luadoc +++ b/core/.buffer.luadoc @@ -2928,8 +2928,7 @@ function get_lexer(buffer, current) end --- -- Sets the name of the lexer used by the buffer to *lang* or the auto-detected --- language and then loads the appropriate language-specific module if the --- module exists. +-- language and then loads the appropriate language module if the module exists. -- @param buffer The global buffer. -- @param lang Optional string language name to set. If `nil`, attempts to -- auto-detect the buffer's language. diff --git a/core/init.lua b/core/init.lua index 04c3dce7..8ce4d16b 100644 --- a/core/init.lua +++ b/core/init.lua @@ -101,8 +101,8 @@ local quit --- -- Resets the Lua state by reloading all initialization scripts. --- Language-specific modules for opened files are NOT reloaded. Re-opening the --- files that use them will reload those modules instead. +-- Language modules for opened files are NOT reloaded. Re-opening the files that +-- use them will reload those modules instead. -- This function is useful for modifying user scripts (such as -- *~/.textadept/init.lua* and *~/.textadept/modules/textadept/keys.lua*) on -- the fly without having to restart Textadept. `arg` is set to `nil` when diff --git a/core/keys.lua b/core/keys.lua index f7c2026e..50ad2948 100644 --- a/core/keys.lua +++ b/core/keys.lua @@ -20,9 +20,9 @@ local M = {} -- global table. This means if there are two commands with the same key -- sequence, Textadept runs the one specific to the current lexer. However, if -- the command returns the boolean value `false`, Textadept also runs the --- lower-priority command. (This is useful for language-specific modules to --- override commands like Adeptsense autocompletion, but fall back to word --- autocompletion if the first command fails.) +-- lower-priority command. (This is useful for language modules to override +-- commands like Adeptsense autocompletion, but fall back to word autocompletion +-- if the first command fails.) -- -- ## Key Sequences -- @@ -95,7 +95,7 @@ local M = {} -- ## Key Chains -- -- Key chains are a powerful concept. They allow you to assign multiple key --- bindings to one key sequence. Language-specific modules +-- bindings to one key sequence. Language modules -- [use key chains](#LANGUAGE_MODULE_PREFIX) for their functions. By default, -- the `Esc` (`⎋` on Mac OSX | `Esc` in curses) key cancels a key chain, but you -- can redefine it via [`CLEAR`](#CLEAR). An example key chain looks like: @@ -111,7 +111,7 @@ local M = {} -- The default value is `'esc'` for the `Esc` (`⎋` on Mac OSX | `Esc` in -- curses) key. -- @field LANGUAGE_MODULE_PREFIX (string) --- The starting key of the key chain reserved for language-specific modules. +-- The starting key of the key chain reserved for language modules. -- The default value is `'cl'` on platforms other than Mac OSX, `'ml'` -- otherwise. Equivalent to `Ctrl+L` (`⌘L` on Mac OSX | `M-L` in curses). -- @field MODE (string) |