Skip to content
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

Icons appearing blurry and thicker #83316

Closed
miguelsolorio opened this issue Oct 25, 2019 · 26 comments
Closed

Icons appearing blurry and thicker #83316

miguelsolorio opened this issue Oct 25, 2019 · 26 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug debt Code quality issues icons-product Issues for in-product icons

Comments

@miguelsolorio
Copy link
Contributor

image

Comparing stable (left) vs insiders (right) it appears that the new activity bar icons that are using the icon font are thicker for some reason.

@miguelsolorio miguelsolorio added bug Issue identified by VS Code Team member as probable bug icons-product Issues for in-product icons labels Oct 25, 2019
@miguelsolorio miguelsolorio self-assigned this Oct 25, 2019
@miguelsolorio
Copy link
Contributor Author

miguelsolorio commented Oct 30, 2019

Looking into this more, I realize that all of our icons are slightly off-grid, which makes them pixelated as well:

image

Compared to how they are designed:

image

image

I suspect this has something to do with our icon font generating tool we use for our icon font.

@miguelsolorio miguelsolorio changed the title Activity bar icons appear thicker Icons appearing blurry and thicker Oct 30, 2019
@miguelsolorio
Copy link
Contributor Author

miguelsolorio commented Nov 4, 2019

My findings were about how some platforms/browsers render font glyphs and I was able to update these via #83951. However, it appears that the original issue with the activity bar appearing blurry is related to an issue where icons rendered on Windows appear bold. Below is a comparison of macOS (top) and Windows (bottom):

image

Also, -webkit-font-smoothing does nothing on Windows. Would be worthwhile to explore rendering icons via SVG instead of an icon font.

@miguelsolorio miguelsolorio added this to the Backlog milestone Nov 4, 2019
@miguelsolorio miguelsolorio added the debt Code quality issues label Nov 4, 2019
@miguelsolorio
Copy link
Contributor Author

