ProgerXP / Notepad2e

Word highlighting, simultaneous editing, split views, math evaluation, un/grep, comment reformatting, UAC elevation, complete regexps (PCRE), Lua lexers, DPI awareness and more (XP+)
Other
370 stars 52 forks source link

Shift/Ctrl+Alt+Left/Right to navigate word start/end #436

Closed ProgerXP closed 1 year ago

ProgerXP commented 1 year ago

This is like E gE in Vim (e ge are mostly the same as non-accelerated Ctrl+Left/Right).

Cursor is placed before first/after last symbol in the word as if in accelerated mode (regardless of the setting #89).

Chart of cursor positions for different hotkeys:

aa  aa..  ..aa                    <- original document or line contents

 a a • • a a . . • • . . a a      • = space
|       |           |       |     accelerated Ctrl+Left/Right
|       |   |       |   |   |     regular Ctrl+Left/Right
|   |           |           |     Ctrl+Alt+Left/Right

When pressed with Shift held down (Shift+Ctrl+Alt+Left and Shift+Ctrl+Alt+Right), extend selection in addition to moving the caret.

New companion combinations: Shift+Alt+Del and Shift+Alt+Backspace to delete up to this/previous word's end (not to word's start as Ctrl/Alt+Del/Backspace). Would use Clrl+Alt for these but Ctrl+Alt+Del is obviously unavailable.

cshnik commented 1 year ago

Done.