I have a little problem with the way the backward-word and backward-kill-word commands work. When I click backward-kill-word on a line that represents only white spaces (for example, the first char of the line to be indented), the command will kill all the white space, as well as the last word of the previous line.
This behavior is completely unintuitive for me. I prefer, for example, that it works in Eclipse, which will kill whitespace before the start of the line the first time you press "backward-kill-word", it will move to the end of the previous line the next time you press, and only then will the word wipe from the end of the line.
I am sure that this behavior is used by default in most applications (since it seems more intuitive, probably because I'm used to it, but I'm not sure), so I wonder if there is a way to configure Emacs for this behavior. Several searches on Google, unfortunately, showed nothing.
thanks
EDIT:
Thanks to everyone for the answers (including the elisp code that does what I requested).
The same problem arises, obviously, with the forward-kill-word command and move commands, and I was hoping that emacs has only some custom flag to change the behavior, but it seems like I'm just going to these elisp functions and reordering the default commands and killing teams for these.
Elimis
source share