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

Cascadia Code static vs variable (VF) rendering #14891

Closed
Finii opened this issue Feb 21, 2023 · 6 comments
Closed

Cascadia Code static vs variable (VF) rendering #14891

Finii opened this issue Feb 21, 2023 · 6 comments
Labels
Issue-Bug It either shouldn't be doing this or needs an investigation. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting

Comments

@Finii
Copy link

Finii commented Feb 21, 2023

Windows Terminal version

1.16.10262.0

Windows build number

10.0.22000.1574

Other Software

Cascadia Code release 2111.01

Steps to reproduce

  • Remove Cascadia Cove that comes bundled with Windows Terminal [1]
  • Note that the bundled version is Cascadia Cove 2111.01 VF TrueType outlines
  • Manually install Cascadia Cove 2111.01 static Regular TrueType outlines
  • Start Windows Terminal
  • Take screenshot of text with capitals and small-letter i at some bigger size (effect is not size dependent though)
  • Close Windows Terminal, remove Cascadia Cove font
  • Install Cascadia Cove 2111.01 VF TrueType ourlines
  • Start Windows Terminal and repeat previous steps
  • Compare screenshots

[1] For people like me that is hard, here is a manual:

MAINTAINER EDIT: DO NOT FOLLOW THESE STEPS. Changing the permissions on WindowsApps is a one-way street to pain.
  • Gain access to C:/Programs/WindowsApps
  • Set youself as owner for C:\Program Files\WindowsApps\Microsoft.WindowsTerminal_1.15.3466.0_x64__8wekyb3d8bbwe
  • Set youself as owner for all 4 font files in that folder
  • Add full access right for everyone on the 4 fonts
  • Move the 4 fonts to another location (e.g. desktop) - deleting is impossible
  • Reboot
  • Enjoy to be able to install whichever Cascadia Code you like and use Windows Terminal with that

Note that a Windows Terminal update reinstalls the bundled font, of course.

I'm not entirely sure if this should be reported here or at Cascadia Code. But the issue can not be seen on WordPad and also not in terminals on other platforms, so I guess it is something specific to Windows Terminal.

I tried experimental.rendering.software true and false (and also experimental.useAtlasEngine) but the outcome is unchanged.

Related issues, that as far as I can see all are due to the effect described in this issue.

The problem with the issues above was that they all compare the VF to the static ones and the VF is hard to get rid of.

Expected Behavior

Both fonts should look the same. With maybe a very slight weight difference because one is interpolated on the fly.

Actual Behavior

  • The heights (capital and x) is visibly different
  • The dot on the small letter i is noticable down (or stays in place while the dotless-i glyph resizes)

The effect is even visible in the font preview window.
For easier visual comparison I use a renamed copy of Cascadia Cove Regular ttf with the name Delugia.

The first image shows that Delugia and Cascadia Cove static render the same (at least no really noticable differences):

static

The second image now compares Delugia and Cascadia Cove VF ttf. Because of the comparison above this is equivalent to comparing Cascadia Cove static to Cascadia Cove VF:

VF

@Finii Finii added Issue-Bug It either shouldn't be doing this or needs an investigation. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting labels Feb 21, 2023
@zadjii-msft
Copy link
Member

Hey before going any further on this thread: absolutely do NOT set yourself as owner for anything under C:\Program Files\WindowsApps\. You absolutely WILL break your system by doing that. We've had people need to reinstall Windows after doing that. Seriously, you've been warned.

@Finii
Copy link
Author

Finii commented Feb 21, 2023

Ok, then please advice me how I can get rid of the bundled font?

The steps described above are done in order to be able to bugfix (or rather triage) a problem, not for any 'normal' user.

@lhecker
Copy link
Member

lhecker commented Feb 21, 2023

Couldn't you just install the 12 variants of "CascadiaCodePL" and then compare "Cascadia Code PL" with the builtin "Cascadia Code"? That way you wouldn't have to delete any fonts to reproduce the issue.

According to Visual TrueType we're rendering the text correctly.

@DHowett there seems to be something strange going on with the static variants of Cascadia Code. If I load them into VTT they look identical to the VF variant, but once I load the GASP table, I get warnings in VTT and the glyphs are suddenly 1px taller. With the lowercase "w" character at 12pt and 144dpi for instance, both initially load as 12px tall, but once the GASP table has loaded for the static variants its suddenly 13px tall.

@Finii
Copy link
Author

Finii commented Feb 21, 2023

Couldn't you just install the 12 variants of "CascadiaCodePL" and then compare

In principle I could, but whatever the result I would never know if that is a difference between the vanilla and the PL version.
But thanks, that is still a good idea 👍

According to Visual TrueType we're rendering the text correctly.

I do not know that tool. But WordPad renders both fonts also identical. And Glyphs' TextPreview tool (used to check fonts after creation) also renders both identical 🤔 So far Windows is the only platform where I witnessed the problem.

One thing lingers still in the back of by head, I believe I had a discussion with aaronbell about the static fonts and that they are different in some way; unfortunately I can not find that thread anymore.

@Finii
Copy link
Author

Finii commented Feb 21, 2023

After re-reading the issue I linked myself for the 3rd time:

I guess this is the exact effect we see here. So it might be the autohinting that 'breaks' the static fonts; and has nothing to do with Windows Terminal per se.
I also have a user comment who sees the problem with Visual Studio on Windows.

So I guess this Issue is wrong here (as speculated in the beginning).

Thank you so much for looking into it!

I close this now, sorry for raising a red-herring.

@Finii Finii closed this as completed Feb 21, 2023
@DHowett
Copy link
Member

DHowett commented Feb 21, 2023

That's alright, thanks for following up!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue-Bug It either shouldn't be doing this or needs an investigation. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting
Projects
None yet
Development

No branches or pull requests

4 participants