helix: styling

This commit is contained in:
Daniel Lundin 2024-04-10 17:36:44 +02:00
parent f3aa483628
commit 1fd76dd0f3
No known key found for this signature in database
2 changed files with 148 additions and 124 deletions

View file

@ -7,6 +7,8 @@ cursorline = true
color-modes = true color-modes = true
auto-pairs = false auto-pairs = false
popup-border = "all" popup-border = "all"
rulers = [80]
gutters = ["diagnostics", "line-numbers", "spacer", "diff", "spacer"]
[editor.cursor-shape] [editor.cursor-shape]
insert = "bar" insert = "bar"
@ -16,11 +18,34 @@ select = "underline"
[editor.indent-guides] [editor.indent-guides]
character = "│" # "╎" character = "│" # "╎"
render = true render = true
skip-levels = 1
[editor.statusline]
separator = "│"
mode.normal = " "
mode.insert = " "
mode.select = "󰒅 "
left = ["spinner", "mode", "diagnostics"]
center = ["file-name", "file-encoding"]
right = ["version-control", "separator", "selections", "register", "separator", "position"]
[editor.lsp] [editor.lsp]
display-inlay-hints = true display-inlay-hints = true
display-messages = true
[keys.normal] [keys.normal]
backspace = "delete_char_backward"
C-h = "delete_char_backward"
C = ["select_mode", "goto_line_end", "normal_mode", "change_selection_noyank"]
H = ":toggle lsp.display-inlay-hints" H = ":toggle lsp.display-inlay-hints"
Z = { Z = ":write-quit-all" } Z = { Z = ":write-quit-all" }
"esc" = ["keep_primary_selection", "collapse_selection"] esc = ["keep_primary_selection", "collapse_selection"]
"`" = ["goto_last_accessed_file"]
tab = ["buffer_picker"]
C-r = ":config-reload"
C-f = [":new", ":insert-output lf -selection-path=/dev/stdout", "split_selection_on_newline", "goto_file", "goto_last_modification", "goto_last_modified_file", ":buffer-close!", ":redraw"]
V = ["goto_first_nonwhitespace", "extend_to_line_end"]
x = "extend_line"
[keys.select]
x = "extend_line"

View file

