help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Changing behavior of backward-word?


From: Johanjo
Subject: Re: Changing behavior of backward-word?
Date: Wed, 08 Dec 2010 15:35:34 -0000
User-agent: G2/1.0

On Nov 10, 7:52 am, Tim X <t...@nospam.dev.null> wrote:
> Elena <egarr...@gmail.com> writes:
> > On Oct 31, 10:27 pm, Johan Json <wow...@gmail.com> wrote:
> >> Afterthought, would this possibly break other user modes dependant on
> >> key M-b and/or 'backward-word'?
>
> > It would not.  This is basic Emacs customization.  Here is the code:
>
> > (defun my-backward-word ()
> >   (interactive)
> >   (backward-word)
> >   (backward-char))
>
> > (global-set-key (kbd "M-b") #'my-backward-word)
>
> Keeping in mind of course that if any mode rebinds M-b in a local key
> map, it will override the global definition. However, this would
> normally indicate the mode defines a new interpretation for
> backward-word and that interpretation probably makes more sense
> (otherwise the mode would not bother). If you notice your backward word
> behavior does not seem to work in some specific mode, this is likely the
> reason.
>
> Tim
>
> --
> tcross (at) rapttech dot com dot au

Thanks a _lot_, exactly what I was looking for!

//Johan


reply via email to

[Prev in Thread] Current Thread [Next in Thread]