diff --git a/src/bin/edit/draw_filepicker.rs b/src/bin/edit/draw_filepicker.rs index 335bee4fb498..2287899ff712 100644 --- a/src/bin/edit/draw_filepicker.rs +++ b/src/bin/edit/draw_filepicker.rs @@ -204,7 +204,7 @@ fn draw_file_picker_update_path(state: &mut State) -> Option { // we can detect this by checking if the length of the path didn't change. let dir = if cfg!(windows) && state.file_picker_pending_name == Path::new("..") - // It's unneccessary to check the contents of the paths. + // It's unnecessary to check the contents of the paths. && old_path.as_os_str().len() == path.as_os_str().len() { Path::new("") diff --git a/src/buffer/mod.rs b/src/buffer/mod.rs index d1679a06a867..1c7ae3c24c7b 100644 --- a/src/buffer/mod.rs +++ b/src/buffer/mod.rs @@ -1240,7 +1240,7 @@ impl TextBuffer { self.measurement_config().with_cursor(top).goto_logical(bottom.logical_pos); // The second problem is that visual positions can be ambiguous. A single logical position - // can map to two visual positions: One at the end of the preceeding line in front of + // can map to two visual positions: One at the end of the preceding line in front of // a word wrap, and another at the start of the next line after the same word wrap. // // This, however, only applies if we go upwards, because only then `bottom ≅ cursor`, diff --git a/src/framebuffer.rs b/src/framebuffer.rs index 586f1e76a015..a9ff35a64a97 100644 --- a/src/framebuffer.rs +++ b/src/framebuffer.rs @@ -621,7 +621,7 @@ impl LineBuffer { if left + cursor.visual_pos.x < 0 && cursor.offset < text.len() { // `-left` must've intersected a wide glyph and since goto_visual stops _before_ reaching the target, - // we stoped before the wide glyph and thus must step forward to the next glyph. + // we stopped before the wide glyph and thus must step forward to the next glyph. cursor = cfg.goto_logical(Point { x: cursor.logical_pos.x + 1, y: 0 }); } diff --git a/src/tui.rs b/src/tui.rs index 442cd95e1f2e..7a22e3c79cd7 100644 --- a/src/tui.rs +++ b/src/tui.rs @@ -3207,7 +3207,7 @@ impl<'a> Context<'a, '_> { match style.accelerator { Some(accelerator) if accelerator.is_ascii_uppercase() => { // Complex case: - // Locate the offset of the acclerator character in the label text + // Locate the offset of the accelerator character in the label text let mut off = text.len(); for (i, c) in text.bytes().enumerate() { // Perfect match (uppercase character) --> stop