microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
162.22k stars 28.55k forks source link

Problems highlighting #{ at MonoLisa for Sass in VS Code #148885

Closed bebraw closed 2 years ago

bebraw commented 2 years ago

Does this issue occur when all extensions are disabled?: Yes

I have more info at https://github.com/MonoLisaFont/feedback/issues/138 . The basic problem is that #{ isn't getting picked up by the highlighter for MonoLisa although it works for Fira Code. It works in WebStorm, though.

Do you know what could cause the difference?

Code samples

I've set "editor.fontFamily": "MonoLisa", to generate examples below.

demo.sass

Code:

@for $i from 1 through 9
  .text-#{$key}
    color: red

"editor.fontLigatures": false,

Screen Shot 2022-05-06 at 16 27 33

"editor.fontLigatures": "'liga' on",

Screen Shot 2022-05-06 at 16 27 41

demo.scss

Code:

@for $i from 1 through 9 {
  .text-#{$key} {
    color: red
  }
}

"editor.fontLigatures": false,

Screen Shot 2022-05-06 at 16 27 28

"editor.fontLigatures": "'liga' on",

Screen Shot 2022-05-06 at 16 27 47

Speculation

It's possible the issue is in the typeface itself. My understanding is that it might have something to do with the direction in which ligatures are applied. At the same time given the render is perfect in WebStorm, it might be an issue to address at VS Code itself.

aeschli commented 2 years ago

Can you add a small code sample and the minimal steps to reproduce to the description?

bebraw commented 2 years ago

@aeschli Yeah, I added samples to the issue with something that's fast/easy to copy. I'll send you a typeface you can use for testing separately to your email.

I'm including @marktripney to this issue as I believe he might have further insight and probably wants to know how we progress with the issue.

aeschli commented 2 years ago

Is there an extension we can install to get the font? Sending by mail to me is not very practical as I have to move this issue to the editor team.

bebraw commented 2 years ago

Is there an extension we can install to get the font? Sending by mail to me is not very practical as I have to move this issue to the editor team.

As it's a commercial font, it's not available as an extension.

I've provided instructions on how to access the font for testing to your email so maybe you could forward that info.

aeschli commented 2 years ago

@bebraw I just double checked but couldn't find a mail from you. Can you resend, or, even better, add the instructions to the description?

bebraw commented 2 years ago

@aeschli Ok, I resent it from a different address. Most likely it went to the spam. The message is titled "MonoLisa - Typeface for testing #148885".

hediet commented 2 years ago

/duplicate #131092

VSCodeTriageBot commented 2 years ago

Thanks for creating this issue! We figured it's covering the same as another one we already have. Thus, we closed this one as a duplicate. You can search for similar existing issues. See also our issue reporting guidelines.

Happy Coding!