feat(panel): add mark_placement option for selection marks location#90
Conversation
There was a problem hiding this comment.
Pull request overview
Adds a new file_panel.mark_placement configuration option to control whether selection marks are rendered inline (current behavior) or placed in the sign column to avoid text alignment shifts in the file panel.
Changes:
- Introduces
file_panel.mark_placement = "inline" | "sign_column"with documentation and default config updates. - Updates diff view panel rendering to suppress inline marks in
sign_columnmode and instead place selection marks via sign extmarks. - Adds functional tests covering config persistence and sign-column mark behavior for file entries.
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| lua/diffview/ui/panel.lua | Uses :redraw() on WinResized to ensure post-render steps run on resize. |
| lua/diffview/scene/views/diff/render.lua | Implements mark_placement handling and sign-column extmark placement for selection marks. |
| lua/diffview/scene/views/diff/file_panel.lua | Overrides :redraw() to place selection signs after buffer render. |
| lua/diffview/config.lua | Adds the file_panel.mark_placement default. |
| doc/diffview.txt | Documents the new mark_placement option. |
| doc/diffview_defaults.txt | Updates defaults listing to include mark_placement. |
| lua/diffview/tests/functional/panel_render_spec.lua | Adds functional tests for inline vs sign-column selection mark rendering. |
| lua/diffview/tests/functional/config_options_spec.lua | Adds config option tests for mark_placement default and persistence. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
4097f95 to
0e08ce7
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 8 out of 8 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
0e08ce7 to
42bf2ef
Compare
42bf2ef to
7bf5648
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 8 out of 8 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Relates to #70 (comment).