# _M.lua

The lua module.
It provides utilities for editing Lua code.

## Key Bindings

+ `Ctrl+L, M` (`⌘L, M` on Mac OSX | `M-L, M` in curses)
  Open this module for editing.
+ `.`
  Show an autocompletion list of fields for the symbol behind the caret.
+ `:`
  Show an autocompletion list of functions for the symbol behind the caret.
+ `Shift+Enter` (`⇧↩` | `S-Enter`)
  Autocomplete an `if`, `while`, `for`, etc. control structure with the `end`
  keyword.

- - -

## Fields

- - -

<a id="sense"></a>
### `sense` 

The Lua [Adeptsense](_M.textadept.adeptsense.html).
  It loads user tags from *`_USERHOME`/modules/lua/tags* and user apidocs
  from *`_USERHOME`/modules/lua/api*.

- - -


## Functions

- - -

<a id="try_to_autocomplete_end"></a>
### `try_to_autocomplete_end`()

Tries to autocomplete control structures like `if`, `while`, `for`, etc. with
the `end` keyword.

See also:

* [`control_structure_patterns`](#control_structure_patterns)

- - -


## Tables

- - -

<a id="_G.keys.lua"></a>
### `_G.keys.lua`

Container for Lua-specific key bindings.

- - -

<a id="_G.snippets.lua"></a>
### `_G.snippets.lua`

Container for Lua-specific snippets.

- - -

<a id="control_structure_patterns"></a>
### `control_structure_patterns`

List of patterns for auto-`end` completion for control structures.

See also:

* [`try_to_autocomplete_end`](#try_to_autocomplete_end)

- - -

