microsoft / cascadia-code

This is a fun, new monospaced font that includes programming ligatures and is designed to enhance the modern look and feel of the Windows Terminal.
Other
25.66k stars 804 forks source link

Cascadia Mono PL @ Font Size 15 doesn't render U2591-U2593 (* shade) glyphs correctly #438

Closed rbeesley closed 3 years ago

rbeesley commented 3 years ago

Environment

Cascadia Code version number: 2009.022
Application (with version) used to display text: Windows Terminal Preview (Version: 1.7.572.0)
OS platform and version: Windows 10 (Dev 21337.1010)
Screen resolution (i.e. 220dpi): 3440x1440 @ 100% scaling

Steps to reproduce

Using ansi-color.cmd with the following definition file:

:: plaid-2.def
__DATA__
:: Select Graphic Rendition (SGR) parameters
__TABLE__
:: The test text
SET "CELL= ░▒▓█"
SET "STUBHEAD=plaid-2"
:: Separator characters for cells and headers
SET "SEPARATOR.STUBHEAD_BOXHEAD=│"
SET "SEPARATOR.STUBHEAD_STUB=─"
SET "SEPARATOR.INTERSECT=┘"
__TABLE:END__

:: Background
__COLS__
40m
41m
42m
43m
44m
45m
46m
47m
100m
101m
102m
103m
104m
105m
106m
107m
__COLS:END__

:: [Intensity;][Attribute;]Foreground
__ROWS__
:: Normal
30m
31m
32m
33m
34m
35m
36m
37m
90m
91m
92m
93m
94m
95m
96m
97m
__ROWS:END__
__DATA:END__

From a cmd prompt (not PS), run: C:\>ansi-color.cmd plaid-2.def

Expected behavior

image

Actual behavior

image

At a font size of 15, the Light Shade (U2591), Medium Shade (U2592), and Dark Shade (U2593) glyphs render transparently with no foreground masking. The way the shades render has been a problem discussed before as I recall, specifically with respect to how the foreground and background colors are mixed, but I hadn't seen before where one font size completely broke the expected functionality in a range of working sizes. This appears to be a problem with font sizes 1, 2, and 3 as well, but 15 stands out as a bigger problem since it is in the threshold of typical ranges. This problem didn't reproduce in Notepad for similar font sizes, so it might be specific with the font rendering pipeline used with Windows Terminal rather than a font specific issue.

aaronbell commented 3 years ago

If it doesn't repro in Notepad, then it is definitely an issue with Windows Terminal. Please file a bug over there :)

DHowett commented 3 years ago

Oh yes we FOR SURE use the wrong antialiasing mode when we render shades and box glyphs. I can’t link it right now, but we have an issue for it.

rbeesley commented 3 years ago

Looks like it is #5897.