-
Notifications
You must be signed in to change notification settings - Fork 28.8k
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
Terminal webgl renderer oh-my-posh prompt issues #120129
Comments
What I suspect is happening here is that the more clever glyph boundary detection in the webgl renderer where we render the character with a margin and then find its bounding box is biting us because the darker lines are not exactly the same color as the actual background. I wonder if we should hardcode for these particular powerlines characters to explicitly drop that line. |
I also experience problems with vertical lines that break the flow. This is on macOS Big Sur using a powerlevel10k prompt and Delugia Nerd Font Book (a variant of Cascadia Code with Nerd Fonts added) iTerm2 terminal (which is also GPU based) I don't know if it is relevant but the issues adam7/delugia-code#53 and adam7/delugia-code#55 go into a lot of detail concerning vertical alignment. |
Upstream issue: xtermjs/xterm.js#3278 |
Fix looking good, should be in tomorrow's insiders xtermjs/xterm.js#3279, it also includes a vertical alignment improvement too |
@Mellbourn good to hear 😃 the alignment is even fixed on canvas too so it should be just as good there as well if the user falls back to it (you can no longer set to use it explicitly). |
The DOM renderer works a little differently, to get cells to align perfectly they are laid our using inline-block and regular rely on the regular flow of the page as opposed to absolute positioning for performance reasons. I wonder if we could take the nerd font glyph ranges and the powerlines glyph ranges, and handle them specially. Positioning absolute won't work but I wonder if we could do some something using Surprisingly I didn't see the line on my tests, maybe it's only on certain font sizes or something. |
Created xtermjs/xterm.js#3287, I probably won't have time to check it out this release though. |
Finally, its solved in Stable version as well ❤️ Thanks team |
@floh96 do you have a particular large |
@Tyriar window.zoomLevel is 0, font family is 'CaskaydiaCove NF', Consolas, 'Courier New', monospace, font size is 16. |
@floh96 does the problem seem isolated to that font maybe? |
@Tyriar i chanced the font to FiraMono NF same problem |
@Tyriar friendly ping 😄 |
@floh96 not sure what else we could do here unfortunately, without doing something drastic like not actually rendering the glyph but doing it ourselves like in xtermjs/xterm.js#2409 |
@Tyriar okay sad to hear. |
@floh96 you could try switching up the gpuAcceleration setting as that drives which renderer is used, it's was fixed at least on my machine in all the renderers |
@Tyriar thanks for your suggestion unfortunately changing the setting did not fix the issue. |
Below are 3 screenshots from vscode and windows terminal. You can see with the webgl renderer there are strange vertical lines that break the flow. And in both the webgl and canvas, the text isn't vertically aligned properly either. Whereas, Windows Terminal looks the best (only very minor vertical line artifacts).
VS Code webgl renderer
VS Code canvas renderer
Windows Terminal
The text was updated successfully, but these errors were encountered: