Fix typos

pull/692/head
Howard Halim 1 year ago committed by GitHub
parent fafad6c961
commit cd7136ccc3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -289,7 +289,7 @@ impl Buffer {
continue; continue;
} }
// `x_offset + width > max_offset` could be integer overflow on 32-bit machines if we // `x_offset + width > max_offset` could be integer overflow on 32-bit machines if we
// change dimenstions to usize or u32 and someone resizes the terminal to 1x2^32. // change dimensions to usize or u32 and someone resizes the terminal to 1x2^32.
if width > max_offset.saturating_sub(x_offset) { if width > max_offset.saturating_sub(x_offset) {
break; break;
} }
@ -434,9 +434,9 @@ impl Buffer {
let width = self.area.width; let width = self.area.width;
let mut updates: Vec<(u16, u16, &Cell)> = vec![]; let mut updates: Vec<(u16, u16, &Cell)> = vec![];
// Cells invalidated by drawing/replacing preceeding multi-width characters: // Cells invalidated by drawing/replacing preceding multi-width characters:
let mut invalidated: usize = 0; let mut invalidated: usize = 0;
// Cells from the current buffer to skip due to preceeding multi-width characters taking their // Cells from the current buffer to skip due to preceding multi-width characters taking their
// place (the skipped cells should be blank anyway): // place (the skipped cells should be blank anyway):
let mut to_skip: usize = 0; let mut to_skip: usize = 0;
for (i, (current, previous)) in next_buffer.iter().zip(previous_buffer.iter()).enumerate() { for (i, (current, previous)) in next_buffer.iter().zip(previous_buffer.iter()).enumerate() {

Loading…
Cancel
Save