Vertical joining of box drawing characters has gaps #4215

Closed
opened 2026-01-30 23:41:11 +00:00 by claunia · 6 comments
Owner

Originally created by @tryptamic on GitHub (Oct 2, 2019).

Environment

Windows build number: Microsoft Windows [Version 10.0.18362.356]
Windows Terminal version (if applicable): 0.5.2681.0

Steps to reproduce

Run this litle command in the terminal using a cmd.exe tab to produce a little box:

echo ┌┐ & echo └┘

Expected behavior

The box should have perfectly joined lines on all sides. Living in a monospaced environment where the box drawing characters are used to draw trees, boxes and other stuf perfect line joining is expected

Actual behavior

The lines of the box are not vertically joined

image

Originally created by @tryptamic on GitHub (Oct 2, 2019). # Environment Windows build number: Microsoft Windows [Version 10.0.18362.356] Windows Terminal version (if applicable): 0.5.2681.0 # Steps to reproduce Run this litle command in the terminal using a cmd.exe tab to produce a little box: ```cmd echo ┌┐ & echo └┘ ``` # Expected behavior The box should have perfectly joined lines on all sides. Living in a monospaced environment where the box drawing characters are used to draw trees, boxes and other stuf perfect line joining is expected # Actual behavior The lines of the box are not vertically joined ![image](https://user-images.githubusercontent.com/8502209/66046865-eaa96a00-e526-11e9-9bd9-90396b006770.png)
claunia added the Area-RenderingResolution-DuplicateArea-Fonts labels 2026-01-30 23:41:11 +00:00
Author
Owner

@zadjii-msft commented on GitHub (Oct 2, 2019):

@tryptamic What font are you using?

What does this look like in conhost (launch cmd.exe directly) with the same font selected?

@zadjii-msft commented on GitHub (Oct 2, 2019): @tryptamic What font are you using? What does this look like in conhost (launch cmd.exe directly) with the same font selected?
Author
Owner

@egmontkob commented on GitHub (Oct 2, 2019):

Some terminals, including VTE and Konsole draw the U+2500..257F (or even up to 259F) glyphs manually, rather than taking them from the font. This prevents such problems (and also avoids ugly looking antialiasing). I haven't seen any monospace font that would just look perfect on its own.

Interestingly, independently from each other, both VTE and Konsole came up with the idea of defining the look of most of these codepoints as a 5x5 matrix (where how the given 5x5 grid is stretched to the character cell is not necessarily the same for thick lines vs. double lines).

VTE link1, link2

Update: Konsole recently changed not to use a 5x5 matrix but other means of drawing.

@egmontkob commented on GitHub (Oct 2, 2019): Some terminals, including VTE and Konsole draw the U+2500..257F (or even up to 259F) glyphs manually, rather than taking them from the font. This prevents such problems (and also avoids ugly looking antialiasing). I haven't seen any monospace font that would just look perfect on its own. Interestingly, independently from each other, both VTE and Konsole came up with the idea of defining the look of most of these codepoints as a 5x5 matrix (where how the given 5x5 grid is stretched to the character cell is not necessarily the same for thick lines vs. double lines). VTE [link1](https://gitlab.gnome.org/GNOME/vte/blob/0.58.0/src/box_drawing.txt), [link2](https://gitlab.gnome.org/GNOME/vte/blob/443cfe95a308247c8661b1bea22c1139520faddf/src/vtedraw.cc#L1180) Update: Konsole recently [changed](https://invent.kde.org/kde/konsole/commit/13132fc77bf90d0a39c62676f3ac75caa581962f) not to use a 5x5 matrix but other means of drawing.
Author
Owner

@DHowett-MSFT commented on GitHub (Oct 2, 2019):

I like the idea of having Terminal draw these itself; we've chatted about that internally and thought it was pretty clever.

This is also related to #455.

@DHowett-MSFT commented on GitHub (Oct 2, 2019): I like the idea of having Terminal draw these itself; we've chatted about that internally and thought it was pretty clever. This is also related to #455.
Author
Owner

@tryptamic commented on GitHub (Oct 2, 2019):

@tryptamic What font are you using?

What does this look like in conhost (launch cmd.exe directly) with the same font selected?

Consolas and here how it looks in in conhost:

image

In terminal with Cascadia Code it gets even worse because horizontal joining is then broken as well and vertical gaps got even larger as you can see in the screenshot

image

Why does it work in the old console without drawing it in a special way. Isn't it a simple issue of the wrong line height and in case of cascadia wrong glyphs?

@tryptamic commented on GitHub (Oct 2, 2019): > @tryptamic What font are you using? > > What does this look like in conhost (launch cmd.exe directly) with the same font selected? Consolas and here how it looks in in conhost: ![image](https://user-images.githubusercontent.com/8502209/66064324-74683000-e545-11e9-8e76-1c3ec0490133.png) In terminal with Cascadia Code it gets even worse because horizontal joining is then broken as well and vertical gaps got even larger as you can see in the screenshot ![image](https://user-images.githubusercontent.com/8502209/66063946-b8a70080-e544-11e9-924a-9deb4fc361f6.png) Why does it work in the old console without drawing it in a special way. Isn't it a simple issue of the wrong line height and in case of cascadia wrong glyphs?
Author
Owner

@zadjii-msft commented on GitHub (Oct 2, 2019):

@tryptamic The legacy console and the Terminal use different renderers to display text. The Terminal's renderer is far more performant, but there are still many edge cases we need to work out, and this is one of them.

I think in general this falls under the umbrella of /dup #455 so I'm gonna close as a dupe.

@zadjii-msft commented on GitHub (Oct 2, 2019): @tryptamic The legacy console and the Terminal use different renderers to display text. The Terminal's renderer is far more performant, but there are still many edge cases we need to work out, and this is one of them. I think in general this falls under the umbrella of /dup #455 so I'm gonna close as a dupe.
Author
Owner

@ghost commented on GitHub (Oct 2, 2019):

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!

@ghost commented on GitHub (Oct 2, 2019): 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!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#4215