@deepak1556 would you know if this is related to an electron change (possibly #59887) that affects window font renderings?

@miguelsolorio
Copy link
Contributor Author

@deepak1556 wondering if this is related to the font rendering issue? #84154

@Guema
Copy link

Guema commented Nov 13, 2019

Noticed this too.
It is probably Windows only as you said.
Saw screenshots of MacOS or Linux, and it seems not suffering from it.
As icons seems to be blurrier as they was, it could be related to Electron 6 or new chromium version.
Probably depending of the way it is rendered (SVG ? Font-Icon ?)

@Guema
Copy link

Guema commented Nov 13, 2019

May be related to #84698

@bpasero
Copy link
Member

bpasero commented Nov 14, 2019

@misolori @Guema how does it look like with todays insider build? Make sure to update if you did not yet: https://code.visualstudio.com/insiders/

Version must be b6a486e34fe3715f6edec0cdb11138b1672d33bd (check from about dialog).

@Guema
Copy link

Guema commented Nov 14, 2019

I downloaded last Insiders build, looks like the problem is still here

image

@Guema
Copy link

Guema commented Nov 14, 2019

Here is a 1.39.2 (Left) ; Insiders (Right) build comparison

image

image

It seems it affect top bar too (even if it is not really visible)
1.39.2 (Top) ; Insiders (Bottom)

image

@bpasero
Copy link
Member

bpasero commented Nov 14, 2019

Oh I am sorry, there is a change missing on my end to get this right. Hold on...

@bpasero bpasero modified the milestones: Backlog, November 2019 Nov 14, 2019
@bpasero bpasero self-assigned this Nov 14, 2019
@eamodio
Copy link
Contributor

eamodio commented Nov 14, 2019

@bpasero That version looks much better to me (its no longer grayscale AA). Although just like the editor text, it is still much "smoother" than 1.39.2 was.

@bpasero
Copy link
Member

bpasero commented Nov 14, 2019

@eamodio can you spot a difference in the area of the activity bar or just in general?

@Guema
Copy link

Guema commented Nov 14, 2019

@Guema how about: https://az764295.vo.msecnd.net/insider/dccaf037f35ed2d73fa97e48e8e053887d0366b1/VSCode-win32-x64-1.41.0-insider.zip

Seems closer to the initial look, even if there it is still different when looking closer.

image

(1.39.2 vs this insiders build vs Exploration)

image

image

The gear icon is where it is the more visible. the 3 versions are different.

Finally, here is a Windows-Zoomed version where we can see the differences well. It seems related to anti-aliasing method :

image

The difference is visible to me only on :

  • Extensions Button
  • Gear Button
  • Minimize/Maximize/Close Buttons

Otherwise, I probably would not have seen the difference without zooming

@bpasero
Copy link
Member

bpasero commented Nov 14, 2019

@Guema i am not sure about using the exploration build, that one lags behind a lot of changes we did and only comes with Electron 7. Best to compare current stable 1.40.1 with the version from the zip I posted.

@Guema
Copy link

Guema commented Nov 14, 2019

@Guema i am not sure about using the exploration build, that one lags behind a lot of changes we did and only comes with Electron 7. Best to compare current stable 1.40.1 with the version from the zip I posted.

Yeah i could do that, but it seems that launching an instance of the same build type just launch an instance of the already launched editor (If i want to compare 1.39, 1.40 and insiders) I already tried to launch insiders production build and the one you shared, but only could launch one of them at the time

@bpasero
Copy link
Member

bpasero commented Nov 14, 2019

@Guema you can solve this by providing (from the command line when putting the full path to the code EXE): --user-data-dir <unique dir>

@eamodio
Copy link
Contributor

eamodio commented Nov 14, 2019

@bpasero in general, but imo its most noticeable on the activity bar

@bpasero
Copy link
Member

bpasero commented Nov 15, 2019

I see a difference still (left stable 1.39, right latest insiders):

image

I am not sure what the cause is, possibly Chrome decides to render colors differently when transparency is applied or we changed something with our Codicons that could have an impact.

@misolori I can get it to look almost the same as before if I use a stronger color (#AAAAAA) for the inactive foreground:

image

Unfortunately this is probably platform dependent and also should account for the active color, not be hardcoded.

Maybe you wanna play around with changing the activity bar colors if there is a solution that works on all platforms. We could throw in some platform checks in the theme.ts file as well if that is needed.

/cc @deepak1556 if you know of any related Chrome issue that could have an impact

@bpasero bpasero modified the milestone: November 2019 Nov 15, 2019
@bpasero
Copy link
Member

bpasero commented Nov 15, 2019

Oh wait, there was a change in opacity in insiders from 0.6 to 0.4, that could explain it!

@bpasero
Copy link
Member

bpasero commented Nov 15, 2019

Yeap I see no more difference when manually changing to the previous transparency:

image

@bpasero bpasero closed this as completed Nov 15, 2019
@eamodio
Copy link
Contributor

eamodio commented Nov 15, 2019

@bpasero I still see a difference in your last screen shot -- the left one is thinner and less fuzzy. But yeah, with the transparency change they are indeed closer.

@kanlukasz
Copy link

I still see a difference in your last screen shot -- the left on is thinner and less fuzzy.

I see the same

@bpasero
Copy link
Member

bpasero commented Nov 15, 2019

@bpasero I still see a difference in your last screen shot -- the left one is thinner and less fuzzy.

Well to be fair, master includes the changes so that all icons in the activity bar are rendered with LCD-anti-aliasing, while previously it was greyscale. So I would think you notice a difference already because of that.

I think we have to live with the fact that browsers change and accept that. I do not think this is an issue on our end nor Electron we can change.

@Guema
Copy link

Guema commented Nov 15, 2019

imo the fix you done make it far more close to initial design.
It is really acceptable now.
If your UX team feels like they need to fine-tune it, they could probably re-fit the icons or ask for font-icons generator changes.
Thanks for your time and your work @bpasero

@miguelsolorio miguelsolorio removed this from the November 2019 milestone Dec 2, 2019
@miguelsolorio
Copy link
Contributor Author

Removing milestone as this was handled by #84584

@vscodebot vscodebot bot locked and limited conversation to collaborators Dec 30, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug debt Code quality issues icons-product Issues for in-product icons
Projects
None yet
Development

No branches or pull requests

5 participants