From b5c34658984c4519ab768fa1d449bfa113ba5e48 Mon Sep 17 00:00:00 2001 From: NACAMURA Mitsuhiro Date: Thu, 8 Feb 2024 07:09:56 +0900 Subject: [PATCH] fix: tweak palette --- lua/srcerite/groups.lua | 17 +++++- lua/srcerite/inputs.lua | 127 ++++++++++++++++++++-------------------- 2 files changed, 80 insertions(+), 64 deletions(-) diff --git a/lua/srcerite/groups.lua b/lua/srcerite/groups.lua index d66c55f..6670fde 100644 --- a/lua/srcerite/groups.lua +++ b/lua/srcerite/groups.lua @@ -1,7 +1,16 @@ local groups = require 'highlite.groups' -local srcerite = require((...):match '(.+)%.[^.]+') +local palette = require((...):match '(.+)%.[^.]+').palette -local M = require('highlite').groups('default', srcerite.palette) +local M = require('highlite').groups('default', palette) + +-- A couple of tweaks {{{ + +M.NormalFloat = M.Normal +M.CursorLine = groups.extend({ bg = palette.bg_contrast_high }, M.CursorLine) + +-- }}} + +-- Options {{{ if vim.g.srcerite_inverse_visual then M.Visual = { reverse = true } @@ -16,4 +25,8 @@ if vim.g.srcerite_inverse_match_paren then M.MatchParen = groups.extend({ reverse = true }, M.MatchParen) end +-- }}} + return M + +-- vim: fdm=marker diff --git a/lua/srcerite/inputs.lua b/lua/srcerite/inputs.lua index 5a0ba30..d3c6ab7 100644 --- a/lua/srcerite/inputs.lua +++ b/lua/srcerite/inputs.lua @@ -1,97 +1,100 @@ local srcery = require((...):match '(.+)%.[^.]+' .. '.srcery') --- c.f. https://github.com/Iron-E/nvim-highlite/blob/master-v4/doc/advanced-usage.md#list-of-palette-colors +-- * List of palette colors: +-- https://github.com/Iron-E/nvim-highlite/blob/v4.15.1/doc/advanced-usage.md#list-of-palette-colors +-- * What color will be used if missing: +-- https://github.com/Iron-E/nvim-highlite/blob/v4.15.1/lua/highlite/color/palette/init.lua#L100-L196 return { - -- annotation = , - -- attribute = , + -- annotation = , --> attribute + -- attribute = , --> preproc bg = srcery.black, bg_contrast_high = srcery.xgray2, - bg_contrast_low = srcery.xgray2, + bg_contrast_low = srcery.hard_black, boolean = srcery.bright_magenta, - -- buffer_active = , - -- buffer_alternate = , - -- buffer_current = , + -- buffer_active = , --> text_contrast_bg_high + -- buffer_alternate = , --> text_contrast_bg_low + -- buffer_current = , --> select character = srcery.bright_magenta, - -- character_special = , - class = srcery.cyan, - comment = srcery.bright_black, - -- comment_documentation = , - -- comment_special = , + -- character_special = , --> special + -- class = , --> structure + -- comment = , --> text_contrast_bg_low + -- comment_documentation = , --> comment + comment_special = srcery.orange, -- NOTE: missing in upstream conditional = srcery.red, constant = srcery.bright_magenta, - -- constant_builtin = , - constructor = srcery.yellow, - -- decorator = , + -- constant_builtin = , --> special + -- constructor = , --> type + -- decorator = , --> attribute define = srcery.cyan, diff_add = srcery.green, diff_change = srcery.cyan, diff_delete = srcery.red, - enum = srcery.cyan, + -- enum = , --> structure error = srcery.bright_red, - event = srcery.bright_orange, - field = srcery.cyan, - -- field_enum = , - float = srcery.bright_magenta, + -- event = , --> loop + -- field = , --> property + -- field_enum = , --> constant + -- float = , --> number fold = srcery.bright_black, func = srcery.yellow, - -- func_builtin = , + -- func_builtin = , --> special hint = srcery.bright_cyan, identifier = srcery.cyan, - include = srcery.cyan, + -- include = , --> preproc info = srcery.bright_green, - interface = srcery.bright_blue, + -- interface = , --> type -- interface_builtin = , - keyword = srcery.red, - -- keyword_coroutine = , - -- keyword_function = , - -- keyword_operator = , - -- keyword_return = , + -- keyword = , --> statement + -- keyword_coroutine = , --> keyword + -- keyword_function = , --> type_builtin + -- keyword_operator = , --> operator + -- keyword_return = , --> keyword label = srcery.red, - loop = srcery.red, + -- loop =, --> conditional macro = srcery.orange, - -- message = , - method = srcery.yellow, - -- namespace = , + -- message = , --> info + -- method = , --> func + -- namespace = , --> uri number = srcery.bright_magenta, ok = srcery.bright_green, operator = srcery.bright_white, - -- parameter = , + -- parameter = , --> identifier preproc = srcery.cyan, - -- preproc_conditional = , - -- property = , - punctuation = srcery.bright_black, - -- punctuation_bracket = , - -- punctuation_delimiter = , - -- punctuation_special = , + -- preproc_conditional = , --> preproc + -- property = , --> identifier + -- punctuation = , --> text_contrast_bg_high + -- punctuation_bracket = , --> punctuation + -- punctuation_delimiter = , --> punctuation + -- punctuation_special = , --> string_special search = srcery.xgray5, - select = srcery.xgray2, - special = srcery.magenta, + select = srcery.xgray2, --> bg_contrast_low + special = srcery.orange, statement = srcery.red, storage = srcery.orange, string = srcery.bright_green, - -- string_escape = , - -- string_regex = , - -- string_special = , + -- string_escape = , --> character + -- string_regex = , --> string + -- string_special = , --> identifier structure = srcery.cyan, - syntax_error = srcery.bright_red, - tag = srcery.cyan, - -- tag_attribute = , - -- tag_delimiter = , + -- syntax_error = , --> error + -- tag = , --> structure + -- tag_attribute = , --> field + -- tag_delimiter = , --> punctuation_bracket text = srcery.bright_white, - -- text_contrast_bg_high = , - -- text_contrast_bg_low = , - -- text_environment_name = , - -- text_environment = , - -- text_literal = , - -- text_math = , - -- text_reference = , - throw = srcery.red, + text_contrast_bg_high = srcery.bright_black, + text_contrast_bg_low = srcery.white, + -- text_environment_name = , --> label + -- text_environment = , --> text_contrast_bg_low + -- text_literal = , --> statement + -- text_math = , --> number + -- text_reference = , --> uri + -- throw = , --> error todo = srcery.bright_white, type = srcery.bright_blue, - -- type_builtin = , - -- type_parameter = , - -- uri = , - variable = srcery.cyan, - -- variable_builtin = , - warning = srcery.orange, + -- type_builtin = , --> type + -- type_parameter = , --> type + uri = srcery.blue, --> text + -- variable = , --> identifier + -- variable_builtin = , --> keyword + warning = srcery.bright_yellow, }