Skip to content

Conversation

@romanstingler
Copy link

  • Preserve error messages during scroll actions (ScrollUp/ScrollDown)
  • Force error line to be included in render diff to prevent artifacts
  • Skip bottom-right corner cell to prevent terminal scrolling
  • Clean newlines from error messages and ensure proper width
  • Fix scroll boundary check (< instead of <=)
  • Add lifetime annotation to Change struct for better memory safety

The issue was that scrolling would corrupt the error display because
2025-12-31-16:54:45

- Preserve error messages during scroll actions (ScrollUp/ScrollDown)
- Force error line to be included in render diff to prevent artifacts
- Skip bottom-right corner cell to prevent terminal scrolling
- Clean newlines from error messages and ensure proper width
- Fix scroll boundary check (< instead of <=)
- Add lifetime annotation to Change struct for better memory safety

The issue was that scrolling would corrupt the error display because
@fcoury
Copy link
Contributor

fcoury commented Dec 31, 2025

Whoa, is this a new year's gift? Just when I thought this project was abandoned for good 😄

I will review this shortly and let you know!

@fcoury
Copy link
Contributor

fcoury commented Jan 1, 2026

Skip bottom-right corner cell to prevent terminal scrolling

CleanShot 2026-01-01 at 01 58 05@2x

This one leaves a character not filled in my terminal (using ghostty).

CleanShot 2026-01-01 at 01 58 36@2x

What terminal and OS are you using that makes the terminal scroll?

I would like to accept the PR as everything else looks good.

@fcoury
Copy link
Contributor

fcoury commented Jan 1, 2026

Feedback from Codex:

  • [P2] Skip of bottom-right cell leaves stale UI character — /Users/fcoury/code/red/src/editor/rendering.rs:909-939 The new guard in render_diff unconditionally ignores any change targeting the bottom-right cell. Several render paths (e.g., the waiting- command indicator written in draw_commandline or any status text that reaches the last column) legitimately write to that cell, and now their diff entries are silently dropped. When those values change or are cleared, the terminal will keep the previous character in the bottom-right corner, leading to persistent ghost text. This is user-visible any time content is expected to update in that cell, and the change prevents it from ever repainting.

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.

2 participants