mirror of
https://github.com/zed-industries/zed.git
synced 2026-12-04 03:23:21 +01:00
agent_ui: Hide wrap guides in the agent message editor (#64886)
## Summary Closes #55958 When no conversation has started yet, the agent panel's message editor uses `EditorMode::Full`. Wrap guides are only drawn in full mode, so a user's `wrap_guides` setting (for example `"wrap_guides": [100]`) showed a vertical line across the empty agent panel. The line does nothing useful there. The message editor already turns off indent guides. This PR turns off wrap guides in the same place, the same way the inline assistant's prompt editor already does (`inline_assistant.rs`). ## Testing 1. Add `"wrap_guides": [50]` to `settings.json`. 2. Open the agent panel before starting a conversation, and make it wide enough to reach column 50. 3. Before this change a vertical wrap guide shows in the empty panel. After it, none shows. `cargo clippy -p agent_ui --all-targets -- --deny warnings` and `cargo fmt --check` pass. ## Self-review - [ ] I've reviewed my diff for quality, security, reliability, and performance. - [ ] UI changes follow the [checklist](https://zed.dev/docs/development/ui-checklist). - [ ] Tests cover the new or changed behavior. Release Notes: - Fixed wrap guides showing in the agent panel before a conversation starts.
This commit is contained in:
1 parent
5d5963361f
commit
017f9b89aa
1 file changed
+1
@@ -476,6 +476,7 @@ impl MessageEditor {
|
||||
let mut editor = Editor::new(mode, buffer, None, window, cx);
|
||||
editor.set_placeholder_text(placeholder, window, cx);
|
||||
editor.set_show_indent_guides(false, cx);
|
||||
editor.set_show_wrap_guides(false, cx);
|
||||
editor.set_show_completions_on_input(Some(true));
|
||||
editor.set_soft_wrap();
|
||||
editor.disable_mouse_wheel_zoom();
|
||||
|
||||
Reference in new issue
Block a user