question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add support for semantic highlighting so that syntax plugins work without any modification

See original GitHub issue

This is just an idea I had. I have no idea how feasible it is, or if it covers all cases.

The problem with a lot of highlighting plugins is that they do not work well with the syntax highlighter that is used by VSCode. In most cases, they are simply ignored and we have to modify the highlighting groups inside init.vim in order to force a certain terminal highlighting color.

I propose adding a semantic highlighter that receives the colors from Neovim and applies them to the VSCode editor. This will probably require wrapping existing VSCode highlighters and combining the results. I don’t know whether VCode has an API that supports this, but it might be interesting to find out.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
asvetliakovcommented, Jun 22, 2021

vscode semantic api is pull model. however neovim HL is only push model and only for current neovim viewport. it’s useless

1reaction
samvvcommented, Jun 5, 2021

Support for more Neovim plugins that (ab)use the syntax highlighting would be the main use case. They would just work without any adjustments, which is in theory why this extension exists in the first place. However I agree that the benefits may not outweigh the costs in terms of development time.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Semshi - Semantic Highlighting for Python in Neovim - GitHub
Semshi provides semantic highlighting for Python in Neovim. Unlike regex-based syntax highlighters, Semshi understands Python code and performs static ...
Read more >
Semantic Highlight Guide | Visual Studio Code Extension API
Semantic highlighting is an addition to syntax highlighting as described in the Syntax Highlight guide. Visual Studio Code uses TextMate grammars as the...
Read more >
How to enable semantic highlighting in VS Code - Stefan Judis
Semantic syntax highlighting makes code easier to read and can be enabled in VS Code easily.
Read more >
Semantic Highlighting | Qt Creator Manual - Qt Documentation
To specify the color scheme to use for semantic highlighting, select Edit > Preferences > Text Editor > Fonts & Color. Qt Creator...
Read more >
Customizing syntax highlighting in Visual Studio Code
I also looked through the settings file vscode generated and files that came with it, but no clue either. Neither did a web...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found