GNU bug report logs -
#31204
25.3; Make word motion more customizable
Previous Next
Reported by: Yuri Khan <yuri.v.khan <at> gmail.com>
Date: Wed, 18 Apr 2018 08:56:01 UTC
Severity: wishlist
Tags: moreinfo, wontfix
Found in version 25.3
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
Message #8 received at 31204 <at> debbugs.gnu.org (full text, mbox):
Yuri Khan <yuri.v.khan <at> gmail.com> writes:
> While trying to make word motion commands (Ctrl+left/right, M-f/b) more
> similar to that implemented in other editors:
>
> http://lists.gnu.org/archive/html/help-gnu-emacs/2018-04/msg00230.html
>
> I encountered a difficulty.
[...]
> Step 1, on the other hand, is not customizable at all.
>
> The specific behavior that I was trying to implement was to find the
> nearest transition:
>
> * from a word character to a non-word character, OR
> * from a non-word non-whitespace character to a word character, OR
> * from a non-word non-whitespace character to a whitespace character.
>
> As an illustration (where ‘|’ specifies word motion stops when going
> left to right):
>
> foo| ***| +++| (|bar|)|
> ^
[...]
> Perhaps it would be nice to have an optional hook for step 1 of
> ‘forward-word’, a function that would take two arguments POS and LIMIT,
> and returning the starting word boundary position from which step 2 would
> then work.
(I'm going through old bug reports that unfortunately weren't resolved
at the time.)
I think this sounds like it could be useful. If we added such a hook to
`forward-word', what would the rest of the code look like to make
`C-<right>' work this way?
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
This bug report was last modified 3 years and 32 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.