fix: don't clip leading whitespace based on cursor column in smart_insert_line
This commit is contained in:
parent
9026404d6d
commit
cd1d9f3042
1 changed files with 1 additions and 1 deletions
|
|
@ -4522,7 +4522,7 @@ pub const Editor = struct {
|
|||
|
||||
fn cursel_smart_insert_line(self: *Self, root: Buffer.Root, cursel: *CurSel, b_allocator: std.mem.Allocator, mode: WSCollapseMode) !Buffer.Root {
|
||||
const row = cursel.cursor.row;
|
||||
const leading_ws = @min(find_first_non_ws(root, row, self.metrics), cursel.cursor.col);
|
||||
const leading_ws = find_first_non_ws(root, row, self.metrics);
|
||||
var sfa = std.heap.stackFallback(512, self.allocator);
|
||||
const sfa_allocator = sfa.get();
|
||||
var stream: std.Io.Writer.Allocating = .init(sfa_allocator);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue