Plugin API
From LuaFAR for Editor
Plugin API
- There is an important thing to know when writing scripts for
LuaFAR for Editor: indexing string variables accesses functions
in
unicode.utf8rather than instringnamespace.- For example,
s:sub(1,2)meansunicode.utf8.sub(s,1,2). - To use
stringlibrary, specify that explicitly, e.g.,string.sub(s,1,2). #srefers tostring.len(s). Uses:len()to obtain number of characters.
- For example,
- The plugin has a few functions that are available to user scripts. They are placed under lf4ed namespace.