diff --git a/crates/editor/src/editor.rs b/crates/editor/src/editor.rs index 4792c6b2cb..515cde1908 100644 --- a/crates/editor/src/editor.rs +++ b/crates/editor/src/editor.rs @@ -6671,7 +6671,11 @@ impl Editor { let is_entire_line = selection.is_empty() || self.selections.line_mode; if is_entire_line { selection.start = Point::new(selection.start.row, 0); - selection.end = cmp::min(max_point, Point::new(selection.end.row + 1, 0)); + if !selection.is_empty() && selection.end.column == 0 { + selection.end = cmp::min(max_point, selection.end); + } else { + selection.end = cmp::min(max_point, Point::new(selection.end.row + 1, 0)); + } selection.goal = SelectionGoal::None; } if is_first {