Ver código fonte

Line wrap cursor movement option (#855)

rob 4 anos atrás
pai
commit
f2e4f540a3
2 arquivos alterados com 6 adições e 1 exclusões
  1. 1 0
      lua/default-config.lua
  2. 5 1
      lua/settings.lua

+ 1 - 0
lua/default-config.lua

@@ -7,6 +7,7 @@ USER = vim.fn.expand "$USER"
 O = {
   leader_key = "space",
   colorscheme = "spacegray",
+  line_wrap_cursor_movement = true,
   transparent_window = false,
   format_on_save = true,
   vnsip_dir = vim.fn.stdpath "config" .. "/snippets",

+ 5 - 1
lua/settings.lua

@@ -9,7 +9,11 @@ cmd "filetype plugin on"
 cmd('let &titleold="' .. TERMINAL .. '"')
 cmd "set inccommand=split"
 cmd "set iskeyword+=-"
-cmd "set whichwrap+=<,>,[,],h,l"
+
+if O.line_wrap_cursor_movement then
+  cmd "set whichwrap+=<,>,[,],h,l"
+end
+
 if O.transparent_window then
   cmd "au ColorScheme * hi Normal ctermbg=none guibg=none"
   cmd "au ColorScheme * hi SignColumn ctermbg=none guibg=none"