Closed patrick-motard closed 1 week ago
Hi, I'm glad you like the theme!
The coloring issue is related to tmux, you have to explictly enable true-colors in your tmux config file. This is how I do it in my config:
set -g default-terminal 'screen-256color'
set -as terminal-overrides ',xterm*:RGB'
The top line may need to be changed to fit with your terminal, but I've been using this with wezterm and kitty for a while without any issues.
As for the underline issue, does that happen when you open neovim outside of tmux? I'm not entirely sure what causes that, but it may also be fixed by setting the default-terminal
option.
Turns out this isn't an issue with just this theme. Other themes have issues displaying color correctly. Kanagawa for example:
In tmux:
Outside tmux:
However, this issue is only present on my linux machine (arch / kde / wayland). On OSX these themes work perfectly fine. I am running alacritty on both. My config is identical on both. Perhaps i need to set a different term value in alacritty on linux or a different value for the two settings you mentioned in tmux. I tried the values you suggested but those did not work in my case.
I agree with marking this as not a bug for this theme. I will close this ticket. However, once I find a solution I'll try to remember to come back and mention the fix here in case others have issues and find there way here. If i don't remember to, at least others have links here to my dotfiles where the fix will live.
Also, using the kanagawa theme here is what it looks like when my cursor is over a variable in lua
And over a string
I'm guessing this highlighting has something to do with treesitter or treesitter-text-objects. I'm not sure. Either way, I think it would be nice if the darkearth theme had something similar instead of using a squiggly line underneath. That's just my personal preference though. I find the squigly and highlighting very distracting as it looks to me like there is an issue when there isn't.
Maybe i'll re-open this just for the highlight display issue. I've tested it on osx and linux, with lua and ruby files.
Regarding your tmux config, the problem might be coming from the set -sa terminal-features ',tmux256color:RGB'
line, as I think that tells tmux to use a 256-color palette rather than a truecolor palette.
Since you use alacritty, you could try this in its place.
set -as terminal-overrides ",alacritty*:Tc"
As for the squiggly underline, I'm still unsure about where that is coming from (and I haven't been able to replicate it), can you run :Inspect
over one of the places where it is happening and post the output?
Adding that setting to my tmux config fixed the issue on linux. Thank you! I still need to test it out on osx.
Here is the output of :Inspect
:
Treesitter
- @variable.lua links to Identifier lua
- @property.lua links to Field lua
- @function.lua links to Function lua
Semantic Tokens
- @lsp.type.property.lua links to Identifier priority: 125
Extmarks
- LspReferenceWrite vim_lsp_references
Press ENTER or type command to continue
This is the file from the screenshot. I have a couple different nvim configurations I'm working with, but this is the one I have been using in these screenshots. Link.
I just pushed an update (680dd3b) that should switch the squiggles to underlines. Try updating and let me know if everything looks right for you.
Muuuuuch better! Thank you!!
Hey fellow Patrick! Love the theme!! I'm noticing that the background doesn't look quite right on mine. Any ideas what the cause might be?
Also, the variable or string under cursor always has a squigly line underneath, and sometimes has a different color than when not focused. Normally the squigly line only shows up when there is a linting or lsp issue.
This is how I install and configure darkearth.