You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[bug] CJK glyph corruption in terminal output (1.9.6) #4639
When rendering text in Superset Terminal 1.9.6 (1.9.6), glyphs appear corrupted — characters overlap each other and some are drawn as broken or unrecognizable shapes, making the output unreadable. The issue is most visible with Korean (Hangul) text and with mixed Korean/Latin output.
This appears to be a font rendering or CJK grid-cell width calculation issue rather than a content problem: the underlying byte stream is intact (the same commands render correctly in other terminal emulators such as Terminal.app and iTerm2).
Steps to reproduce
Open Superset Terminal 1.9.6 (1.9.6)
Run a command that prints Korean text, e.g. echo "한글 테스트 통합 참조"
Observe the rendered output in the terminal window
Output (screenshot)
The following is what is actually rendered in Superset Terminal when printing Korean + Latin text. Hangul syllables overlap and several glyphs are replaced with broken shapes.
Expected: Hangul and Latin characters render with correct glyphs and no overlap, identical to how the same byte stream renders in other terminals.
Environment
App: Superset Terminal 1.9.6 (1.9.6)
OS:
Font:
Font size / line height:
Install method:
Additional notes
Reproduces with Latin-only text?
Reproduces with other fonts?
Same text renders correctly in Terminal.app and iTerm2 on the same machine.
Reacted by J, Igor Kulman, KyuJoo Han, David Knell, Jake Nelken, Lee Han Ul and Henrique Santaella Bontempo
Triage note: I looked at this but couldn't write a bun:test reproduction. A short writeup of what I checked and why a test isn't feasible:
What's affected
Terminal renderer lives in apps/desktop/src/renderer/lib/terminal/. Addons are loaded in terminal-addons.ts: Unicode11Addon (with activeVersion = "11"), LigaturesAddon, WebglAddon (deferred to rAF), plus ClipboardAddon/ImageAddon/SearchAddon/ProgressAddon.
Width/cell logic is in apps/desktop/src/renderer/lib/terminal/links/buffer-helpers.ts and is already covered by CJK regression tests (buffer-helpers.test.ts), including Hangul ranges (0x1100–0x115F Jamo and 0xAC00–0xD7A3 Syllables) and a regression for #147619.
Default font stack in apps/desktop/src/renderer/lib/terminal/appearance/index.ts is JetBrains Mono, …, Menlo, Monaco, Courier New, monospace — none of these primary entries ship Hangul glyphs, so Korean characters are drawn from a browser/OS fallback font.
Why a unit test isn't feasible
The reported symptom is glyph corruption at the pixel level (characters overlapping, broken/unrecognizable shapes) while the input byte stream is intact (same bytes render fine in Terminal.app/iTerm2). That points squarely at the rendering pipeline — @xterm/addon-webgl's glyph atlas, font fallback for missing CJK glyphs, or @xterm/addon-ligatures interaction with non-Latin shaping. bun:test runs in Node without a real DOM/Canvas/WebGL context, so it can't exercise the renderer that produces these glyphs. The width-calculation path (the only logic-level slice of the problem) is already tested and passing.
Likely culprits worth investigating in a real Electron build
Font fallback mismatch — JetBrains Mono measures cell width from a Latin glyph; the fallback Hangul font's intrinsic glyph width may not match, producing overlap. A targeted fix would be adding a CJK-capable monospace (e.g. D2Coding, Nanum Gothic Coding, Noto Sans Mono CJK KR) ahead of the generic monospace in DEFAULT_TERMINAL_FONT_FAMILIES.
LigaturesAddon × CJK — LigaturesAddon is loaded unconditionally; if the active font doesn't expose Hangul glyphs but ligature shaping still emits cell hints, the WebGL renderer can draw the wrong glyph at a cell. Worth testing by temporarily skipping loadAddon(new LigaturesAddon()) and re-running the repro.
WebGL glyph atlas — @xterm/addon-webgl (0.20.0-beta.196 here) has a history of atlas-corruption bugs with non-Latin text; falling back to the DOM renderer (set suggestedRendererType = "dom" in terminal-addons.ts:17 or short-circuit before the rAF loadAddon(new WebglAddon())) would confirm.
Repro environment notes the reporter could fill in that would help: macOS version, exact font in use (default vs custom), and whether disabling ligatures or the WebGL renderer makes the corruption go away.
It only happens to me after long sessions without restarting the application, with many terminal sessions running
Closing the terminal window and resuming the session in another will fix it, but the issue returns quickly after switching tabs a few times, or if more window history gets generated.
Restarting the app will fix it temporarily, but unless I cut back the amount of terminal sessions (or GPU load)? it will come back again
Closing as a duplicate of #5605, the consolidated tracker for stale terminal-rendering issues from the July 2026 stale-issue sweep (no activity since 2026-06-01). If this still applies on a current build, comment on #5605 and we'll reopen.
Activity
github-actions commentedon May 16, 2026
Triage note: I looked at this but couldn't write a
bun:testreproduction. A short writeup of what I checked and why a test isn't feasible:What's affected
apps/desktop/src/renderer/lib/terminal/. Addons are loaded interminal-addons.ts:Unicode11Addon(withactiveVersion = "11"),LigaturesAddon,WebglAddon(deferred to rAF), plusClipboardAddon/ImageAddon/SearchAddon/ProgressAddon.apps/desktop/src/renderer/lib/terminal/links/buffer-helpers.tsand is already covered by CJK regression tests (buffer-helpers.test.ts), including Hangul ranges (0x1100–0x115F Jamo and 0xAC00–0xD7A3 Syllables) and a regression for #147619.apps/desktop/src/renderer/lib/terminal/appearance/index.tsisJetBrains Mono, …, Menlo, Monaco, Courier New, monospace— none of these primary entries ship Hangul glyphs, so Korean characters are drawn from a browser/OS fallback font.Why a unit test isn't feasible
The reported symptom is glyph corruption at the pixel level (characters overlapping, broken/unrecognizable shapes) while the input byte stream is intact (same bytes render fine in Terminal.app/iTerm2). That points squarely at the rendering pipeline —
@xterm/addon-webgl's glyph atlas, font fallback for missing CJK glyphs, or@xterm/addon-ligaturesinteraction with non-Latin shaping.bun:testruns in Node without a real DOM/Canvas/WebGL context, so it can't exercise the renderer that produces these glyphs. The width-calculation path (the only logic-level slice of the problem) is already tested and passing.Likely culprits worth investigating in a real Electron build
JetBrains Monomeasures cell width from a Latin glyph; the fallback Hangul font's intrinsic glyph width may not match, producing overlap. A targeted fix would be adding a CJK-capable monospace (e.g.D2Coding,Nanum Gothic Coding,Noto Sans Mono CJK KR) ahead of the genericmonospaceinDEFAULT_TERMINAL_FONT_FAMILIES.LigaturesAddon× CJK —LigaturesAddonis loaded unconditionally; if the active font doesn't expose Hangul glyphs but ligature shaping still emits cell hints, the WebGL renderer can draw the wrong glyph at a cell. Worth testing by temporarily skippingloadAddon(new LigaturesAddon())and re-running the repro.@xterm/addon-webgl(0.20.0-beta.196 here) has a history of atlas-corruption bugs with non-Latin text; falling back to the DOM renderer (setsuggestedRendererType = "dom"interminal-addons.ts:17or short-circuit before the rAFloadAddon(new WebglAddon())) would confirm.Repro environment notes the reporter could fill in that would help: macOS version, exact font in use (default vs custom), and whether disabling ligatures or the WebGL renderer makes the corruption go away.
Refs #4639
Kitenite commentedon May 16, 2026
Hi looking at this now
Kitenite commentedon May 16, 2026
Hi added a fix for this but could you also try resizing the terminal see if that fixes for the time?
4dollar4 commentedon May 17, 2026
bwalding commentedon May 18, 2026
I'm getting the glyph corruption on generally regular English text - but resizing did fix it for me. Thanks for the tip.
igorkulman commentedon May 18, 2026
Happens to me also with regular English output from Claude Code and Pi.
dknell commentedon May 18, 2026
Same, this one is very frustrating because it constantly interrupts work.
jnelken commentedon May 18, 2026
Some feedback:
kkak10 commentedon May 19, 2026
+1 Same issue here — I'm using a CJK language (Korean). Resizing the terminal fixes it temporarily, but it breaks again shortly after.
jnelken commentedon May 19, 2026
Kitenite mentioned it's an xterm issue. Please comment and vote this potential fix:
kkak10 commentedon May 22, 2026
@Kitenite Since xtermjs/xterm.js#5883 has been merged, could you bump xterm to 6.1.0-beta.220?
This should hopefully resolve the issue.
fix(desktop): bump @xterm/* to beta.220 for upstream WebGL atlas-merg…
Kitenite commentedon Jul 11, 2026
Closing as a duplicate of #5605, the consolidated tracker for stale
terminal-renderingissues from the July 2026 stale-issue sweep (no activity since 2026-06-01). If this still applies on a current build, comment on #5605 and we'll reopen.