VSCodeVim / Vim

:star: Vim for Visual Studio Code
http://aka.ms/vscodevim
MIT License
14.02k stars 1.32k forks source link

Easymotion - Gray out fonts when activated #4524

Closed fourcolors closed 4 years ago

fourcolors commented 4 years ago

Is your feature request related to a problem? Please describe. I'd like greater focus when jumping to words in EasyMotion

Describe the solution you'd like VIM Easymotion will gray out the code text when you activate it. It would be nice to have this option as well https://github.com/easymotion/vim-easymotion

MathiasKandelborg commented 4 years ago

If you want to see easymotion clearer, I'd suggest to use the options for changing the background and text color.

I'm pretty sure this is a very heavy task, please don't make it default. There's no reason to create such an intensive default when most people easily can distinguish between colors...

I have been trying to do some things with vscode on arch (known problems for save as sudo, transparency), and I just realized that me missing highlighting probably is attributed to this exact default setting. It doesn't really have anything to do with easymotion or vim, just people having a hard time distinguishing colors.

I had to go through the change-log and luckily find this issue. There's no mention of this setting being added anywhere, which by the nature of it (unload all colors, then, when done, load all colors again in the correct places) should be more 'accessible' (put it in 2th place top, it's so critical) and, itself, mention how intensive the task is or could be.

Oh on a side-node, you have left settings in the readme that are deprecated (font family, font size)

I'm done talking reasonable choices and defaults as well as efficiency now. I'd like to mention that my problem probably is a bug somewhere (not in easymotion/vim) that resulted in no highlighting for me. I haven't installed this extension every time and on some builds the extensions simply aren't installed at all.

But my guess is that the vim.easymotionDimBackground has effects on how vscode want to intruct the editor in coloring grammar, and if this setting has been triggered (by installing the extension) it might change some other default setting that messes up vscode's instructions. I need to troubleshoot (a lot more) to see how extenstion settings are saved, and if the problem persists on a completely new install (we're talking both fresh OS with new user install, and vscode). And go from there.

I am just baffled this is a default setting no matter what. I see no reason other than helping people who has trouble differentiating colors and who won't set: `

Setting Description Type Default Value
vim.easymotion Enable/disable easymotion plugin Boolean false
vim.easymotionMarkerBackgroundColor The background color of the marker box.    
vim.easymotionMarkerForegroundColorOneChar The font color for one-character markers.    
vim.easymotionMarkerForegroundColorTwoChar The font color for two-character markers, used to differentiate from one-character markers.  

I also just realized that you're not even using the table to show what the default values are.

berknam commented 4 years ago

Just so you now the background dimming uses the vscode TextEditorDecorationType that simply adds a css class with the css styles you want to the range of code that you want. There is no change of settings, or highlighting at all. This decorations only show when the extension uses the command to show them and as soon as you restart vscode they will be gone (if an extension needs to use one of this decorations it needs to set it every time when loading). So when you disable or remove an extension it is impossible for one of this decorations to linger around.

Since this change is only a css change it isn't a heavy or intensive task. Vscode and a lot of other extensions use this all the time. The code lenses are made like this, the little lamp bulb you see when there are code actions available is made like this.

Your issue is probably something else and is not related to this easymotion setting at all. It's probably not even related to Vim extension because this extension doesn't mess with any sort of Highlighting user settings. It only creates two new types of highlight for the search highlight and yank highlight.