* bug#18996: 24.4; Pressing Alt-g shows Esc g- when running emacs inside terminal and in GUI mode it shows M-g
@ 2014-11-08 8:37 L. Guruprasad
2016-03-05 18:14 ` Marcin Borkowski
0 siblings, 1 reply; 7+ messages in thread
From: L. Guruprasad @ 2014-11-08 8:37 UTC (permalink / raw)
To: 18996
Hi,
When I press Alt-g as part of executing the shortcut M-g g, when running
emacs within the terminal using the -nw flag, it shows up in the
minibuffer as "Esc g-". But when I run the same in the GUI Emacs, it
shows up as "M-g". This can be misleading and confusing to users who do
not know Esc and Meta keys are equivalent.
Further, when I press Alt-x, it shows up as M-x in both the
scenarios. So it doesn't look like Emacs cannot differentiate between
the two when running inside the terminal without a GUI.
I vaguely remember seeing M-g in the terminal on pressing Alt-g some
time back, maybe in an older emacs version. But not sure.
In GNU Emacs 24.4.1 (x86_64-pc-linux-gnu, GTK+ Version 3.14.3)
of 2014-10-26 on trouble, modified by Debian
System Description: Debian GNU/Linux unstable (sid)
Configured using:
`configure --build x86_64-linux-gnu --prefix=/usr
--sharedstatedir=/var/lib --libexecdir=/usr/lib
--localstatedir=/var/lib --infodir=/usr/share/info
--mandir=/usr/share/man --with-pop=yes
--enable-locallisppath=/etc/emacs24:/etc/emacs:/usr/local/share/emacs/24.4/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/24.4/site-lisp:/usr/share/emacs/site-lisp
--build x86_64-linux-gnu --prefix=/usr --sharedstatedir=/var/lib
--libexecdir=/usr/lib --localstatedir=/var/lib
--infodir=/usr/share/info --mandir=/usr/share/man --with-pop=yes
--enable-locallisppath=/etc/emacs24:/etc/emacs:/usr/local/share/emacs/24.4/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/24.4/site-lisp:/usr/share/emacs/site-lisp
--with-x=yes --with-x-toolkit=gtk3 --with-toolkit-scroll-bars
'CFLAGS=-g -O2 -fstack-protector-strong -Wformat
-Werror=format-security -Wall' CPPFLAGS=-D_FORTIFY_SOURCE=2
LDFLAGS=-Wl,-z,relro'
Important settings:
value of $LANG: en_IN.utf8
locale-coding-system: utf-8-unix
Major mode: Lisp Interaction
Minor modes in effect:
ido-everywhere: t
yas-global-mode: t
yas-minor-mode: t
global-linum-mode: t
linum-mode: t
tooltip-mode: t
electric-indent-mode: t
mouse-wheel-mode: t
tool-bar-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
column-number-mode: t
line-number-mode: t
transient-mark-mode: t
Recent input:
ESC [ > 1 ; 3 8 0 1 ; 0 c ESC x r e p o r t - e RET
C-g C-g ESC x g DEL DEL ESC x C-g ESC x r e RET C-g
ESC g C-g ESC x r e p RET
Recent messages:
[yas] Loading for `emacs-lisp-mode', just-in-time: (lambda nil
(yas--load-directory-1 (quote
/home/guruprasad/.emacs.d/elpa/yasnippet-20140729.1240/snippets/emacs-lisp-mode)
(quote emacs-lisp-mode)))!
[yas] Loading compiled snippets from
/home/guruprasad/.emacs.d/elpa/yasnippet-20140729.1240/snippets/emacs-lisp-mode
[yas] Loading for `prog-mode', just-in-time: (lambda nil
(yas--load-directory-1 (quote
/home/guruprasad/.emacs.d/elpa/yasnippet-20140729.1240/snippets/prog-mode)
(quote prog-mode)))!
[yas] Loading compiled snippets from
/home/guruprasad/.emacs.d/elpa/yasnippet-20140729.1240/snippets/prog-mode
Loading
/home/guruprasad/.emacs.d/elpa/yasnippet-20140729.1240/snippets/prog-mode/.yas-setup...done
For information about GNU Emacs and the GNU system, type C-h C-a.
Quit [2 times]
delete-backward-char: Text is read-only
Quit [3 times]
M-g C-g is undefined
Load-path shadows:
/usr/share/emacs/site-lisp/golang-mode/go-mode hides
/usr/share/emacs/24.4/site-lisp/golang-mode/go-mode
/usr/share/emacs/site-lisp/golang-mode/go-mode-load hides
/usr/share/emacs/24.4/site-lisp/golang-mode/go-mode-load
/usr/share/emacs/24.4/site-lisp/debian-startup hides
/usr/share/emacs/site-lisp/debian-startup
/usr/share/emacs24/site-lisp/dictionaries-common/ispell hides
/usr/share/emacs/24.4/lisp/textmodes/ispell
/usr/share/emacs/site-lisp/rst hides
/usr/share/emacs/24.4/lisp/textmodes/rst
/usr/share/emacs24/site-lisp/dictionaries-common/flyspell hides
/usr/share/emacs/24.4/lisp/textmodes/flyspell
Features:
(shadow sort gnus-util mail-extr emacsbug message format-spec rfc822 mml
mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev
gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util
help-fns mail-prsvr mail-utils smex xterm time-date info magit-autoloads
git-rebase-mode-autoloads git-commit-mode-autoloads cl-macs
pkg-info-autoloads epl-autoloads pungi-autoloads jedi-autoloads
auto-complete-autoloads popup-autoloads epc-autoloads ctable-autoloads
concurrent-autoloads python-environment-autoloads deferred-autoloads
smex-autoloads yasnippet-autoloads edmacro kmacro ido yasnippet
help-mode easymenu cl gv cl-loaddefs cl-lib package epg-config linum
go-mode-load tooltip electric uniquify ediff-hook vc-hooks
lisp-float-type mwheel x-win x-dnd tool-bar dnd fontset image regexp-opt
fringe tabulated-list newcomment lisp-mode prog-mode register page
menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock
syntax facemenu font-core frame cham georgian utf-8-lang misc-lang
vietnamese tibetan thai tai-viet lao korean japanese hebrew greek
romanian slovak czech european ethiopic indian cyrillic chinese
case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer nadvice
loaddefs button faces cus-face macroexp files text-properties overlay
sha1 md5 base64 format env code-pages mule custom widget
hashtable-print-readable backquote make-network-process dbusbind
gfilenotify dynamic-setting system-font-setting font-render-setting
move-toolbar gtk x-toolkit x multi-tty emacs)
Memory information:
((conses 16 144727 5953)
(symbols 48 22691 0)
(miscs 40 44 90)
(strings 32 28993 4270)
(string-bytes 1 746905)
(vectors 16 14075)
(vector-slots 8 459565 1712)
(floats 8 403 291)
(intervals 56 252 1)
(buffers 960 12)
(heap 1024 24304 809))
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#18996: 24.4; Pressing Alt-g shows Esc g- when running emacs inside terminal and in GUI mode it shows M-g
2014-11-08 8:37 bug#18996: 24.4; Pressing Alt-g shows Esc g- when running emacs inside terminal and in GUI mode it shows M-g L. Guruprasad
@ 2016-03-05 18:14 ` Marcin Borkowski
2016-03-05 18:52 ` Eli Zaretskii
0 siblings, 1 reply; 7+ messages in thread
From: Marcin Borkowski @ 2016-03-05 18:14 UTC (permalink / raw)
To: L. Guruprasad; +Cc: 18996
On 2014-11-08, at 14:07, "L. Guruprasad" <lgp171188@gmail.com> wrote:
> Hi,
>
> When I press Alt-g as part of executing the shortcut M-g g, when running
> emacs within the terminal using the -nw flag, it shows up in the
> minibuffer as "Esc g-". But when I run the same in the GUI Emacs, it
> shows up as "M-g". This can be misleading and confusing to users who do
> not know Esc and Meta keys are equivalent.
Confirmed on GNU Emacs 25.1.50.6 (commit ac9a931).
> Further, when I press Alt-x, it shows up as M-x in both the
> scenarios. So it doesn't look like Emacs cannot differentiate between
> the two when running inside the terminal without a GUI.
This is not true: M-x is bound (by default) to
`execute-extended-command', which calls `read-extended-command', which
has at one point the literal string "M-x ", which is fed (via
a `concat', which shows prefix arguments, if any) directly to
`completing-read'.
> I vaguely remember seeing M-g in the terminal on pressing Alt-g some
> time back, maybe in an older emacs version. But not sure.
No idea, though I doubt.
All in all, I'll assign this a "wishlist" level - I agree with the OP
that it would be nice to have this solved, but I don't think this would
really confuse anyone. (IMHO, if someone uses Emacs in a terminal, s?he
probably is advanced enough to know that M-g and Esc g are equivalent.)
--
Marcin Borkowski
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#18996: 24.4; Pressing Alt-g shows Esc g- when running emacs inside terminal and in GUI mode it shows M-g
2016-03-05 18:14 ` Marcin Borkowski
@ 2016-03-05 18:52 ` Eli Zaretskii
2016-03-08 16:47 ` Marcin Borkowski
0 siblings, 1 reply; 7+ messages in thread
From: Eli Zaretskii @ 2016-03-05 18:52 UTC (permalink / raw)
To: Marcin Borkowski; +Cc: 18996, lgp171188
> From: Marcin Borkowski <mbork@mbork.pl>
> Date: Sat, 05 Mar 2016 19:14:17 +0100
> Cc: 18996@debbugs.gnu.org
>
> > When I press Alt-g as part of executing the shortcut M-g g, when running
> > emacs within the terminal using the -nw flag, it shows up in the
> > minibuffer as "Esc g-". But when I run the same in the GUI Emacs, it
> > shows up as "M-g". This can be misleading and confusing to users who do
> > not know Esc and Meta keys are equivalent.
>
> Confirmed on GNU Emacs 25.1.50.6 (commit ac9a931).
>
> > Further, when I press Alt-x, it shows up as M-x in both the
> > scenarios. So it doesn't look like Emacs cannot differentiate between
> > the two when running inside the terminal without a GUI.
>
> This is not true: M-x is bound (by default) to
> `execute-extended-command', which calls `read-extended-command', which
> has at one point the literal string "M-x ", which is fed (via
> a `concat', which shows prefix arguments, if any) directly to
> `completing-read'.
>
> > I vaguely remember seeing M-g in the terminal on pressing Alt-g some
> > time back, maybe in an older emacs version. But not sure.
>
> No idea, though I doubt.
>
> All in all, I'll assign this a "wishlist" level - I agree with the OP
> that it would be nice to have this solved
To have what solved?
If you type "C-h l" after M-x, what do you see?
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#18996: 24.4; Pressing Alt-g shows Esc g- when running emacs inside terminal and in GUI mode it shows M-g
2016-03-05 18:52 ` Eli Zaretskii
@ 2016-03-08 16:47 ` Marcin Borkowski
2016-03-08 17:10 ` Eli Zaretskii
0 siblings, 1 reply; 7+ messages in thread
From: Marcin Borkowski @ 2016-03-08 16:47 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: 18996, lgp171188
On 2016-03-05, at 19:52, Eli Zaretskii <eliz@gnu.org> wrote:
>> From: Marcin Borkowski <mbork@mbork.pl>
>> Date: Sat, 05 Mar 2016 19:14:17 +0100
>> Cc: 18996@debbugs.gnu.org
>>
>> > When I press Alt-g as part of executing the shortcut M-g g, when running
>> > emacs within the terminal using the -nw flag, it shows up in the
>> > minibuffer as "Esc g-". But when I run the same in the GUI Emacs, it
>> > shows up as "M-g". This can be misleading and confusing to users who do
>> > not know Esc and Meta keys are equivalent.
>>
>> Confirmed on GNU Emacs 25.1.50.6 (commit ac9a931).
>>
>> > Further, when I press Alt-x, it shows up as M-x in both the
>> > scenarios. So it doesn't look like Emacs cannot differentiate between
>> > the two when running inside the terminal without a GUI.
>>
>> This is not true: M-x is bound (by default) to
>> `execute-extended-command', which calls `read-extended-command', which
>> has at one point the literal string "M-x ", which is fed (via
>> a `concat', which shows prefix arguments, if any) directly to
>> `completing-read'.
>>
>> > I vaguely remember seeing M-g in the terminal on pressing Alt-g some
>> > time back, maybe in an older emacs version. But not sure.
>>
>> No idea, though I doubt.
>>
>> All in all, I'll assign this a "wishlist" level - I agree with the OP
>> that it would be nice to have this solved
>
> To have what solved?
>
> If you type "C-h l" after M-x, what do you see?
AFAIU, OP wants to see "M-g-" and not "ESC g-" after pressing M-g in an
Emacs session in a terminal. This looks reasonable to me, though
definitely not a high priority. If it's not possible/desirable, it
would be better to close this as "wontfix", but I do not know that.
Best,
--
Marcin Borkowski
http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski
Faculty of Mathematics and Computer Science
Adam Mickiewicz University
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#18996: 24.4; Pressing Alt-g shows Esc g- when running emacs inside terminal and in GUI mode it shows M-g
2016-03-08 16:47 ` Marcin Borkowski
@ 2016-03-08 17:10 ` Eli Zaretskii
2016-03-08 17:35 ` Eli Zaretskii
2016-03-09 6:01 ` Marcin Borkowski
0 siblings, 2 replies; 7+ messages in thread
From: Eli Zaretskii @ 2016-03-08 17:10 UTC (permalink / raw)
To: Marcin Borkowski; +Cc: 18996, lgp171188
> From: Marcin Borkowski <mbork@mbork.pl>
> Cc: lgp171188@gmail.com, 18996@debbugs.gnu.org
> Date: Tue, 08 Mar 2016 17:47:48 +0100
>
> >> > Further, when I press Alt-x, it shows up as M-x in both the
> >> > scenarios. So it doesn't look like Emacs cannot differentiate between
> >> > the two when running inside the terminal without a GUI.
> >>
> >> This is not true: M-x is bound (by default) to
> >> `execute-extended-command', which calls `read-extended-command', which
> >> has at one point the literal string "M-x ", which is fed (via
> >> a `concat', which shows prefix arguments, if any) directly to
> >> `completing-read'.
> >>
> >> > I vaguely remember seeing M-g in the terminal on pressing Alt-g some
> >> > time back, maybe in an older emacs version. But not sure.
> >>
> >> No idea, though I doubt.
> >>
> >> All in all, I'll assign this a "wishlist" level - I agree with the OP
> >> that it would be nice to have this solved
> >
> > To have what solved?
> >
> > If you type "C-h l" after M-x, what do you see?
>
> AFAIU, OP wants to see "M-g-" and not "ESC g-" after pressing M-g in an
> Emacs session in a terminal.
My point was that you will see "ESC g" in the "C-h l" output. Which
means Emacs _doesn't_ know how to differentiate between ESC-x and M-x,
on the level that shows the prefix key prompts, such as M-g-. What
happens here is that the command bound to "ESC x" deliberately
displays "M-x " in the echo area. IOW, "M-x" is _not_ the key echo,
it's a message displayed by a command.
In sum, Emacs doesn't have a way to distinguish between M-c and ESC c,
for any character c, on a TTY. We can only do that on a GUI frame.
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#18996: 24.4; Pressing Alt-g shows Esc g- when running emacs inside terminal and in GUI mode it shows M-g
2016-03-08 17:10 ` Eli Zaretskii
@ 2016-03-08 17:35 ` Eli Zaretskii
2016-03-09 6:01 ` Marcin Borkowski
1 sibling, 0 replies; 7+ messages in thread
From: Eli Zaretskii @ 2016-03-08 17:35 UTC (permalink / raw)
To: mbork; +Cc: 18996, lgp171188
> Date: Tue, 08 Mar 2016 19:10:51 +0200
> From: Eli Zaretskii <eliz@gnu.org>
> Cc: 18996@debbugs.gnu.org, lgp171188@gmail.com
>
> My point was that you will see "ESC g" in the "C-h l" output.
Sorry, I meant to say "ESC g" and "ESC x", not just the former.
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#18996: 24.4; Pressing Alt-g shows Esc g- when running emacs inside terminal and in GUI mode it shows M-g
2016-03-08 17:10 ` Eli Zaretskii
2016-03-08 17:35 ` Eli Zaretskii
@ 2016-03-09 6:01 ` Marcin Borkowski
1 sibling, 0 replies; 7+ messages in thread
From: Marcin Borkowski @ 2016-03-09 6:01 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: 18996-done, lgp171188
On 2016-03-08, at 19:10, Eli Zaretskii <eliz@gnu.org> wrote:
>> From: Marcin Borkowski <mbork@mbork.pl>
>> Cc: lgp171188@gmail.com, 18996@debbugs.gnu.org
>> Date: Tue, 08 Mar 2016 17:47:48 +0100
>>
>> >> > Further, when I press Alt-x, it shows up as M-x in both the
>> >> > scenarios. So it doesn't look like Emacs cannot differentiate between
>> >> > the two when running inside the terminal without a GUI.
>> >>
>> >> This is not true: M-x is bound (by default) to
>> >> `execute-extended-command', which calls `read-extended-command', which
>> >> has at one point the literal string "M-x ", which is fed (via
>> >> a `concat', which shows prefix arguments, if any) directly to
>> >> `completing-read'.
>> >>
>> >> > I vaguely remember seeing M-g in the terminal on pressing Alt-g some
>> >> > time back, maybe in an older emacs version. But not sure.
>> >>
>> >> No idea, though I doubt.
>> >>
>> >> All in all, I'll assign this a "wishlist" level - I agree with the OP
>> >> that it would be nice to have this solved
>> >
>> > To have what solved?
>> >
>> > If you type "C-h l" after M-x, what do you see?
>>
>> AFAIU, OP wants to see "M-g-" and not "ESC g-" after pressing M-g in an
>> Emacs session in a terminal.
>
> My point was that you will see "ESC g" in the "C-h l" output. Which
> means Emacs _doesn't_ know how to differentiate between ESC-x and M-x,
> on the level that shows the prefix key prompts, such as M-g-. What
> happens here is that the command bound to "ESC x" deliberately
> displays "M-x " in the echo area. IOW, "M-x" is _not_ the key echo,
> it's a message displayed by a command.
>
> In sum, Emacs doesn't have a way to distinguish between M-c and ESC c,
> for any character c, on a TTY. We can only do that on a GUI frame.
OK, so I'm tagging this "wontfix" and closing it.
Best,
--
Marcin
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2016-03-09 6:01 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-11-08 8:37 bug#18996: 24.4; Pressing Alt-g shows Esc g- when running emacs inside terminal and in GUI mode it shows M-g L. Guruprasad
2016-03-05 18:14 ` Marcin Borkowski
2016-03-05 18:52 ` Eli Zaretskii
2016-03-08 16:47 ` Marcin Borkowski
2016-03-08 17:10 ` Eli Zaretskii
2016-03-08 17:35 ` Eli Zaretskii
2016-03-09 6:01 ` Marcin Borkowski
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).