@ -1,192 +1,191 @@
# Template document for helix color schemes
# See also: https://docs.helix-editor.com/themes.html
#
# NOTE: Keys default to the most specific parent value.
# e.g ui.cursor.primary > ui.cursor > ui
# GENERAL ============================== # GENERAL ==============================
warning = { fg = "#ff7700" } # Editor warnings. warning = { fg = "#ff7700", bg = "#221100", modifierd = [ "italic" ] }
error = { fg = "#ff0038" } # Editor errors, like mis-typing a command. error = { fg = "#ff0038", bg = "#220000", modifiers = [ "italic" ] }
info = { fg = "#00d992" } # Contextual info in diagnostic messages (LSP). hint = { fg = "#00d992", bg = "#002211", modifierd = [ "italic" ] }
hint = { } # Code diagnostics hints (LSP). info = { fg = "#ffcc00", bg = "#222200", modifiers = ["italic"] }
diagnostic = { fg = "#c49848"} # Code diagnostics in editing area (LSP). diagnostic = { fg = "#c49848"}
"diagnostic.hint" = { underline = { color = "silver", style = "curl" } } "diagnostic.info" = { underline = { color = "#ffcc00", style = "curl" } }
"diagnostic.info" = { underline = { color = "delta", style = "curl" } } "diagnostic.hint" = { fg = "#00d992", underline = { color = "#00d992", style = "curl" } }
"diagnostic.warning" = { underline = { color = "lightning", style = "curl" } } "diagnostic.warning" = { fg = "#ff7700", underline = { color = "#ff7700", style = "curl" } }
"diagnostic.error" = { underline = { color = "apricot", style = "curl" } } "diagnostic.error" = { fg = "#ff0038", underline = { color = "#ff0038", style = "curl" } }
"diagnostic.unnecessary" = { modifiers = ["dim"] } "diagnostic.unnecessary" = { fg = "#ffcc00", modifiers = ["dim", "italic"], underline = { style = "curl" } }
"diagnostic.deprecated" = { modifiers = ["crossed_out"] } "diagnostic.deprecated" = { modifiers = ["crossed_out"] }
# UI ============================== # UI ==============================
# For styling helix itself. # For styling helix itself.
'ui.background' = { bg="background" } # Default background color. 'ui.background' = { bg="background" }
'ui.background.separator' = { fg="#00a171" } 'ui.background.separator' = { fg="#00a171" }
'ui.window' = { bg="#224466" } # Window border between splits. 'ui.window' = { bg="#224466" }
'ui.gutter' = { } # Left gutter for diagnostics and breakpoints. 'ui.gutter' = { bg="#11171d" }
'ui.text' = { fg = "#e3e0cd" } # Default text color. 'ui.text' = { fg = "#cccccc" }
'ui.text.focus' = { bg = "#294467" } # Selection highlight in buffer-picker or file-picker. 'ui.text.focus' = { bg = "#294467" }
'ui.text.info' = { } # Info popup contents (space mode menu). 'ui.text.info' = { }
'ui.cursor' = { bg = "#00a171", fg = "#000000" } # Fallback cursor colour, non-primary cursors when there are multiple (shift-c). 'ui.cursor' = { bg = "#00a171", fg = "#000000" }
'ui.cursor.primary' = { bg ="#23fdb6", fg = "#000000" } # The primary cursor when there are multiple (shift-c). 'ui.cursor.primary' = { bg ="#23fdb6", fg = "#000000" }
'ui.cursor.insert' = { fg = "#ff0000" } # The cursor in insert mode (i). 'ui.cursor.insert' = { fg = "#ff0000" }
'ui.cursor.select' = { } # The cursor in select mode (v). 'ui.cursor.select' = { fg = "#3399ff" }
'ui.cursor.match' = { } # The matching parentheses of that under the cursor. 'ui.cursor.match' = { fg = "#000000", bg = "#ffd54f" }
'ui.cursorline.primary' = { bg = "#141b23" } 'ui.cursorline.primary' = { bg = "#141b23" }
'ui.selection' = { bg = "#294467" } # All currently selected text. 'ui.selection' = { bg = "#294467" }
'ui.selection.primary' = { bg = "#294467" } # The primary selection when there are multiple. 'ui.selection.primary' = { bg = "#294467" }
'ui.linenr' = { fg = "#374351" } # Line numbers. 'ui.linenr' = { fg = "#374351", modifiers = [ "bold", "italic" ] }
'ui.linenr.selected' = { fg = "#617d9d", bg = "#14202e" } # Current line number. 'ui.linenr.selected' = { fg = "#617d9d", bg = "#14202e" }
'ui.virtual' = { } # Namespace for additions to the editing area. 'ui.virtual' = { }
"ui.virtual.indent-guide" = { fg = "#273341" } "ui.virtual.indent-guide" = { fg = "#273341" }
"ui.virtual.inlay-hint" = { fg = "#51a0cf", modifiers = ["italic"] } "ui.virtual.inlay-hint" = { fg = "#51a0cf", modifiers = ["italic", "bold"] }
'ui.virtual.ruler' = { } # Vertical rulers (colored columns in editing area). 'ui.virtual.ruler' = { bg = "#11171d" }
'ui.virtual.whitespace' = { } # Whitespace markers in editing area. 'ui.virtual.whitespace' = { }
'ui.virtual.wrap' = { fg = "#ffd54f" }
"ui.virtual.jump-label" = { fg = "#96ffe6", bg = "#051e33", modifiers = ["bold", "italic"] }
'ui.statusline' = { bg = "#151920", fg = "#4d5a6c" } # Status line. # 'ui.statusline' = { bg = "#151920", fg = "#4d5a6c" }
'ui.statusline.inactive' = { } # Status line in unfocused windows. 'ui.statusline' = { bg = "#11171d", fg = "#637184", modifiers = ["italic", "bold"] }
"ui.statusline.normal" = { } # Statusline mode during normal mode (only if editor.color-modes is enabled) 'ui.statusline.inactive' = { }
"ui.statusline.insert" = { fg = "#b99912" } # Statusline mode during insert mode (only if editor.color-modes is enabled) "ui.statusline.normal" = { }
"ui.statusline.select" = { } # Statusline mode during select mode (only if editor.color-modes is enabled) "ui.statusline.insert" = { fg = "#d7b640" }
"ui.statusline.select" = { fg = "#3dc9ff" }
'ui.help' = { } # `:command` descriptions above the command line. 'ui.help' = { }
'ui.highlight' = { } # selected contents of symbol pickers (spc-s, spc-S) and current line in buffer picker (spc-b). 'ui.highlight' = { bg="#224466" }
"ui.highlight.frameline" = { } "ui.highlight.frameline" = { }
'ui.menu' = { bg = "#242d38", fg="#bfd5e2" } # Autocomplete menu. 'ui.menu' = { bg = "#242d38", fg="#bfd5e2" }
'ui.menu.selected' = { bg = "#135d7e" } # Selected autocomplete item. 'ui.menu.selected' = { bg = "#135d7e" }
'ui.popup' = { bg = "#253d6b", fg="#b2c6e9" } # Documentation popups (space-k). 'ui.popup' = { bg = "#253d6b", fg="#b2c6e9" }
'ui.popup.info' = { } # Info popups box (space mode menu). 'ui.popup.info' = { }
# SYNTAX HIGHLIGHTING ============================== # SYNTAX HIGHLIGHTING ==============================
# All the keys here are Treesitter scopes. # All the keys here are Treesitter scopes.
'property' = { } # Regex group names. 'property' = { }
'special' = { fg="#ffecd3" } # Special symbols e.g `?` in Rust, `...` in Hare. 'special' = { fg="#ffecd3" }
'attribute' = { } # Class attributes, html tag attributes. 'attribute' = { }
'type' = { } # Variable type, like integer or string, including program defined classes, structs etc.. 'type' = { }
'type.builtin' = { } # Primitive types of the language (string, int, float). 'type.builtin' = { }
'type.enum.variant' = { } # A variant of an enum. 'type.enum.variant' = { }
'constructor' = { } # Constructor method for a class or struct. 'constructor' = { }
'constant' = { } # Constant value 'constant' = { }
'constant.builtin' = { } # Special constants like `true`, `false`, `none`, etc. 'constant.builtin' = { }
'constant.builtin.boolean' = { } # True or False. 'constant.builtin.boolean' = { }
'constant.character' = { } # Constant of character type. 'constant.character' = { }
'constant.character.escape' = { } # escape codes like \n. 'constant.character.escape' = { }
'constant.numeric' = { } # constant integer or float value. 'constant.numeric' = { }
'constant.numeric.integer' = { } # constant integer value. 'constant.numeric.integer' = { }
'constant.numeric.float' = { } # constant float value. 'constant.numeric.float' = { }
'string' = { fg="#88ab8a", modifiers=["italic"] } # String literal. 'string' = { fg="#88ab8a", modifiers=["italic"] }
'string.regexp' = { } # Regular expression literal. 'string.regexp' = { }
'string.special' = { } # Strings containing a path, URL, etc. 'string.special' = { }
'string.special.path' = { } # String containing a file path. 'string.special.path' = { }
'string.special.url' = { } # String containing a web URL. 'string.special.url' = { }
'string.special.symbol' = { } # Erlang/Elixir atoms, Ruby symbols, Clojure keywords. 'string.special.symbol' = { }
'comment' = { fg = "#e57373", modifiers = ["bold", "italic"] } # This is a comment. 'comment' = { fg = "#e57373", modifiers = ["bold", "italic"] }
'comment.line' = { } # Line comments, like this. 'comment.line' = { }
'comment.block' = { } # Block comments, like /* this */ in some languages. 'comment.block' = { }
'comment.block.documentation' = { } # Doc comments, e.g '///' in rust. 'comment.block.documentation' = { }
'variable' = { fg="#eceff1" } # Variable names. 'variable' = { fg="#999999", modifiers = [ "italic" ] }
'variable.builtin' = { } # Language reserved variables: `this`, `self`, `super`, etc. # 'variable.builtin' = { }
'variable.parameter' = { } # Function parameters. 'variable.parameter' = { fg = "#eeccaa", modifiers = [ "italic" ] }
'variable.other.member' = { } # Fields of composite data types (e.g. structs, unions). # 'variable.other.member' = { }
'label' = { } # Loop labels, among other things. 'label' = { }
'punctuation' = { } # Any punctuation symbol. 'punctuation' = { fg = "#b0bec5" }
'punctuation.delimiter' = { fg = "#999999" } # Commas, colons or other delimiter depending on the language. 'punctuation.delimiter' = { fg = "#b0bec5" }
'punctuation.bracket' = { } # Parentheses, angle brackets, etc. 'punctuation.bracket' = { fg = "#b0bec5" }
'keyword' = { } # Language reserved keywords. 'keyword' = { fg = "#d5d5d5" }
'keyword.control' = { } # Control keywords. # 'keyword.control' = { }
'keyword.control.conditional' = { } # `if`, `else`, `elif`. # 'keyword.control.conditional' = { }
'keyword.control.repeat' = { } # `for`, `while`, `loop`. # 'keyword.control.repeat' = { }
'keyword.control.import' = { } # `import`, `export` `use`. # 'keyword.control.import' = { }
'keyword.control.return' = { } # `return` in most languages. # 'keyword.control.return' = { }
'keyword.control.exception' = { } # `try`, `catch`, `raise`/`throw` and related. # 'keyword.control.exception' = { }
'keyword.operator' = { } # `or`, `and`, `in`. # 'keyword.operator' = { }
'keyword.directive' = { } # Preprocessor directives (#if in C...). # 'keyword.directive' = { }
'keyword.function' = { } # The keyword to define a function: 'def', 'fun', 'fn'. # 'keyword.function' = { }
'operator' = { } # Logical, mathematical, and other operators. 'operator' = { }
'function' = { fg = "#f7f7f7" } #, modifiers = [ "bold" ] } 'function' = { fg = "#f7f7f7" }
'function.builtin' = { } 'function.builtin' = { }
'function.method' = { } # Cla"ss / Struct methods. 'function.method' = { }
'function.macro' = { } 'function.macro' = { }
'function.special' = { } # Preprocessor function in C. 'function.special' = { }
'tag' = { } # As in <body> for html, css tags. 'tag' = { }
'tag.error' = { } # Erroneous closing html tags. 'tag.error' = { }
'namespace' = { } # Namespace or module identifier. 'namespace' = { fg = "#b0bec5" }
# Markup ============================== # Markup ==============================
# Colors for markup languages, like Markdown or XML. # Colors for markup languages, like Markdown or XML.
'markup.heading.1' = { } # Markdown heading 1 color. 'markup.heading.1' = { }
'markup.heading.2' = { } # Markdown heading 2 color. 'markup.heading.2' = { }
'markup.heading.3' = { } # Markdown heading 3 color. 'markup.heading.3' = { }
'markup.heading.4' = { } # Markdown heading 4 color. 'markup.heading.4' = { }
'markup.heading.5' = { } # Markdown heading 5 color. 'markup.heading.5' = { }
'markup.heading.6' = { } # Markdown heading 6 color. 'markup.heading.6' = { }
'markup.heading.marker' = { } # Hashtag color on Markdown headings. 'markup.heading.marker' = { }
'markup.list' = { } 'markup.list' = { }
'markup.list.numbered' = { } # Numbered list. 'markup.list.numbered' = { }
'markup.list.unnumbered' = { } # Bullet point list. 'markup.list.unnumbered' = { }
'markup.bold' = { } # Bold text. 'markup.bold' = { }
'markup.italic' = { } # Italicised text. 'markup.italic' = { }
'markup.link' = { } 'markup.link' = { }
'markup.link.url' = { } # Urls pointed to by links. 'markup.link.url' = { }
'markup.link.label' = { } # Non-URL link references. 'markup.link.label' = { }
'markup.link.text' = { } # URL and image descriptions in links. 'markup.link.text' = { }
'markup.quote' = { } # `> Quotes` in Markdown. 'markup.quote' = { }
# Markup - Interface ============================== # Markup - Interface ==============================
# "These scopes are used for theming the editor interface." # "These scopes are used for theming the editor interface."
'markup.normal' = { } 'markup.normal' = { }
'markup.normal.completion' = { } # For completion doc popup ui. 'markup.normal.completion' = { }
'markup.normal.raw' = { } # For hover popup ui. 'markup.normal.raw' = { }
'markup.heading.completion' = { } # Headings for completion doc popup ui. 'markup.heading.completion' = { }
'markup.heading.raw' = { } # Headings for hover popup ui. 'markup.heading.raw' = { }
'markup.raw' = { } # Code block in Markdown. 'markup.raw' = { }
'markup.raw.block' = { } # Multiline (```) codeblock in Markdown. 'markup.raw.block' = { }
'markup.raw.inline' = { } # `Inline code block` in Markdown. 'markup.raw.inline' = { }
'markup.raw.inline.completion' = { } # ? 'markup.raw.inline.completion' = { }
'markup.raw.inline.hover' = { } # ? 'markup.raw.inline.hover' = { }
# Diff ============================== # Diff ==============================
# Version control changes. # Version control changes.
'diff.plus' = { fg = "#469e58" } # Additions. 'diff.plus' = { fg = "#678350" }
'diff.minus' = { fg = "#ff0038" } # Deletions. 'diff.minus' = { fg = "#ff0038" }
'diff.delta' = { fg = "#3caba4" } # Modifications. 'diff.delta' = { fg = "#897a21" }
'diff.delta.moved' = { } # Renamed or moved files. 'diff.delta.gutter' = { fg = "#ffff00" }
# 'diff.delta.moved' = { }
[palette] # Define your custom colors here. [palette] # Define your custom colors here.