diff options
Diffstat (limited to 'modules/textadept')
-rw-r--r-- | modules/textadept/lsnippets.lua | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/modules/textadept/lsnippets.lua b/modules/textadept/lsnippets.lua index 92f1b0a5..19f20e28 100644 --- a/modules/textadept/lsnippets.lua +++ b/modules/textadept/lsnippets.lua @@ -344,6 +344,11 @@ function insert(s_text) buffer:begin_undo_action() s_text = handle_escapes(s_text) + -- Take into account tab settings. + if not buffer.use_tabs then + s_text = s_text:gsub('\t', string.rep(' ', buffer.tab_width)) + end + -- Execute Lua and shell code. s_text = s_text:gsub('%%(%b())', run_lua_code) s_text = |