Editor support may include syntax highlighting, auto-formatting, syntax checking, build and debug integration, etc.
The following editors have some Lua support (at least highlighting or formatting) out of the box:
- [LuaEdit IDE] (Win32, freeware)
- Completion proposal
- Syntax highlighting
- Watch, Globals, Locals, Call Stack, Lua Stack, etc
- Debugger for Lua 5.0.2
- [Vim] (most platforms)
- Vim comes with syntax highlighting and indentation for Lua. Vim 7 supports Lua 5.1
- [ftp.vim.org] You can download the lastest version of the syntax and indent files here.
- [luarefvim] is the Lua reference manual for Vim.
- [lua-support] Lua-IDE for Vim.
- [Scintilla/SciTE] (Win32/GTK+)
- Lua syntax highlighting (4.0, 5.0, 5.1), including nested literal strings and block comments.
- Lua scripting extension [1]
- SciteScripts is a community area for disseminating Lua extension scripts
- [lua5api.zip] Lua 5 C API and Lua functions for SciTE calltips (with optional annotations)
- [SciTE Setup Wizard] provides a batteries-included installation for Windows; it is pre-configured with Lua function calltips and Lua 5 keywords.
- [Geany] (Unix, Windows and most other platforms)
- Code folding, Syntax highlighting (since Geany 0.11)
-
- [Zeus for Windows] (Win32, shareware)
- Code folding
- Syntax highlighting
- Project/Workspace manager
- Code templates
- Tools and macros
- The [QuickHelp] feature can open the [Lua Helpfile] at the topic of current word.
- [Debugger] for Lua 5.1.2
- Editor is fully configurable using embedded Lua 5.1.2 scripting module
- [PSPad for Windows] (Win32, freeware)
- Support of Lua 4.0 syntax highlighting
- Can be re-configured to support Lua 5.0 syntax highlighting
- Keyboard F-keys can open [Lua Helpfile] at the topic for a word the cursor is on.
- [Crimson Editor for Windows] (Win32, freeware)
- Support of Lua 4.0 syntax highlighting
- Can be re-configured to support Lua 5.0 syntax highlighting
- F1 can open [Lua Helpfile] at the topic for a word the cursor is on.
- [EmEditor] (Win32, shareware)
- Lua 5.0 syntax highlighting configuration file
- [jEdit] (Java, freeware)
- Support of Lua 5.0 syntax highlighting
Editors requiring 3rd party add-ons, and miscellaneous editor tools:
- [Emacs] and [XEmacs] (most platforms)
- [Lua-mode] with syntax highlighting, auto-indent, interactive lua shell, paren and brace matching, auto-move to function or block begin/end, online documentation look-ups, postprocess output buffer (jump to error lines using traceback). Supports Lua 4 and 5. Works with GNU Emacs 20.7 and above, and XEmacs 21.1 and above.
- [GNU Nano] (Unix, Windows and most other platforms)
-
- [Jed] (Unix, Windows and most other platforms)
- [2]. Should be added to the main release in the next version.
- [Xcode] (OSX, Note: doesn't seem to work with XCode 3)
- [MED] (win32 and OS/2 PM)
- [NEdit] (most platforms)
- visit site to download Lua pattern
- [MC-Cooledit] (Unix, win32)
- [Syntax coloring scheme] Use this with the internal editor of the GNU Midnight Commander to get your scripts with fancy colors. Includes small Lua script to perform installation.
- [FTE] (Unix, win32, OS/2)
- [Epsilon] (win32)
- Epsilon is an emacs-like editor that has been around for quite a few years in the DOS, OS/2, Windows, and lately Mac OSX and Linux platforms. A [simple Lua mode] is available, written in Epsilon's C-like extension language EEL. It is known to work with Epsilon 13, and probably works with some earlier versions as well. Save the liked file locally as luamode.e, compile to bytecode and load into the running Epsilon state with the compile-buffer command (which is probably bound to Alt+F3). Save the modified state file as usual (with the write-state command). The resulting major mode handles simple syntax highlighting and code indentation cases, but it does have blind spots and limitations.
- [NitroLite] (win32)
- A small text editor. It supports multi-level undo, syntax highlighting, handling multiple files and multiple views.
- [Syntax coloring scheme] Copy/paste this at the bottom of the n2.ini configuration file in the installation folder to add syntax coloring for Lua 5.
Comments on Specific Editors
Xemacs
This tickles XEmacs' syntax highlighting a bit. On the first line place "local x = (x)*(x)*(x)*(x)*(x)*(x)*(x)*(x)*(x)*(x)*(x)*(x)*(x)*(x)*(x)". On the second line type "print()". The hourglass cursor flickers for a few couple seconds after typing the ")". Additional terms cause much longer flicker. Some rexex performance issue I suppose. Xemacs 21.4 (patch 13) i586-pc-win32. --DavidManura, 200703
Here's a fill paragraph (M-q) function for wrapping comments. A similar questions was posted in LuaList:2004-04/msg00320.html , but I didn't see this function in the the latest 20061208 version of lua-mode.el on LuaForge. It can probably be improved from this simple form. --DavidManura, 200703
; Fill paragraph (M-q) for wrapping Lua comments.
; http://lua-users.org/wiki/LuaEditorSupport
(defun lua-fill-paragraph (arg)
(save-excursion
(beginning-of-line)
(cond
((looking-at "^ *\-\-+ ")
; Comment found. Set fill prefix. Then fill.
(let ((fill-prefix (buffer-substring-no-properties
(match-beginning 0) (match-end 0)))
(fill-paragraph-function nil))
(fill-paragraph nil)
t))))
)
(setq fill-paragraph-function 'lua-fill-paragraph)
FindPage · RecentChanges · preferences
edit · history
Last edited April 1, 2008 8:14 am GMT (diff)