mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-26 03:09:08 +00:00
In Vim's insert mode, Ctrl-W deletes the word before the cursor, like Ctrl-Backspace. Unlike Ctrl-Backspace, if only whitespace exists between the end of the word and the cursor, the word will be deleted with the whitespace. To do so, this commit introduces two methods: delete_previous_word() for TextEditor and first_word_before() for TextDocument, where the former depends on the latter. delete_previous_word() is then called in VimEditingEngine.
7.7 KiB
7.7 KiB