Emacs: “M-%” shortcut being treated as simply “%”, even when “M-” works fine











up vote
1
down vote

favorite












I have no clue as to why my Emacs won't take "M-%" as the shortcut for replace. Even more strangely, in the message window it states "% is undefined", as if it doesn't get that I'm also pressing the Meta key. But the Meta key works fine: if I press "M-x" I get the expected result. As an additional information, I can see in the menu that "M-%" is bound to replace, as expected.



This is Emacs'a about:
GNU Emacs 25.2.2 (x86_64-pc-linux-gnu, GTK+ Version 3.22.21)
of 2017-09-22, modified by Debian










share|improve this question
























  • Does it work if you run emacs as $ emacs -Q? If it does, then it's probably an issue with your init file and we'd need more information about that.
    – MattHusz
    Nov 21 at 18:01












  • Good guess, but it still doesn't work
    – user3406881
    Nov 21 at 18:45






  • 1




    Sounds like your Window manager or some other program might be interfering. Can you use ESC %?
    – Drew
    Nov 21 at 18:54






  • 1




    ESC % works, indeed
    – user3406881
    Nov 21 at 19:40










  • You can also use C-h c to see what Emacs sees (though I guess it would be % in your case and that's not very informative), and also xev to see what the window manager sees (look for state and keycode). You can also try other Alt-Shift-foo key combinations to see whether they have the same problem. Also, try Emacs in a GUI versus in a terminal. Good luck!
    – ShreevatsaR
    Nov 21 at 22:18















up vote
1
down vote

favorite












I have no clue as to why my Emacs won't take "M-%" as the shortcut for replace. Even more strangely, in the message window it states "% is undefined", as if it doesn't get that I'm also pressing the Meta key. But the Meta key works fine: if I press "M-x" I get the expected result. As an additional information, I can see in the menu that "M-%" is bound to replace, as expected.



This is Emacs'a about:
GNU Emacs 25.2.2 (x86_64-pc-linux-gnu, GTK+ Version 3.22.21)
of 2017-09-22, modified by Debian










share|improve this question
























  • Does it work if you run emacs as $ emacs -Q? If it does, then it's probably an issue with your init file and we'd need more information about that.
    – MattHusz
    Nov 21 at 18:01












  • Good guess, but it still doesn't work
    – user3406881
    Nov 21 at 18:45






  • 1




    Sounds like your Window manager or some other program might be interfering. Can you use ESC %?
    – Drew
    Nov 21 at 18:54






  • 1




    ESC % works, indeed
    – user3406881
    Nov 21 at 19:40










  • You can also use C-h c to see what Emacs sees (though I guess it would be % in your case and that's not very informative), and also xev to see what the window manager sees (look for state and keycode). You can also try other Alt-Shift-foo key combinations to see whether they have the same problem. Also, try Emacs in a GUI versus in a terminal. Good luck!
    – ShreevatsaR
    Nov 21 at 22:18













up vote
1
down vote

favorite









up vote
1
down vote

favorite











I have no clue as to why my Emacs won't take "M-%" as the shortcut for replace. Even more strangely, in the message window it states "% is undefined", as if it doesn't get that I'm also pressing the Meta key. But the Meta key works fine: if I press "M-x" I get the expected result. As an additional information, I can see in the menu that "M-%" is bound to replace, as expected.



This is Emacs'a about:
GNU Emacs 25.2.2 (x86_64-pc-linux-gnu, GTK+ Version 3.22.21)
of 2017-09-22, modified by Debian










share|improve this question















I have no clue as to why my Emacs won't take "M-%" as the shortcut for replace. Even more strangely, in the message window it states "% is undefined", as if it doesn't get that I'm also pressing the Meta key. But the Meta key works fine: if I press "M-x" I get the expected result. As an additional information, I can see in the menu that "M-%" is bound to replace, as expected.



This is Emacs'a about:
GNU Emacs 25.2.2 (x86_64-pc-linux-gnu, GTK+ Version 3.22.21)
of 2017-09-22, modified by Debian







ubuntu emacs ubuntu-18.04






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 21 at 22:13









Drew

23.7k54963




23.7k54963










asked Nov 21 at 17:54









user3406881

386




386












  • Does it work if you run emacs as $ emacs -Q? If it does, then it's probably an issue with your init file and we'd need more information about that.
    – MattHusz
    Nov 21 at 18:01












  • Good guess, but it still doesn't work
    – user3406881
    Nov 21 at 18:45






  • 1




    Sounds like your Window manager or some other program might be interfering. Can you use ESC %?
    – Drew
    Nov 21 at 18:54






  • 1




    ESC % works, indeed
    – user3406881
    Nov 21 at 19:40










  • You can also use C-h c to see what Emacs sees (though I guess it would be % in your case and that's not very informative), and also xev to see what the window manager sees (look for state and keycode). You can also try other Alt-Shift-foo key combinations to see whether they have the same problem. Also, try Emacs in a GUI versus in a terminal. Good luck!
    – ShreevatsaR
    Nov 21 at 22:18


















  • Does it work if you run emacs as $ emacs -Q? If it does, then it's probably an issue with your init file and we'd need more information about that.
    – MattHusz
    Nov 21 at 18:01












  • Good guess, but it still doesn't work
    – user3406881
    Nov 21 at 18:45






  • 1




    Sounds like your Window manager or some other program might be interfering. Can you use ESC %?
    – Drew
    Nov 21 at 18:54






  • 1




    ESC % works, indeed
    – user3406881
    Nov 21 at 19:40










  • You can also use C-h c to see what Emacs sees (though I guess it would be % in your case and that's not very informative), and also xev to see what the window manager sees (look for state and keycode). You can also try other Alt-Shift-foo key combinations to see whether they have the same problem. Also, try Emacs in a GUI versus in a terminal. Good luck!
    – ShreevatsaR
    Nov 21 at 22:18
















Does it work if you run emacs as $ emacs -Q? If it does, then it's probably an issue with your init file and we'd need more information about that.
– MattHusz
Nov 21 at 18:01






Does it work if you run emacs as $ emacs -Q? If it does, then it's probably an issue with your init file and we'd need more information about that.
– MattHusz
Nov 21 at 18:01














Good guess, but it still doesn't work
– user3406881
Nov 21 at 18:45




Good guess, but it still doesn't work
– user3406881
Nov 21 at 18:45




1




1




Sounds like your Window manager or some other program might be interfering. Can you use ESC %?
– Drew
Nov 21 at 18:54




Sounds like your Window manager or some other program might be interfering. Can you use ESC %?
– Drew
Nov 21 at 18:54




1




1




ESC % works, indeed
– user3406881
Nov 21 at 19:40




ESC % works, indeed
– user3406881
Nov 21 at 19:40












You can also use C-h c to see what Emacs sees (though I guess it would be % in your case and that's not very informative), and also xev to see what the window manager sees (look for state and keycode). You can also try other Alt-Shift-foo key combinations to see whether they have the same problem. Also, try Emacs in a GUI versus in a terminal. Good luck!
– ShreevatsaR
Nov 21 at 22:18




You can also use C-h c to see what Emacs sees (though I guess it would be % in your case and that's not very informative), and also xev to see what the window manager sees (look for state and keycode). You can also try other Alt-Shift-foo key combinations to see whether they have the same problem. Also, try Emacs in a GUI versus in a terminal. Good luck!
– ShreevatsaR
Nov 21 at 22:18

















active

oldest

votes











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














 

draft saved


draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53417963%2femacs-m-shortcut-being-treated-as-simply-even-when-m-works-fine%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown






























active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes
















 

draft saved


draft discarded



















































 


draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53417963%2femacs-m-shortcut-being-treated-as-simply-even-when-m-works-fine%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Catalogne

Violoncelliste

Héron pourpré