diff --git a/README.md b/README.md index 2871bf2..b5acb7f 100644 --- a/README.md +++ b/README.md @@ -85,6 +85,10 @@ highlight. Set to `v:true` to make non-current window background dimmer than _Normal_. +#### g:zenbones_italic_comments + +Set to `v:false` to make comments not italicize. + ## Advanced Usage Zenbones is pretty extensible thanks to Lush. You can easily retrieve the colors diff --git a/lua/zenbones/init.lua b/lua/zenbones/init.lua index cfffd1d..609f61d 100644 --- a/lua/zenbones/init.lua +++ b/lua/zenbones/init.lua @@ -16,6 +16,8 @@ elseif lightness ~= nil then vim.api.nvim_echo({ { error_msg, "WarningMsg" } }, true, {}) end +local italic_comments = type(vim.g.zenbones_italic_comments) == "boolean" and vim.g.zenbones_italic_comments or true + -- stylua: ignore start local theme = lush(function() return { @@ -41,7 +43,7 @@ local theme = lush(function() ErrorMsg { Error }, -- error messages on the command line WarningMsg { fg = c.wood }, -- warning messages - Comment { fg = c.sand.da(38).de(28), gui = "italic" }, -- any comment + Comment { fg = c.sand.da(38).de(28), gui = (italic_comments and "italic" or "NONE") }, -- any comment Conceal { fg = c.stone.li(20), gui = "bold,italic" }, -- placeholder characters substituted for concealed text (see 'conceallevel') Cursor { bg = c.stone, fg = c.sand.li(20) }, -- character under the cursor diff --git a/lua/zenflesh/init.lua b/lua/zenflesh/init.lua index 440cc04..c220112 100644 --- a/lua/zenflesh/init.lua +++ b/lua/zenflesh/init.lua @@ -16,6 +16,8 @@ elseif darkness ~= nil then vim.api.nvim_echo({ { error_msg, "WarningMsg" } }, true, {}) end +local italic_comments = type(vim.g.zenflesh_italic_comments) == "boolean" and vim.g.zenflesh_italic_comments or true + -- stylua: ignore start local theme = lush(function() return { @@ -41,7 +43,7 @@ local theme = lush(function() ErrorMsg { Error }, -- error messages on the command line WarningMsg { fg = c.wood }, -- warning messages - Comment { fg = c.sand.li(32).de(48), gui = "italic" }, -- any comment + Comment { fg = c.sand.li(32).de(48), gui = (italic_comments and "italic" or "NONE") }, -- any comment Conceal { fg = c.stone.da(20), gui = "bold,italic" }, -- placeholder characters substituted for concealed text (see 'conceallevel') Cursor { bg = c.stone.li(20), fg = c.sand.da(20) }, -- character under the cursor