Renormalized + itronb adjustments

This commit is contained in:
Lüdecke Sascha
2026-03-23 15:09:06 +01:00
parent 2b47d7a9cd
commit fd5c73f099
25 changed files with 2143 additions and 2102 deletions

View File

@@ -1,15 +1,15 @@
-- custom defined functions
-- Return the currently, visually selected text range
function SL_get_visual_selection()
vim.cmd([[ execute "normal! \<ESC>" ]])
local s_start = vim.fn.getcharpos("'<")
local s_end = vim.fn.getcharpos("'>")
vim.cmd([[ execute "normal! gv" ]])
local current_buffer = vim.api.nvim_get_current_buf()
local r = vim.api.nvim_buf_get_text(current_buffer, s_start[2] - 1, s_start[3] - 1,
s_end[2] - 1, s_end[3], {})
-- print("region might be", current_buffer, s_start[2], s_start[3], s_end[2], s_end[3])
return table.concat(r, "\n")
end
-- custom defined functions
-- Return the currently, visually selected text range
function SL_get_visual_selection()
vim.cmd([[ execute "normal! \<ESC>" ]])
local s_start = vim.fn.getcharpos("'<")
local s_end = vim.fn.getcharpos("'>")
vim.cmd([[ execute "normal! gv" ]])
local current_buffer = vim.api.nvim_get_current_buf()
local r = vim.api.nvim_buf_get_text(current_buffer, s_start[2] - 1, s_start[3] - 1,
s_end[2] - 1, s_end[3], {})
-- print("region might be", current_buffer, s_start[2], s_start[3], s_end[2], s_end[3])
return table.concat(r, "\n")
end