diff options
author | max397574 <[email protected]> | 2021-11-22 12:42:06 +0100 |
---|---|---|
committer | max397574 <[email protected]> | 2021-11-22 12:42:06 +0100 |
commit | dae7fe9034ce85edfed7567f7fbd4ed93a73fd96 (patch) | |
tree | bfda6715c6042158bb844c0f195f4e0fd8394ae7 /lua/startup/utils.lua | |
parent | befd13523c08e76a8ad2deafa02295221974a2d3 (diff) |
feat(): ✨default value for margin and cursor column
Diffstat (limited to 'lua/startup/utils.lua')
-rw-r--r-- | lua/startup/utils.lua | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lua/startup/utils.lua b/lua/startup/utils.lua index 1f4fa21..c80bcfa 100644 --- a/lua/startup/utils.lua +++ b/lua/startup/utils.lua @@ -178,10 +178,11 @@ end local column = function() local settings = require("startup").settings local column_calc - if settings.options.cursor_column < 1 then - column_calc = math.floor(vim.o.columns * settings.options.cursor_column) + local cursor_column = settings.options.cursor_column or 0.5 + if cursor_column < 1 then + column_calc = math.floor(vim.o.columns * cursor_column) else - column_calc = settings.options.cursor_column + column_calc = cursor_column end return column_calc end |