Skip to content

Add ghost text wrapping for inline suggestions#93

Merged
FuJacob merged 1 commit into
mainfrom
jafu/suggestion-text-wrapping
May 1, 2026
Merged

Add ghost text wrapping for inline suggestions#93
FuJacob merged 1 commit into
mainfrom
jafu/suggestion-text-wrapping

Conversation

@FuJacob

@FuJacob FuJacob commented May 1, 2026

Copy link
Copy Markdown
Owner

Summary

  • Adds a dedicated ghost suggestion layout helper that wraps overflowing suggestion text onto additional overlay lines instead of letting it run past the focused input frame.
  • Threads overlay geometry through coordinator, presenter, overlay state, and controller so the first line can start at the caret while wrapped lines align to the input frame's left edge.
  • Updates presentation and session tests to cover wrapped layout, overlay geometry, and acceptance behavior with the new state shape.

Validation

  • swiftlint .
    • Found 0 violations, 0 serious in 78 files.
  • git diff --check origin/main...HEAD
    • Exit 0.
  • xcodebuild test -scheme tabby -destination 'platform=macOS' CODE_SIGNING_ALLOWED=NO
    • TEST SUCCEEDED; 151 tests, 0 failures.

Linked issues

Refs #94

Risk / rollout notes

  • This is an approximate visual wrapping pass based on available caret/input geometry and observed character width. It improves overflow behavior, but it does not fully solve the follow-up bug where some host editors reflow accepted text before AX exposes the refreshed caret/text-node geometry.
  • The unsigned test run still prints the existing llama/Metal shutdown assert after XCTest finishes, but xcodebuild exits successfully and reports TEST SUCCEEDED.

@FuJacob FuJacob merged commit 5614fb5 into main May 1, 2026
3 checks passed
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.

1 participant