If your RETURN (aka Enter) key sends a Control-M
character, then you're out of luck: they are the same thing.
If your RETURN key sends something different, that is,
if Emacs can distinguish what it sends from C-m, then you can distinguish in
Emacs Lisp. You can bind [return] instead of C-m.
Same thing with TAB and C-i, etc. You can bind [tab] or
C-i or both (to different things). But if your TAB key always sends C-i, then
you cannot distinguish the two in Emacs Lisp. AFAIK.
I
don't quite understand what this means - I have
(global-define-key (kbd
"C-m") 'execute-extended-command)
but it also binds RETURN. How do I
make the input events distinguishable? I'm not running emacs in a
terminal.
Is
there a way to bind C-m and return to different
keybindings?
Yes, of course. The input events just
need to be distinguishable for GNU
Emacs.