From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#34517: tmm menubar menu items have no effect on Android Date: Wed, 27 Feb 2019 17:10:23 -0500 Message-ID: References: <87sgwm75ko.fsf@mail.linkov.net> <87h8d0u70k.fsf@mail.linkov.net> <835ztgjvus.fsf@gnu.org> <8736ojwl1l.fsf@mail.linkov.net> <874l8puep9.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="206295"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: 34517@debbugs.gnu.org To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Feb 27 23:19:28 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gz7Xz-000rWr-34 for geb-bug-gnu-emacs@m.gmane.org; Wed, 27 Feb 2019 23:19:27 +0100 Original-Received: from localhost ([127.0.0.1]:51388 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gz7Xy-0005Gx-39 for geb-bug-gnu-emacs@m.gmane.org; Wed, 27 Feb 2019 17:19:26 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:57416) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gz7Xm-0005AB-HH for bug-gnu-emacs@gnu.org; Wed, 27 Feb 2019 17:19:15 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gz7Pr-0005Sh-FZ for bug-gnu-emacs@gnu.org; Wed, 27 Feb 2019 17:11:04 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:40913) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gz7Pr-0005SE-Aw for bug-gnu-emacs@gnu.org; Wed, 27 Feb 2019 17:11:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gz7Pr-0006jt-0G for bug-gnu-emacs@gnu.org; Wed, 27 Feb 2019 17:11:03 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 27 Feb 2019 22:11:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 34517 X-GNU-PR-Package: emacs Original-Received: via spool by 34517-submit@debbugs.gnu.org id=B34517.155130542925850 (code B ref 34517); Wed, 27 Feb 2019 22:11:02 +0000 Original-Received: (at 34517) by debbugs.gnu.org; 27 Feb 2019 22:10:29 +0000 Original-Received: from localhost ([127.0.0.1]:54457 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gz7PJ-0006ir-2r for submit@debbugs.gnu.org; Wed, 27 Feb 2019 17:10:29 -0500 Original-Received: from chene.dit.umontreal.ca ([132.204.246.20]:54165) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gz7PF-0006ii-J3 for 34517@debbugs.gnu.org; Wed, 27 Feb 2019 17:10:28 -0500 Original-Received: from pastel.home (lechon.iro.umontreal.ca [132.204.27.242]) by chene.dit.umontreal.ca (8.14.7/8.14.1) with ESMTP id x1RMANVb023835; Wed, 27 Feb 2019 17:10:23 -0500 Original-Received: by pastel.home (Postfix, from userid 20848) id 5BE5869F67; Wed, 27 Feb 2019 17:10:23 -0500 (EST) In-Reply-To: <874l8puep9.fsf@mail.linkov.net> (Juri Linkov's message of "Wed, 27 Feb 2019 23:04:14 +0200") X-NAI-Spam-Flag: NO X-NAI-Spam-Threshold: 5 X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 2 Rules triggered EDT_SA_DN_PASS=0, RV6492=0 X-NAI-Spam-Version: 2.3.0.9418 : core <6492> : inlines <7025> : streams <1814288> : uri <2803319> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:155885 Archived-At: > Stefan, please advise shouldn't selecting a completion from the > *Completions* buffer clear the minibuffer's content before > inserting the selected completion? No, for example when you complete file name "C-x C-f ~/.e TAB" the *Completions* buffer will only show ".emacs" so we should clear the minibuffer before inserting ".emacs" because that would lose the leading "~/". There are other circumstances where trailing text needs to be preserved. The completion code handles this with `completion-base-position` which holds the beginning and end of the text that should be replaced when you choose an item in *Completions*. >> 0. emacs -Q >> 1. =E2=80=98C-h f TAB=E2=80=99 displays a list of completions >> 2. type a nonexistent function name, i.e. some random text >> in the minibuffer, e.g. =E2=80=9Cblabla=E2=80=9D The *Completions* content is now "out of date" compared to the minibuffer. >> 3. click on an existing valid completion in the *Completions* buffer, >> e.g. on =E2=80=9Cappend=E2=80=9D completion-base-position was set at step (1) to cover the empty text after the prompt, so this empty text (which is now right in front of "blabla") is replaced with "append" resulting in "appendblabla". Obviously, the result is not what we want. Now sure how to change which part, tho. Maybe instead of completion-base-position we should store the prefix and suffix strings, so when you select an entry from *Completions* we just clear the minibuffer and replace it with (concat prefix selection suffix)? Stefan