unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Alan Mackenzie <acm@muc.de>
To: Eli Zaretskii <eliz@gnu.org>
Cc: yuri.v.khan@gmail.com, monnier@iro.umontreal.ca, emacs-devel@gnu.org
Subject: Re: What's happened to M-<tab> `completion-at-point'?
Date: Thu, 5 May 2022 16:57:55 +0000	[thread overview]
Message-ID: <YnQCEz31lk7Uc0xG@ACM> (raw)
In-Reply-To: <83fslo33ha.fsf@gnu.org>

Hello, Eli.

On Thu, May 05, 2022 at 09:20:17 +0300, Eli Zaretskii wrote:
> > Date: Wed, 4 May 2022 21:07:04 +0000
> > Cc: Stefan Monnier <monnier@iro.umontreal.ca>, Eli Zaretskii <eliz@gnu.org>,
> >   Emacs developers <emacs-devel@gnu.org>
> > From: Alan Mackenzie <acm@muc.de>

> > Maybe the best thing we can do in Emacs is to remove that entry for "kB"
> > in src/term.c.  That would prevent Emacs recognising <shift>TAB on all
> > these misconfigured keyboards.  I think that is a lesser evil than
> > failing to recognise <meta>TAB.

> This doesn't sound like a good idea to me.  Emacs shouldn't try
> second-guessing the user's keyboard configuration, it isn't in our
> mandate.

We have a bug here, Emacs does not work properly.  While it is true in
theory that a user might be able to fix it in her configuration, in
practice this is just too difficult for a user to diagnose and fix.
Note that all the key sequences M-tab, ESC TAB, and C-M-i are affected.

The change from ncurses-6.2 to ncurses-6.3 broke the Linux console
keyboard, in that terminfo now directs ESC TAB to be translated to
backtab.  This was almost certainly intentional, possibly prompted by
the misconfiguration of so many Linux keyboard layouts (in
/usr/share/keymaps/...), where the <shift>TAB key sequence produces the
characters ESC TAB.  I can imagine that there was a lot of strenuous
discussion on the ncurses mailing list before making this change, and
that it was done with regret.

> If the terminfo database you have doesn't do what you want, why can't
> you modify it?  The tools to do that are available, and aren't part of
> Emacs.

I could do this without too much difficulty for myself personally, but
that doesn't fix the bug for other users.  I don't think we want to
distribute a version of terminfo just for Linux Emacs users.

> (We could include the instructions for making such a change in
> PROBLEMS, if this is a common issue.)  Of course, the best solution
> would be if the distro changes the terminfo database.

There are many GNU/Linux distros all distributing Emacs, and I think it
likely that few, if any, will be prepared to fix terminfo (likely
"breaking" other programs) for the sake of Emacs.

Our problem here is caused by an ad hoc change to terminfo.  Why can't
we fix it likewise by an ad hoc change in Emacs, that would prevent ESC
TAB only on the Linux keyboard from being changed into backtab.  We
could make this optional, either by a run-time or a configure-time
option.

-- 
Alan Mackenzie (Nuremberg, Germany).



  reply	other threads:[~2022-05-05 16:57 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-03 21:06 What's happened to M-<tab> `completion-at-point'? Alan Mackenzie
2022-05-04  6:32 ` Eli Zaretskii
2022-05-04 16:34   ` Alan Mackenzie
2022-05-04 16:40     ` Eli Zaretskii
2022-05-04 18:13       ` Alan Mackenzie
2022-05-04 18:55         ` Eli Zaretskii
2022-05-04 19:10           ` Alan Mackenzie
2022-05-04 19:47             ` Yuri Khan
2022-05-04 20:16               ` Stefan Monnier
2022-05-04 20:31                 ` Yuri Khan
2022-05-04 20:50                   ` Stefan Monnier
2022-05-04 21:07                   ` Alan Mackenzie
2022-05-05  5:03                     ` tomas
2022-05-05  6:20                     ` Eli Zaretskii
2022-05-05 16:57                       ` Alan Mackenzie [this message]
2022-05-05 17:28                         ` Eli Zaretskii
2022-05-06 23:19                           ` Richard Stallman
2022-05-07 11:03                             ` Alan Mackenzie
2022-05-08 23:35                               ` Richard Stallman
2022-05-04 20:35               ` Alan Mackenzie
2022-05-04 19:16           ` Tassilo Horn
2022-05-04 19:39             ` Eli Zaretskii
2022-05-04 19:45               ` Tassilo Horn
2022-05-04 19:57               ` Andreas Schwab
2022-05-04  6:33 ` Lars Ingebrigtsen
2022-05-04 16:26   ` Alan Mackenzie

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YnQCEz31lk7Uc0xG@ACM \
    --to=acm@muc.de \
    --cc=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    --cc=yuri.v.khan@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).