aboutsummaryrefslogtreecommitdiff
path: root/doc/07_Modules.md
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2013-07-08 16:09:29 -0400
committermitchell <70453897+667e-11@users.noreply.github.com>2013-07-08 16:09:29 -0400
commit6600c4f959bb4ea91a2f632bfc5375f7e75e40c4 (patch)
tree3c108fa22c3c6d6d32ea7beef55039bd845149d5 /doc/07_Modules.md
parent7d1f21b44479d8b4484f8e27872eafd203b0e727 (diff)
downloadtextadept-6600c4f959bb4ea91a2f632bfc5375f7e75e40c4.tar.gz
textadept-6600c4f959bb4ea91a2f632bfc5375f7e75e40c4.zip
Renamed "language-specific" modules to just "language modules" in documentation.
Diffstat (limited to 'doc/07_Modules.md')
-rw-r--r--doc/07_Modules.md76
1 files changed, 35 insertions, 41 deletions
diff --git a/doc/07_Modules.md b/doc/07_Modules.md
index 297a0ba5..02b6bf0c 100644
--- a/doc/07_Modules.md
+++ b/doc/07_Modules.md
@@ -1,46 +1,40 @@
# Modules
-Most of Textadept's functionality comes from Lua modules. Essentially there are
-two classes of module: generic and language-specific. A generic module provides
-features for all programming languages while a language-specific module provides
-features for a specific programming language.
+Most of Textadept's functionality comes from Lua modules loaded on startup. An
+example is the [textadept module][] which implements most of Textadept's
+functionality (find & replace, key bindings, menus, snippets, etc.) See the
+[preferences][] page for instructions on how to load your own modules on
+startup.
-## Generic
-
-Generic modules have a broad scope and are usually available for programming in
-all languages or writing plain-text. An example is the [textadept module][]
-which implements most of Textadept's functionality (find & replace, key
-bindings, menus, snippets, etc.). In general, Textadept should load these kinds
-of modules on startup. See the [preferences][] page for instructions on how to
-do this.
+Textadept also recognizes a special kind of module: a language module. Language
+modules provide functionality specific their respective programming languages.
[textadept module]: api/_M.textadept.html
[preferences]: 08_Preferences.html#Loading.Modules
-## Language-Specific
+## Language Modules
-Language-specific modules have a scope limited to a single programming language.
-The module's name matches the language's lexer in the *lexers/* directory.
-Textadept automatically loads the module when editing source code in that
-particular language. In addition to the source code editing features discussed
-previously, these kinds of modules typically also define shell commands for
-running and compiling code, indentation settings, custom key bindings, and
-perhaps a custom context menu. The manual discusses these features below.
+Language modules have a scope limited to a single programming language. The
+module's name matches the language's lexer in the *lexers/* directory. Textadept
+automatically loads the module when editing source code in that particular
+language. In addition to the source code editing features discussed previously,
+these kinds of modules typically also define shell commands for running and
+compiling code, indentation settings, custom key bindings, and perhaps a custom
+context menu. The manual discusses these features below.
### Compile and Run
-Most language-specific modules specify commands that compile and/or run the code
-in the current file. Pressing `Ctrl+Shift+R` (`⌘⇧R` on Mac OSX | `M-^R` in
-curses) executes the command for compiling code and `Ctrl+R` (`⌘R` | `^R`)
-executes the command for running code. A new buffer shows the output from the
-command and marks any recognized errors. Pressing `Ctrl+Alt+E` (`^⌘E` | `M-X`)
-attempts to jump to the source of the next recognized error and
-`Ctrl+Alt+Shift+E` (`^⌘⇧E` | `M-S-X`) attempts to jump to the previous one.
-Double-clicking on errors also jumps to their sources. Note: In order for these
-features to work, the language you are working with must have its compile and
-run commands and error format defined. If the language-specific module does not
-exist or does not [define][] commands or an error format, you can do so
-[manually][] in your [user-init file][].
+Most language modules specify commands that compile and/or run the code in the
+current file. Pressing `Ctrl+Shift+R` (`⌘⇧R` on Mac OSX | `M-^R` in curses)
+executes the command for compiling code and `Ctrl+R` (`⌘R` | `^R`) executes the
+command for running code. A new buffer shows the output from the command and
+marks any recognized errors. Pressing `Ctrl+Alt+E` (`^⌘E` | `M-X`) attempts to
+jump to the source of the next recognized error and `Ctrl+Alt+Shift+E` (`^⌘⇧E` |
+`M-S-X`) attempts to jump to the previous one. Double-clicking on errors also
+jumps to their sources. Note: In order for these features to work, the language
+you are working with must have its compile and run commands and error format
+defined. If the language module does not exist or does not [define][] commands
+or an error format, you can do so [manually][] in your [user-init file][].
![Runtime Error](images/runerror.png)
@@ -51,27 +45,27 @@ exist or does not [define][] commands or an error format, you can do so
### Buffer Properties
Some programming languages have style guidelines for indentation and/or line
-endings which differ from Textadept's defaults. In this case, language-specific
-modules [set][] these preferences. You can do so manually with your
+endings which differ from Textadept's defaults. In this case, language modules
+[set][] these preferences. You can do so manually with your
[language module preferences][].
[set]: api/_M.html#Buffer.Properties
-[language module preferences]: 08_Preferences.html#Language-Specific
+[language module preferences]: 08_Preferences.html#Language
### Key Bindings
-Most language-specific modules assign a set of key bindings to
-[custom commands][]. The module's [LuaDoc][] or code lists which key bindings
-map to which commands. The `Ctrl+L` (`⌘L` on Mac OSX | `M-L` in curses) key
-chain prefix typically houses them.
+Most language modules assign a set of key bindings to [custom commands][]. The
+module's [LuaDoc][] or code lists which key bindings map to which commands. The
+`Ctrl+L` (`⌘L` on Mac OSX | `M-L` in curses) key chain prefix typically houses
+them.
[custom commands]: api/_M.html#Commands
[LuaDoc]: api/index.html
### Context Menu
-Some language-specific modules add extra actions to the context menu.
-Right-click inside the view to bring up this menu.
+Some language modules add extra actions to the context menu. Right-click inside
+the view to bring up this menu.
## Getting Modules