-
Notifications
You must be signed in to change notification settings - Fork 8.4k
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
windows terminal preview bold / cut-off fonts #10678
Comments
note also that I downgraded the wt preview to version |
Yeah obviously this is caused by #10498, you can see that the "funky" version is rendered as bold, which is actually the expected behavior. What's not expected is the cuf-off. Can you share your settings.json here? Especially for the profile in the screenshot. |
This is probably similar to the italics rendering issue. Bold text may overflow the clipping box we give it. |
Ah. Do we have a solution? Or we just let users disable bold in the settings, after the setting is shipped.
Update: found it #9381
|
This comment has been minimized.
This comment has been minimized.
{
"$schema": "https://aka.ms/terminal-profiles-schema",
"actions":
[
{
"command":
{
"action": "openSettings",
"target": "settingsUI"
},
"keys": "ctrl+shift+,"
},
{
"command":
{
"action": "commandPalette"
},
"keys": "ctrl+shift+p"
},
{
"command": "find",
"keys": "ctrl+shift+f"
},
{
"command": "unbound",
"name": "Change font size..."
},
{
"command":
{
"action": "splitPane",
"split": "auto",
"splitMode": "duplicate"
},
"keys": "ctrl+shift+\\"
}
],
"copyOnSelect": false,
"defaultProfile": "{7f586916-8357-53d4-bb2b-ca96f639898a}",
"largePasteWarning": false,
"multiLinePasteWarning": false,
"profiles":
{
"defaults":
{
"altGrAliasing": true,
"antialiasingMode": "grayscale",
"bellStyle": "none",
"colorScheme": "HLTDev-Github-Bold-Darkened",
"padding": "9"
},
"list":
[
{
"acrylicOpacity": 0.5,
"closeOnExit": "graceful",
"colorScheme": "Breeze",
"commandline": "C:\\Program Files\\PowerShell\\7-preview\\pwsh.exe",
"cursorColor": "#FFFFFF",
"cursorShape": "bar",
"fontFace": "DroidSansMono Nerd Font",
"fontSize": 10,
"guid": "{61c54bbd-c2c6-5271-96e7-009a87ff44bf}",
"hidden": false,
"icon": "ms-appx:///Images/Square44x44Logo.targetsize-32.png",
"name": "PowerShell 6-preview (x64)",
"snapOnInput": true,
"useAcrylic": false
},
{
"colorScheme": "Breeze",
"commandline": "gsudo.exe \"C:\\Program Files\\PowerShell\\7-preview\\pwsh.exe\"",
"hidden": false,
"icon": "ms-appx:///Images/Square44x44Logo.targetsize-32.png",
"name": "PowerShell 6-preview (x64) [elevated]"
},
{
"acrylicOpacity": 0.5,
"closeOnExit": "graceful",
"colorScheme": "Breeze",
"commandline": "C:\\Users\\jared\\apps\\gsudo\\gsudo.exe",
"cursorColor": "#FFFFFF",
"cursorShape": "bar",
"fontFace": "DroidSansMono Nerd Font",
"fontSize": 10,
"hidden": false,
"name": "gsudo",
"snapOnInput": true,
"useAcrylic": false
},
{
"colorScheme": "Breeze",
"commandline": "cmd.exe",
"guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}",
"hidden": false,
"name": "Command Prompt"
},
{
"colorScheme": "Breeze",
"guid": "{574e775e-4f2a-5b96-ac1e-a2962a402336}",
"hidden": false,
"name": "PowerShell",
"source": "Windows.Terminal.PowershellCore"
},
{
"acrylicOpacity": 0.45000000000000001,
"altGrAliasing": true,
"antialiasingMode": "cleartype",
"backgroundImage": null,
"backgroundImageOpacity": 0.0,
"closeOnExit": "graceful",
"colorScheme": "Breeze",
"commandline": "C:\\Windows\\System32\\wsl.exe",
"cursorColor": "#FFFFFF",
"cursorShape": "bar",
"fontFace": "DroidSansMono Nerd Font",
"fontSize": 10,
"fontWeight": "normal",
"guid": "{7f586916-8357-53d4-bb2b-ca96f639898a}",
"hidden": false,
"historySize": 9000,
"icon": "C:/Users/jared/AppData/Local/Packages/WhitewaterFoundryLtd.Co.16571368D6CFF_kd1vv0z0vy70w/LocalState/rootfs/usr/local/lib/pengwin.ico",
"name": "Pengwin",
"padding": "9",
"snapOnInput": true,
"source": "Windows.Terminal.Wsl",
"startingDirectory": "%USERPROFILE%",
"useAcrylic": false
},
{
"colorScheme": "Breeze",
"guid": "{b453ae62-4e3d-5e58-b989-0a998ec441b8}",
"hidden": false,
"name": "Azure Cloud Shell",
"source": "Windows.Terminal.Azure"
},
{
"guid": "{d1569d34-e3dc-506e-b3ef-3ca18387f714}",
"hidden": false,
"name": "Ubuntu-CommPrev",
"source": "Windows.Terminal.Wsl"
},
{
"guid": "{620e65d5-5d9b-55bf-873b-4a1dfa317ba4}",
"hidden": false,
"name": "Ubuntu on Windows Community Preview",
"source": "CanonicalGroupLimited.UbuntuonWindowsCommunityPrev_79rhkp1fndgsc"
}
]
},
"schemes":
[
{
"name": "Breeze",
"background": "#31363B",
"black": "#31363B",
"blue": "#1D99F3",
"brightBlack": "#7F8C8D",
"brightBlue": "#3DAEE9",
"brightCyan": "#16A085",
"brightGreen": "#1CDC9A",
"brightPurple": "#8E44AD",
"brightRed": "#C0392B",
"brightWhite": "#FCFCFC",
"brightYellow": "#FDBC4B",
"cursorColor": "#EFF0F1",
"cyan": "#1ABC9C",
"foreground": "#EFF0F1",
"green": "#11D116",
"purple": "#9B59B6",
"red": "#ED1515",
"selectionBackground": "#EFF0F1",
"white": "#EFF0F1",
"yellow": "#F67400"
},
{
"name": "Bright Lights",
"background": "#191919",
"black": "#191919",
"blue": "#76D4FF",
"brightBlack": "#191919",
"brightBlue": "#76D5FF",
"brightCyan": "#6CBFB5",
"brightGreen": "#B7E876",
"brightPurple": "#BA76E7",
"brightRed": "#FF355B",
"brightWhite": "#C2C8D7",
"brightYellow": "#FFC251",
"cursorColor": "#F34B00",
"cyan": "#6CBFB5",
"foreground": "#B3C9D7",
"green": "#B7E876",
"purple": "#BA76E7",
"red": "#FF355B",
"selectionBackground": "#B3C9D7",
"white": "#C2C8D7",
"yellow": "#FFC251"
},
{
"name": "Brogrammer",
"background": "#131313",
"black": "#1F1F1F",
"blue": "#2A84D2",
"brightBlack": "#D6DBE5",
"brightBlue": "#1081D6",
"brightCyan": "#0F7DDB",
"brightGreen": "#1DD361",
"brightPurple": "#5350B9",
"brightRed": "#DE352E",
"brightWhite": "#FFFFFF",
"brightYellow": "#F3BD09",
"cursorColor": "#B9B9B9",
"cyan": "#1081D6",
"foreground": "#D6DBE5",
"green": "#2DC55E",
"purple": "#4E5AB7",
"red": "#F81118",
"selectionBackground": "#1F1F1F",
"white": "#D6DBE5",
"yellow": "#ECBA0F"
},
{
"name": "Campbell",
"background": "#0C0C0C",
"black": "#0C0C0C",
"blue": "#0037DA",
"brightBlack": "#767676",
"brightBlue": "#3B78FF",
"brightCyan": "#61D6D6",
"brightGreen": "#16C60C",
"brightPurple": "#B4009E",
"brightRed": "#E74856",
"brightWhite": "#F2F2F2",
"brightYellow": "#F9F1A5",
"cursorColor": "#FFFFFF",
"cyan": "#3A96DD",
"foreground": "#CCCCCC",
"green": "#13A10E",
"purple": "#881798",
"red": "#C50F1F",
"selectionBackground": "#FFFFFF",
"white": "#CCCCCC",
"yellow": "#C19C00"
},
{
"name": "Campbell Powershell",
"background": "#012456",
"black": "#0C0C0C",
"blue": "#0037DA",
"brightBlack": "#767676",
"brightBlue": "#3B78FF",
"brightCyan": "#61D6D6",
"brightGreen": "#16C60C",
"brightPurple": "#B4009E",
"brightRed": "#E74856",
"brightWhite": "#F2F2F2",
"brightYellow": "#F9F1A5",
"cursorColor": "#FFFFFF",
"cyan": "#3A96DD",
"foreground": "#CCCCCC",
"green": "#13A10E",
"purple": "#881798",
"red": "#C50F1F",
"selectionBackground": "#FFFFFF",
"white": "#CCCCCC",
"yellow": "#C19C00"
},
{
"name": "HLTDev-Github-Bold-Darkened",
"background": "#2C2B2A",
"black": "#1A1A1A",
"blue": "#4074C0",
"brightBlack": "#A3A3A3",
"brightBlue": "#6699CC",
"brightCyan": "#3E999F",
"brightGreen": "#99CC99",
"brightPurple": "#C040A5",
"brightRed": "#F2777A",
"brightWhite": "#FFDDDD",
"brightYellow": "#E0D561",
"cursorColor": "#FFFFFF",
"cyan": "#40C0A8",
"foreground": "#D9D9D9",
"green": "#59C040",
"purple": "#8840C0",
"red": "#AD381C",
"selectionBackground": "#FFFFFF",
"white": "#FFDDDD",
"yellow": "#BCC040"
},
{
"name": "HLTDev-Tommorow",
"background": "#2C2B2A",
"black": "#1A1A1A",
"blue": "#6699CC",
"brightBlack": "#A3A3A3",
"brightBlue": "#6699CC",
"brightCyan": "#3E999F",
"brightGreen": "#99CC99",
"brightPurple": "#F4005F",
"brightRed": "#F2777A",
"brightWhite": "#F6F6EF",
"brightYellow": "#E0D561",
"cursorColor": "#FFFFFF",
"cyan": "#66CCCC",
"foreground": "#D9D9D9",
"green": "#99CC99",
"purple": "#CC99CC",
"red": "#AD381C",
"selectionBackground": "#FFFFFF",
"white": "#CDCDCD",
"yellow": "#FFCC66"
},
{
"name": "Hltdev-pro",
"background": "#DCDAD9",
"black": "#202828",
"blue": "#206898",
"brightBlack": "#606068",
"brightBlue": "#3080B8",
"brightCyan": "#61D6D6",
"brightGreen": "#309E40",
"brightPurple": "#783873",
"brightRed": "#E01818",
"brightWhite": "#F2F2F2",
"brightYellow": "#E6DE98",
"cursorColor": "#FCC6C6",
"cyan": "#78A8C8",
"foreground": "#2D2D2D",
"green": "#19502B",
"purple": "#505890",
"red": "#A61416",
"selectionBackground": "#EAE1A2",
"white": "#ABABAB",
"yellow": "#DEBC05"
},
{
"name": "Lavandula",
"background": "#050014",
"black": "#230046",
"blue": "#4F4A7F",
"brightBlack": "#372D46",
"brightBlue": "#8E87E0",
"brightCyan": "#9AD4E0",
"brightGreen": "#52E0C4",
"brightPurple": "#A776E0",
"brightRed": "#E05167",
"brightWhite": "#8C91FA",
"brightYellow": "#E0C386",
"cursorColor": "#8C91FA",
"cyan": "#58777F",
"foreground": "#736E7D",
"green": "#337E6F",
"purple": "#5A3F7F",
"red": "#7D1625",
"selectionBackground": "#37323C",
"white": "#736E7D",
"yellow": "#7F6F49"
},
{
"name": "Material",
"background": "#E6E6E6",
"black": "#212121",
"blue": "#134EB2",
"brightBlack": "#B5BCCF",
"brightBlue": "#54A4F3",
"brightCyan": "#26BBD1",
"brightGreen": "#7ABA3A",
"brightPurple": "#AA4DBC",
"brightRed": "#E83B3F",
"brightWhite": "#D9D9D9",
"brightYellow": "#E8A30F",
"cursorColor": "#FF324D",
"cyan": "#0E717C",
"foreground": "#232322",
"green": "#457B24",
"purple": "#560088",
"red": "#B7141F",
"selectionBackground": "#F4FF19",
"white": "#C7C7C7",
"yellow": "#E07900"
},
{
"name": "MaterialDark",
"background": "#232322",
"black": "#212121",
"blue": "#134EB2",
"brightBlack": "#424242",
"brightBlue": "#54A4F3",
"brightCyan": "#26BBD1",
"brightGreen": "#7ABA3A",
"brightPurple": "#AA4DBC",
"brightRed": "#E83B3F",
"brightWhite": "#D9D9D9",
"brightYellow": "#FFEA2E",
"cursorColor": "#16AFCA",
"cyan": "#0E717C",
"foreground": "#E5E5E5",
"green": "#457B24",
"purple": "#560088",
"red": "#B7141F",
"selectionBackground": "#DFDFDF",
"white": "#EFEFEF",
"yellow": "#F6981E"
},
{
"name": "One Half Dark",
"background": "#282C34",
"black": "#282C34",
"blue": "#61AFEF",
"brightBlack": "#5A6374",
"brightBlue": "#61AFEF",
"brightCyan": "#56B6C2",
"brightGreen": "#98C379",
"brightPurple": "#C678DD",
"brightRed": "#E06C75",
"brightWhite": "#DCDFE4",
"brightYellow": "#E5C07B",
"cursorColor": "#FFFFFF",
"cyan": "#56B6C2",
"foreground": "#DCDFE4",
"green": "#98C379",
"purple": "#C678DD",
"red": "#E06C75",
"selectionBackground": "#FFFFFF",
"white": "#DCDFE4",
"yellow": "#E5C07B"
},
{
"name": "One Half Light",
"background": "#FAFAFA",
"black": "#383A42",
"blue": "#0184BC",
"brightBlack": "#4F525D",
"brightBlue": "#61AFEF",
"brightCyan": "#56B5C1",
"brightGreen": "#98C379",
"brightPurple": "#C577DD",
"brightRed": "#DF6C75",
"brightWhite": "#FFFFFF",
"brightYellow": "#E4C07A",
"cursorColor": "#4F525D",
"cyan": "#0997B3",
"foreground": "#383A42",
"green": "#50A14F",
"purple": "#A626A4",
"red": "#E45649",
"selectionBackground": "#FFFFFF",
"white": "#FAFAFA",
"yellow": "#C18301"
},
{
"name": "Pengwin",
"background": "#16001A",
"black": "#0C0C0C",
"blue": "#003DE8",
"brightBlack": "#767676",
"brightBlue": "#3B78FF",
"brightCyan": "#61D6D6",
"brightGreen": "#16C60C",
"brightPurple": "#F500D8",
"brightRed": "#E74856",
"brightWhite": "#F2F2F2",
"brightYellow": "#F9F1A5",
"cursorColor": "#FFFFFF",
"cyan": "#3A96DD",
"foreground": "#E3E3E3",
"green": "#13A10E",
"purple": "#9B1AAD",
"red": "#E01123",
"selectionBackground": "#FFFFFF",
"white": "#CCCCCC",
"yellow": "#C19C00"
},
{
"name": "Pro Light",
"background": "#FFFFFF",
"black": "#000000",
"blue": "#3B75FF",
"brightBlack": "#9F9F9F",
"brightBlue": "#0082FF",
"brightCyan": "#61F7F8",
"brightGreen": "#61EF57",
"brightPurple": "#FF7EFF",
"brightRed": "#FF6640",
"brightWhite": "#F2F2F2",
"brightYellow": "#F2F156",
"cursorColor": "#FFFFFF",
"cyan": "#4ED2DE",
"foreground": "#191919",
"green": "#50D148",
"purple": "#ED66E8",
"red": "#E5492B",
"selectionBackground": "#FFFFFF",
"white": "#DCDCDC",
"yellow": "#C6C440"
},
{
"name": "Solarized Dark",
"background": "#002B36",
"black": "#073642",
"blue": "#268BD2",
"brightBlack": "#002B36",
"brightBlue": "#839496",
"brightCyan": "#93A1A1",
"brightGreen": "#586E75",
"brightPurple": "#6C71C4",
"brightRed": "#CB4B16",
"brightWhite": "#FDF6E3",
"brightYellow": "#657B83",
"cursorColor": "#FFFFFF",
"cyan": "#2AA198",
"foreground": "#839496",
"green": "#859900",
"purple": "#D33682",
"red": "#DC322F",
"selectionBackground": "#FFFFFF",
"white": "#EEE8D5",
"yellow": "#B58900"
},
{
"name": "Solarized Light",
"background": "#FDF6E3",
"black": "#073642",
"blue": "#268BD2",
"brightBlack": "#002B36",
"brightBlue": "#839496",
"brightCyan": "#93A1A1",
"brightGreen": "#586E75",
"brightPurple": "#6C71C4",
"brightRed": "#CB4B16",
"brightWhite": "#FDF6E3",
"brightYellow": "#657B83",
"cursorColor": "#002B36",
"cyan": "#2AA198",
"foreground": "#657B83",
"green": "#859900",
"purple": "#D33682",
"red": "#DC322F",
"selectionBackground": "#FFFFFF",
"white": "#EEE8D5",
"yellow": "#B58900"
},
{
"name": "Tango Dark",
"background": "#000000",
"black": "#000000",
"blue": "#3465A4",
"brightBlack": "#555753",
"brightBlue": "#729FCF",
"brightCyan": "#34E2E2",
"brightGreen": "#8AE234",
"brightPurple": "#AD7FA8",
"brightRed": "#EF2929",
"brightWhite": "#EEEEEC",
"brightYellow": "#FCE94F",
"cursorColor": "#FFFFFF",
"cyan": "#06989A",
"foreground": "#D3D7CF",
"green": "#4E9A06",
"purple": "#75507B",
"red": "#CC0000",
"selectionBackground": "#FFFFFF",
"white": "#D3D7CF",
"yellow": "#C4A000"
},
{
"name": "Tango Light",
"background": "#FFFFFF",
"black": "#000000",
"blue": "#3465A4",
"brightBlack": "#555753",
"brightBlue": "#729FCF",
"brightCyan": "#34E2E2",
"brightGreen": "#8AE234",
"brightPurple": "#AD7FA8",
"brightRed": "#EF2929",
"brightWhite": "#EEEEEC",
"brightYellow": "#FCE94F",
"cursorColor": "#000000",
"cyan": "#06989A",
"foreground": "#555753",
"green": "#4E9A06",
"purple": "#75507B",
"red": "#CC0000",
"selectionBackground": "#FFFFFF",
"white": "#D3D7CF",
"yellow": "#C4A000"
},
{
"name": "UbuntuLegit",
"background": "#2C001E",
"black": "#75F50A",
"blue": "#3465A4",
"brightBlack": "#555753",
"brightBlue": "#729FCF",
"brightCyan": "#34E2E2",
"brightGreen": "#8AE234",
"brightPurple": "#AD7FA8",
"brightRed": "#EF2929",
"brightWhite": "#EEEEEE",
"brightYellow": "#FCE94F",
"cursorColor": "#FFFFFF",
"cyan": "#06989A",
"foreground": "#EEEEEE",
"green": "#300A24",
"purple": "#75507B",
"red": "#CC0000",
"selectionBackground": "#FFFFFF",
"white": "#D3D7CF",
"yellow": "#C4A000"
},
{
"name": "Vintage",
"background": "#000000",
"black": "#000000",
"blue": "#000080",
"brightBlack": "#808080",
"brightBlue": "#0000FF",
"brightCyan": "#00FFFF",
"brightGreen": "#00FF00",
"brightPurple": "#FF00FF",
"brightRed": "#FF0000",
"brightWhite": "#FFFFFF",
"brightYellow": "#FFFF00",
"cursorColor": "#FFFFFF",
"cyan": "#008080",
"foreground": "#C0C0C0",
"green": "#008000",
"purple": "#800080",
"red": "#800000",
"selectionBackground": "#FFFFFF",
"white": "#C0C0C0",
"yellow": "#808000"
},
{
"name": "Wombat",
"background": "#171717",
"black": "#000000",
"blue": "#5DA9F6",
"brightBlack": "#313131",
"brightBlue": "#A5C7FF",
"brightCyan": "#B7FFF9",
"brightGreen": "#DDF88F",
"brightPurple": "#DDAAFF",
"brightRed": "#F58C80",
"brightWhite": "#FFFFFF",
"brightYellow": "#EEE5B2",
"cursorColor": "#BBBBBB",
"cyan": "#82FFF7",
"foreground": "#DEDACF",
"green": "#B1E969",
"purple": "#E86AFF",
"red": "#FF615A",
"selectionBackground": "#453B39",
"white": "#DEDACF",
"yellow": "#EBD99C"
},
{
"name": "synthwave",
"background": "#000000",
"black": "#000000",
"blue": "#2186EC",
"brightBlack": "#000000",
"brightBlue": "#2F9DED",
"brightCyan": "#19CDE6",
"brightGreen": "#25C141",
"brightPurple": "#F97137",
"brightRed": "#F841A0",
"brightWhite": "#FFFFFF",
"brightYellow": "#FDF454",
"cursorColor": "#19CDE6",
"cyan": "#12C3E2",
"foreground": "#DAD9C7",
"green": "#1EBB2B",
"purple": "#F85A21",
"red": "#F6188F",
"selectionBackground": "#19CDE6",
"white": "#FFFFFF",
"yellow": "#FDF834"
}
],
"tabSwitcherMode": "disabled",
"tabWidthMode": "equal",
"theme": "system"
}
I am using the theme Breeze (although the problem seems to happen with all themes) heres that snippet so you don't have to search through my giant config json {
"name": "Breeze",
"background": "#31363B",
"black": "#31363B",
"blue": "#1D99F3",
"brightBlack": "#7F8C8D",
"brightBlue": "#3DAEE9",
"brightCyan": "#16A085",
"brightGreen": "#1CDC9A",
"brightPurple": "#8E44AD",
"brightRed": "#C0392B",
"brightWhite": "#FCFCFC",
"brightYellow": "#FDBC4B",
"cursorColor": "#EFF0F1",
"cyan": "#1ABC9C",
"foreground": "#EFF0F1",
"green": "#11D116",
"purple": "#9B59B6",
"red": "#ED1515",
"selectionBackground": "#EFF0F1",
"white": "#EFF0F1",
"yellow": "#F67400"
} |
Note that this is different from the italic issue, because an italic font should generally have the same character spacing as the regular variant (at least I would think so), but it's not uncommon for the character spacing of a bold font to be wider than the default weight. So while you may get the edge of a character clipped off with italics, you could potentially lose multiple characters if you're rendering a long sequence of bold without setting individual character offsets. I suspect this wouldn't be an issue with GDI, because we specify the width for each character in the If you want an easy font to test with, you can use the MS Gothic font that comes with Windows. |
I've had a chance to test a few more of the fonts that I think are preinstalled on Windows, and these are the ones that have wider character spacing when bold: Lucida Console, MS Gothic, NSimSun, and SimSun-ExtB. And here's a test case you can use to demo multiple characters being truncated: Note that we've completely lost two characters from the end of that sequence. This was using Lucida Console, but any of the fonts listed above should produce the same result. |
it's just a wild guess, but could this have something to do with cleartype settings in windows 10? |
Well when ClearType is enabled, you'll get the truncation at the end of a simple line of bold characters, while with Grayscale antialiasing you won't. But the test case I provided above has an attribute change after the run of bold, and that forces the truncation regardless of the antialiasing mode. And even if you aren't seeing the truncation, the characters are still rendering in the wrong place regardless of the mode. So while it's not as obviously wrong if you don't use ClearType, it's still not correct. |
just a sidenote, thank you for the fast responsiveness to the issue! |
The ideal way to fix this would be by rendering the font cell-by-cell, and for that we are going to wait on @lhecker 's atlas rendering because doing cell-by-cell rendering now will be way too performance intensive. As a patch of sorts however, we will use bold-as-bright as the default setting until this is fixed. (An alternative we considered would be to, upon setting the font, set the size of each cell according to the 'biggest' variation of the font - so probably the italic/bold variant - but this would result in a problem in the reverse direction, there'd be large spaces around the normal font. So we're going the cell-by-cell route and moving this to the 2.0 milestone for now, but ideally it'll come in right after the atlas renderer.) |
Just to clarify: Cell-by-cell is "more correct" than what we have now because right now we batch an entire run of text that has the same attributes into a single piece for rendering; this causes the glyph width errors to accumulate as we move rightward across the screen. Rendering one glyph in one cell lets us cut off or choose to overflow the edges of the bold text while centering each glyph in its cell. This will become somewhat better and somewhat worse with @lhecker's atlas renderer, because I suspect there is an invariant that a glyph is fully contained within its bounding box, and if we shrink the bounding box we'll simply cut off the edges of the glyph. Possibly bad, but in a different way than in this issue. We may want to ship with bold=bold disabled for 1.10 given that we're adding a setting for it in #10576. |
That’s how I got it currently implemented as. But in this new rendering engine we can focus on getting that one initial measuring right, where we determine how large a character cell should be (in pixel) and we should be golden for at least all common cases. I personally suspect that there will always be a font out there that will cause trouble for us, but at least in the general case with almost-actually-monospace fonts it should work very well. |
just a question out of curiosity, why exactly is this whole font display system being redone when it already seems to work perfectly fine in the first place? (I assume there must be a good reason that I am just not aware of 😅) ... the phrase comes to mind "if it's not broken don't fix it" |
@hltdev8642 The current system is based on D2D/Direct2D and has certain unfixable (or hardly fixable) flaws. The new system is built with D3D/Direct3D instead and is significantly more energy efficient than the old one. The current approach is fairly simple and draws text in "runs", where each run is a group of text with the same:
D2D has some clever internal optimizations which batches multiple draw calls together and sends them all at once to the GPU. For instance 120 by 30 characters of black and white text can be drawn within 250us GPU and 1ms CPU time. But as you might already guess, no amount of "clever batching" or further optimization can alleviate the extra cost of splitting text into runs in the first place. For instance D2D can only draw text with 8 different colors at most at once. If you draw more than that it'll draw the frame in multiple passes on the GPU -- up to 450 passes, every single frame, in our 120x30 terminal. That way it already takes 4ms GPU and 20ms CPU time, meaning we already can't keep up a stable 60 FPS. And it gets progressively worse the more characters you have on your screen, because it requires more passes. A full-screen terminal is 282x72 characters for me and requires 12ms GPU and 100ms CPU time per frame to draw (8 FPS). The new renderer will require more work from us to implement things like ligatures, but it requires only 10us GPU / 3ms CPU time at 120x30 and 150us GPU / 11ms CPU time at 282x72, despite coloring all characters and using complex text. The GPU usage is entirely independent of any factors and remains constant at a given screen size. Finally the D3D approach will allow us to trivially implement fancy features like accessible cursors or rounded corners for text selections. |
@lhecker , thank you that makes sense now :-) !! |
From discussion at #10678, we will ship with "intense" as bright for now until we fix text getting cut off by some bold fonts.
From discussion at #10678, we will ship with "intense" as bright for now until we fix text getting cut off by some bold fonts.
Note that I have switched CascadiaCodePL font from TrueType to OpenType and it solves the italic font clipping issue for me |
Hi! We've identified this issue as a duplicate of another one that already exists on this Issue Tracker. This specific instance is being closed in favor of tracking the concern over on the referenced thread. Thanks for your report! |
Windows Terminal version (or Windows build number)
1.10.1933.0
Other Software
No response
Steps to reproduce
so in the latest (preview) version, the text is acting really funky. I have a feeling it has something to do with this:
Expected Behavior
No response
Actual Behavior
it is kind of har to explain what is happening, so I made this image:
(it should be noted that I made sure that both versions were using the exact same settings.json file)
The standard version of wt is working fine, but hopefully this will not be an issue anymore when/if it is incorperated into the regular build at some point.
thanks
The text was updated successfully, but these errors were encountered: