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

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

Re: Disabling M-q


From: Cecil Westerhof
Subject: Re: Disabling M-q
Date: Tue, 21 May 2013 10:13:22 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux)

Op donderdag 16 mei 2013 04:59 CEST schreef Yuri Khan:

> On Wed, May 15, 2013 at 10:31 PM, Cecil Westerhof <Cecil@decebal.nl> wrote:
>> A friend asked how to disable M-q. My first thought was:
>> (local-unset-key (kbd "\M-q"))
>> or
>> (local-set-key (kbd "M-q") nil)
>
> You need to unset the key in the map that sets it, or override it
> with another function in a higher-priority map (as you do below with
> the empty string, which is not a proper function).
>
>> But both did not work. I am now using:
>> (local-set-key (kbd "M-q") "")
>>
>> and this works. Is this the best way, or is there a better way?
>
> You could bind the `ignore' function discussed recently on this
> list.

I have tried (I am not using it):
    (local-set-key (kbd "M-q") 'ignore)

and it works. I send the improved solution to my friend.

-- 
Cecil Westerhof
Senior Software Engineer
LinkedIn: http://www.linkedin.com/in/cecilwesterhof


reply via email to

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