From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: =?UTF-8?Q?=E7=A9=8D=E4=B8=B9=E5=B0=BC?= Dan Jacobson Newsgroups: gmane.emacs.bugs Subject: bug#27997: pick a better buffer to fill the gap, not one I already see Date: Mon, 07 Aug 2017 08:37:20 +0800 Message-ID: <87y3qwkybj.fsf@jidanni.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1502072008 9110 195.159.176.226 (7 Aug 2017 02:13:28 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 7 Aug 2017 02:13:28 +0000 (UTC) To: 27997@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Aug 07 04:13:25 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1deXXe-0001gI-ES for geb-bug-gnu-emacs@m.gmane.org; Mon, 07 Aug 2017 04:13:19 +0200 Original-Received: from localhost ([::1]:35005 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1deXXk-0001T4-6Q for geb-bug-gnu-emacs@m.gmane.org; Sun, 06 Aug 2017 22:13:20 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:45387) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1deXXY-0001SW-FN for bug-gnu-emacs@gnu.org; Sun, 06 Aug 2017 22:13:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1deXXV-0004gT-0g for bug-gnu-emacs@gnu.org; Sun, 06 Aug 2017 22:13:08 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:42449) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1deXXU-0004gK-Sv for bug-gnu-emacs@gnu.org; Sun, 06 Aug 2017 22:13:04 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1deXXU-0002c5-Mw for bug-gnu-emacs@gnu.org; Sun, 06 Aug 2017 22:13:04 -0400 X-Loop: help-debbugs@gnu.org Resent-From: =?UTF-8?Q?=E7=A9=8D=E4=B8=B9=E5=B0=BC?= Dan Jacobson Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 07 Aug 2017 02:13:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 27997 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.15020719769984 (code B ref -1); Mon, 07 Aug 2017 02:13:04 +0000 Original-Received: (at submit) by debbugs.gnu.org; 7 Aug 2017 02:12:56 +0000 Original-Received: from localhost ([127.0.0.1]:45119 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1deXXL-0002at-MD for submit@debbugs.gnu.org; Sun, 06 Aug 2017 22:12:55 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:54233) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1deXXJ-0002aM-OX for submit@debbugs.gnu.org; Sun, 06 Aug 2017 22:12:54 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1deXXD-0004Zy-Ol for submit@debbugs.gnu.org; Sun, 06 Aug 2017 22:12:48 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:49140) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1deXXD-0004Zq-Lm for submit@debbugs.gnu.org; Sun, 06 Aug 2017 22:12:47 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:45154) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1deXXC-0001On-72 for bug-gnu-emacs@gnu.org; Sun, 06 Aug 2017 22:12:47 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1deXX8-0004XR-Ul for bug-gnu-emacs@gnu.org; Sun, 06 Aug 2017 22:12:46 -0400 Original-Received: from homie.mail.dreamhost.com ([208.97.132.208]:40020 helo=homiemail-a9.g.dreamhost.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1deXX8-0004X2-P4 for bug-gnu-emacs@gnu.org; Sun, 06 Aug 2017 22:12:42 -0400 Original-Received: from homiemail-a9.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a9.g.dreamhost.com (Postfix) with ESMTP id CA1A75BE06B for ; Sun, 6 Aug 2017 19:12:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=jidanni.org; h=from:to :subject:date:message-id:mime-version:content-type; s= jidanni.org; bh=6EZjU5deEDeloA7bmP30uS07F4Y=; b=aAuzTl1am+VETSFR ZSGnstq26oIU2A2EzcZgTVV3Z+cToyFZcPWlGWQgnoqJ5ISNl5/hMV+vm9pAl6Dn dN+Skn02cW7aAvkvKxEVT6VWmziJXWAbEHlHwkk7ieS/xk5h+OtWlNbHiEVyUEsT /ZpAKMGj6CGSnZ55w35irZn+2gU= Original-Received: from jidanni.org (114-46-60-214.dynamic-ip.hinet.net [114.46.60.214]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: jidanni@jidanni.org) by homiemail-a9.g.dreamhost.com (Postfix) with ESMTPSA id 77E595BE064 for ; Sun, 6 Aug 2017 19:12:41 -0700 (PDT) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no timestamps) [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x 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: 208.118.235.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:135524 Archived-At: OK I killed a buffer, so a new one pops in to replace it. Except sometimes the choice of the new one is quite embarrassing: it picks a buffer I'm already looking at while at the same time ignoring a better candidate. $ emacs -Q /tmp/a /tmp/b /tmp/c C-x 1 [delete-other-windows] C-x 4 b [switch-to-buffer-other-window] # Smart enough not to prompt with the name of a buffer I already see. Good. [minibuffer-complete-and-exit] # was prompted with "b", OK C-x k [kill-buffer] # was prompted with "b", OK [minibuffer-complete-and-exit] # killed "b", OK, but... Now I'm staring at two "c" buffers! I would be better served by staring at "a" and "c" buffers. So please when selecting a buffer to fill the gap, again be smart enough not to show a buffer I already see.