-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
semantic highlighting, coloring unused code differently #25
Comments
This is typically handled through diagnostics with "unnecessary" tag. Does server report relevant diagnostic for that part of the code? If it does then https://lsp.sublimetext.io/customization/#diagnostics has information how to modify color scheme to support that. |
They are neither reported as diagnostics nor the coloring works on the tags |
If not supported right now then it would need to be added in https://github.com/OmniSharp/omnisharp-roslyn. This is just a think wrapper package that makes it easy to use it in Sublime. |
I'm not sure what exactly doesn't work. If server doesn't provide diagnostics with those tags then it will obviously not work. Otherwise it obviously should work if your color scheme is extended accordingly. |
Adding the little snippet I've mentioned in my first comment does not produce a diagnostic. |
Does it work in VSCode? And also you might want to try to disable this seemingly relevant option: LSP-OmniSharp/LSP-OmniSharp.sublime-settings Lines 21 to 23 in 73285c6
|
It does work in VSCode. Changing |
Should be checked with latest Omnisharp version also. |
Then it would need to be investigated how VSCode extension does it. Whether through LSP server, syntax file or maybe even some custom code in the extension. |
I'm not smart enough to get this whole server to run on my mac so I'm not gonna look into it but if you want to debug a bit then you could post here the response to the |
But after brief look it seems like the server reports code actions with This silly server has so much custom logic in the extension that it almost defeats the purpose of having an LSP server... It would be a full time job to get this mapped to our package. |
Consider the following code, I want to "dim" or use custom coloring on the unreachable or unused code. Couldn't find a way to achieve this with semantic highlighting, the LSP documentation doesn't provide a semantic token specifically for this it seems, or I did not notice it. Is this possible and supported and if so what is the correct way to add this to a custom color scheme?
The text was updated successfully, but these errors were encountered: