Repository navigation
Fix unified diff rendering with taller emoji glyphs - #3074
Open
tobiasmelcher wants to merge 1 commit into
Open
tobiasmelcher wants to merge 1 commit into
tobiasmelcher wants to merge 1 commit into
Conversation
Reserve and paint glyph-aware code-mining heights so emoji fallback fonts do not overlap source lines. Keep click-through text aligned and fill source-row backgrounds across increased line spacing.
Contributor
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.
Emoji fallback fonts can exceed the editor's base line height. Unified-diff code minings previously painted successive rows at the shorter base height, so emoji glyphs could overlap adjacent rows and extend into the following source line. The selectable click-through overlay could also require more height than the mining reserved. This change uses consistent glyph-aware heights for reserved space, painting, detailed backgrounds, and selectable text, without changing copied text.
Source-row diff highlighting now covers the full row height when emoji fallback fonts enlarge the editor's rows, eliminating the white stripes between highlighted lines.
Emoji mining rendering
Before: adjacent emoji glyphs touch or overlap, and the final emoji row extends into the following source row.
After: emoji rows have sufficient vertical space, and the final row remains inside the mining background.
Full-height source backgrounds
Before: taller source rows leave white stripes in the diff background.
After: the diff background covers the full source-row height.
The screenshots also expose a separate whitespace-marker baseline misalignment on emoji-expanded source rows. That behavior reproduces independently of Compare drawing and is not addressed by this PR.