Skip to content

Fix decorated ranges at soft-wrap boundaries - #178

Merged
wingleeio merged 1 commit into
zeronsh:mainfrom
gaelcado:codex/fix-inline-code-wrap-rendering
Aug 20, 2026
Merged

wingleeio merged 1 commit into
zeronsh:mainfrom
gaelcado:codex/fix-inline-code-wrap-rendering

Conversation

@gaelcado

@gaelcado gaelcado commented Aug 19, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • preserve the first decorated glyph when an inline-code or selection range starts at a soft-wrap boundary
  • keep continuation rectangles anchored to the start of their visual row
  • add focused regression coverage for ranges that start at and cross a soft wrap

Closes #177

Root cause

GPUI reports a soft-wrap boundary with upstream affinity, placing the boundary index at the end of the preceding visual row. The range walker then advanced past that shared boundary and omitted the first glyph on the continuation row.

Before / after

Before After
Before: first inline-code glyph omitted from the background After: inline-code background includes the first continuation glyph

Validation

  • cargo test -p zeron-ui soft_wrap (3 passed)
  • git diff --check origin/main...HEAD

Scope

This changes only Markdown decorated-range geometry and its unit tests. It introduces no settings, migrations, or accessibility changes.

@gaelcado
gaelcado marked this pull request as ready for review August 19, 2026 19:31
@wingleeio
wingleeio merged commit 265204b into zeronsh:main Aug 20, 2026
1 check passed
guilhermexp pushed a commit to guilhermexp/comet that referenced this pull request Aug 30, 2026
…ap-rendering

Fix decorated ranges at soft-wrap boundaries
@gaelcado
gaelcado deleted the codex/fix-inline-code-wrap-rendering branch October 1, 2026 11:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Inline-code background omits the first glyph after a soft wrap

2 participants