Skip to content
This repository has been archived by the owner on Jul 31, 2023. It is now read-only.

Symbol strings (ex. :abc) via "Remote - SSH" are not correctly highlighted #483

Closed
danglduy opened this issue May 12, 2019 · 22 comments
Closed
Milestone

Comments

@danglduy
Copy link

danglduy commented May 12, 2019

Your environment

  • vscode-ruby version: 0.22.3
  • Ruby version: 2.6.3
  • Ruby version manager (if any): rbenv
  • VS Code version: 1.34.10-insider
  • Operating System: Windows
  • Using language server? Solargraph
  • Using via "Remote - SSH" remote environment (Link)

Expected behavior

Symbol strings syntax is correctly highlighted

Actual behavior

Symbol strings syntax is incorrectly highlighted

In the picture below :exception should be highlighted
image

@connorshea
Copy link
Contributor

I assume this is the same problem as microsoft/vscode-remote-release#153

@danglduy
Copy link
Author

I think these are not the same problems. Ruby symbols are correctly highlighted without any language servers anyway.

@minkir014
Copy link

Have you tried that on an ordinary vs code?

@danglduy
Copy link
Author

@minkir014 "Remote - SSH" extension does only work on VS Code Insider I'm afraid.

@wingrunr21
Copy link
Collaborator

wingrunr21 commented May 13, 2019

hi @danglduy

Can you use the Developer: Inspect TM Scopes tool (accessible via the command palette) to tell me what scopes are being matched for the with: :exception part of that code?

The with: should be matching the grammar with a scope of constant.language.symbol.hashkey.ruby and :exception should be constant.language.symbol.ruby.

@danglduy
Copy link
Author

@wingrunr21 I inspected with: and :exception
image
image

@wingrunr21
Copy link
Collaborator

Ok. What theme are you using? The Ruby grammar is correctly matching the TM scopes but it appears your theme does not have support.

@danglduy
Copy link
Author

@wingrunr21 I am using the default theme.

@wingrunr21
Copy link
Collaborator

wingrunr21 commented May 13, 2019

Which is that? Dark+?

@danglduy
Copy link
Author

Yes it’s Dark+

@wingrunr21
Copy link
Collaborator

interesting. I also use Dark+ and I get those keywords highlighted in blue. Do you get highlighting with a different theme?

@danglduy
Copy link
Author

@wingrunr Have you tried using in “Remote SSH” environment? I get highlighted normally in local environment.

@wingrunr21
Copy link
Collaborator

No but that's what I'm trying to determine what the problem is. Does another theme give you correct highlighting?

The Remote SSH environment isn't stable yet and this extension doesn't explicitly support it. Theming is a core VSCode function as well. The grammar is supplying and matching a TM Scope but the theme doesn't have a matching style.

@OmriSama
Copy link

Following

@OmriSama
Copy link

Here's the difference between correctly working TM scope and a not correctly working one:

CORRECT
image

INCORRECT
image

Issue is in constant.language vs constant.other.symbol

@minkir014
Copy link

How have you displayed this in vscode insiders??? I mean what is displayed in the images.

@OmriSama
Copy link

How have you displayed this in vscode insiders??? I mean what is displayed in the images.

I opened the same directory in two windows, one was local VSCode and another one was Remote SSH.

@connorshea
Copy link
Contributor

There's a command in the command palette called "Inspect TM Scopes", I think that's what they're asking for.

@wingrunr21
Copy link
Collaborator

That's what it is. I'm digging into Remote environments after I fix the current issue with tree-sitter. I haven't yet researched why VSCode is assigning different TextMate scopes between the two environments.

@OmriSama
Copy link

Any updates on this?

@wingrunr21 wingrunr21 added this to the v0.26.0 milestone Oct 20, 2019
@wingrunr21
Copy link
Collaborator

This has been resolved in v0.26.0

@OmriSama
Copy link

@wingrunr21 thank you so much! This has been sorely lacking in my Ruby experience :)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants