vim: Fix character count in visual line mode (#28669)

Closes https://github.com/zed-industries/zed/issues/10727

Release Notes:

- vim: Fixed character count in visual line mode

Co-authored-by: Conrad Irwin <conrad@zed.dev>
This commit is contained in:
5brian 2025-04-18 00:14:44 -04:00 committed by GitHub
parent 72218f4a61
commit 6254efe39d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -99,7 +99,7 @@ impl CursorPosition {
let mut last_selection = None::<Selection<Point>>;
let snapshot = editor.buffer().read(cx).snapshot(cx);
if snapshot.excerpts().count() > 0 {
for selection in editor.selections.all::<Point>(cx) {
for selection in editor.selections.all_adjusted(cx) {
let selection_summary = snapshot
.text_summary_for_range::<text::TextSummary, _>(
selection.start..selection.end,