aboutsummaryrefslogtreecommitdiff
path: root/fnl/opt.fnl
diff options
context:
space:
mode:
Diffstat (limited to 'fnl/opt.fnl')
-rw-r--r--fnl/opt.fnl15
1 files changed, 11 insertions, 4 deletions
diff --git a/fnl/opt.fnl b/fnl/opt.fnl
index 17e4e0d..663fdee 100644
--- a/fnl/opt.fnl
+++ b/fnl/opt.fnl
@@ -11,13 +11,17 @@
(tset vim.opt :termguicolors true)
;--vim.opt.fillchars = { eob = ""}
+(local color_change (fn []
+ (vim.api.nvim_set_hl 0 :Normal {:bg :none})
+ (vim.api.nvim_set_hl 0 :EndOfBuffer {:bg :none})
+ (vim.api.nvim_set_hl 0 :NormalFloat {:bg :none})
+ (vim.api.nvim_set_hl 0 :FloatBorder {:bg :none})))
+
(when (= _G.settings.trans "enable")
(vim.api.nvim_create_autocmd "Colorscheme" {
:pattern :*
- :callback (fn []
- (vim.api.nvim_set_hl 0 :Normal {:bg :none})
- (vim.api.nvim_set_hl 0 :NormalFloat {:bg :none})
- (vim.api.nvim_set_hl 0 :FloatBorder {:bg :none}))}))
+ :callback color_change})
+ (color_change))
(vim.cmd (.. "colorscheme " _G.settings.colorscheme))
@@ -27,3 +31,6 @@
(vim.fn.mkdir target_path :p 0777))
(tset vim.o :undodir target_path)
(tset vim.o :undofile true))
+
+(when (not= _G.settings.layout "")
+ ((require (.. :layouts. _G.settings.layout))))