vim: Fix `cw` with count greater than 1 not preserving whitespace correctly (#56585)

In vim, `c {count} w` diverges from the default `w` motion behavior: For
change operations, the `w` motion will be treated like the `e` motion if
the cursor is on a word, preserving whitespace after the N-th word. In
zed, this special case was only implemented for a count of 1, falling
back to incorrectly using the `w` motion if the count is greater than 1.

This PR generalizes this implementation to handle this special case for
any count.

Self-Review Checklist:

- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable

Closes #56563.

Release Notes:

- Fixed: vim `cw` with count greater than 1 not preserving whitespace
correctly

---------

Co-authored-by: dino <dinojoaocosta@gmail.com>
3fc012ef4bdavidhi7 committed on 6/18/2026, 2:50:31 PM· committed by GitHubparentadb8a1d
2 files changedLine totals unavailable