Repository navigation
Conversation
Mirr0ch1
force-pushed
the
fix/translucent-ui-spacing
branch
2 times, most recently
from
October 26, 2026 19:48
10903e8 to
0553c45
Compare
A pane's nav bar stopped at its own height, leaving the window's top padding below it as terminal ground. The pill was then centred in the bar alone, so it read high against the first terminal row. Extend the header band through that padding, paint it as chrome and take clicks there, and centre the pill in the band. The band now has equal space above and below its pill. The bottom quote is drawn in the gutter below the last row, but the default half-cell bottom padding is shorter than its line box. Centring the box pushed it below the window edge and clipped it. Centre the ink instead, and let it rise over the line box of the last row when the gutter is too short, with a small bottom margin. The quote now stays whole at the bottom of short windows and reads centred in its gutter.
AppKit rounds the window frame, but does not reliably clip the full-size content view underneath it while the window is see-through. The terminal then showed square corners inside the rounded frame, and inside the Liquid Glass its content view is a separate surface that the effect view's rounding does not reach either. Clip the content view, and the glass and blur it can sit in, to the window's own corner radius while the window is see-through. Opaque windows and windows without full-size content are left to AppKit.
config_did_change runs while the window is still being built, before AppKit has necessarily settled the window's private corner radius. A window opened already see-through could therefore keep a square content view until some later configuration change. Reapply the radius to the content view, the glass and its blur once the window is on screen.
A full-screen TUI such as OpenCode paints a rectangular surface inside the rounded window, leaving its corners square. Paint a terminal-corner pass after the content that clears the alpha channel in the wedge outside a rounded corner while leaving RGB alone; the see-through window then shows the glass behind those wedges instead of a painted approximation of it. The pass is armed only when the visible grid's top and bottom edges carry a background of the program's own, so a shell prompt or a one-off coloured cell does not lose part of its first glyph. It follows the same radius on OpenGL and WebGPU, and does not change the terminal's rows or columns.
Mirr0ch1
force-pushed
the
fix/translucent-ui-spacing
branch
from
October 26, 2026 19:51
0553c45 to
b50b69f
Compare
The quote was placed inside the gutter below the last terminal row. That gutter is only the padding plus what the row grid left over, so it grows by whole cells as the window grows and collapses when a row is added. Centring the quote in it made the quote climb in cell-sized steps while the window edge was dragged, and when the gutter was shorter than the line box the box was pushed past the window edge and clipped. Anchor the visible ink a small margin above the window's bottom edge instead. The quote now follows the edge pixel for pixel at every window height. When the gutter is too short, the ink rises over the last row's line box rather than out of the window; it is never clipped.
Contributor
Author
|
Pushed a follow-up commit for item 2: the quote is no longer centred in the leftover gutter. It is anchored by its visible ink a fixed margin above the window's bottom edge, so live-resizing the window moves it pixel for pixel instead of in cell-sized jumps, and it cannot be pushed below the window. The same reason kept the earlier version from fully fixing what testing showed: the gutter is measured from the row grid, which snaps by whole cells. |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Four seams in a see-through window, fixed without changing the terminal's rows or columns:
Pane header sat high. A pane's nav bar was painted only to its own height, leaving the window's top padding below it as terminal ground. The pill was then centred in the bar alone, so the space above it was smaller than the space below. The header band now paints and takes clicks through that padding, and the pill is centred in the whole band. The terminal grid is untouched.
The bottom quote was clipped and moved in cell-sized steps. The quote lives in the gutter below the last row, but that gutter is only the padding plus what the row grid left over: centring the quote in it made the quote climb in jumps as rows were added or removed, and when the gutter was shorter than its line box the box was pushed below the window edge. The quote's visible ink is now anchored a small margin above the window's bottom edge, so it follows the edge pixel for pixel; when the gutter is short it rises over the line box of the last row instead of being clipped. Changing the quote font size still does not reflow the terminal.
A TUI's painted surface had square corners inside the rounded, see-through window. A full-screen TUI such as OpenCode paints a rectangular background into the terminal grid. The corner wedges outside a rounded corner now go through a dedicated pass that clears their alpha while leaving RGB alone, so the glass behind the window shows through instead of a solid approximation of it. OpenGL and WebGPU each get an erase pipeline for that pass. It is armed only when the visible grid's top and bottom edges carry a background of the program's own, so a shell prompt or a one-off coloured cell does not lose part of its first glyph.
macOS content view clipping. AppKit rounds the window frame but does not reliably clip the full-size content view underneath it while the window is see-through; the content view, the Liquid Glass and its blur are clipped to the window's radius, and the clip is removed when the window is opaque or no longer uses full-size content.
Validation
cargo test -p wezterm-gui: 1306 passed, 1 ignored.cargo test -p thinkterm-render: 35 passed.cargo check -p wezterm-guiandcargo check -p thinkterm-web.0.3.6-ui.6) was built locally on Apple silicon, installed, and tested with OpenCode and Liquid Glass: the terminal's painted surface now has rounded corners and the glass shows through them.No new dependencies.
Third-party material
None.
Contributor agreement
I agree to the ThinkTerm Contributor Agreement version 1.1 for this contribution.