refactor: rename Buffer.del_chars to Buffer.delete_bytes

This commit is contained in:
CJ van den Berg 2024-12-19 22:41:26 +01:00
parent f134fdb747
commit d3b12774c4
Signed by: neurocyte
GPG key ID: 8EB1E1BB660E3FB9
2 changed files with 10 additions and 10 deletions

View file

@ -644,10 +644,10 @@ const Node = union(enum) {
};
_ = self.get_range(sel, null, &size, null, metrics) catch return error.Stop;
const pos = try self.get_line_width_to_pos(sel.begin.row, sel.begin.col, metrics);
return self.del_chars(sel.begin.row, pos, size, allocator, metrics) catch return error.Stop;
return self.delete_bytes(sel.begin.row, pos, size, allocator, metrics) catch return error.Stop;
}
pub fn del_chars(self: *const Node, line: usize, pos_: usize, bytes: usize, allocator: Allocator, metrics_: Metrics) !Root {
pub fn delete_bytes(self: *const Node, line: usize, pos_: usize, bytes: usize, allocator: Allocator, metrics_: Metrics) !Root {
const Ctx = struct {
allocator: Allocator,
pos: usize,