From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dani Moncayo Newsgroups: gmane.emacs.bugs Subject: bug#7700: 24.0.50; C-y binding withing Isearch mode Date: Fri, 24 Dec 2010 14:34:24 +0100 Message-ID: References: <20101223171434.GA3971@muc.de> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: dough.gmane.org 1293198800 22429 80.91.229.12 (24 Dec 2010 13:53:20 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 24 Dec 2010 13:53:20 +0000 (UTC) Cc: 7700@debbugs.gnu.org To: Lennart Borgman Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Dec 24 14:53:15 2010 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PW853-0006jC-Ly for geb-bug-gnu-emacs@m.gmane.org; Fri, 24 Dec 2010 14:53:14 +0100 Original-Received: from localhost ([127.0.0.1]:44697 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PW853-0004lA-2j for geb-bug-gnu-emacs@m.gmane.org; Fri, 24 Dec 2010 08:53:13 -0500 Original-Received: from [140.186.70.92] (port=38236 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PW84y-0004l5-LP for bug-gnu-emacs@gnu.org; Fri, 24 Dec 2010 08:53:09 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PW84x-0006Ba-6j for bug-gnu-emacs@gnu.org; Fri, 24 Dec 2010 08:53:08 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:34312) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PW84w-0006BV-Us for bug-gnu-emacs@gnu.org; Fri, 24 Dec 2010 08:53:07 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1PW7gg-0006oe-4o; Fri, 24 Dec 2010 08:28:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Dani Moncayo Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 24 Dec 2010 13:28:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 7700 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 7700-submit@debbugs.gnu.org id=B7700.129319726826178 (code B ref 7700); Fri, 24 Dec 2010 13:28:02 +0000 Original-Received: (at 7700) by debbugs.gnu.org; 24 Dec 2010 13:27:48 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PW7gR-0006oB-PE for submit@debbugs.gnu.org; Fri, 24 Dec 2010 08:27:48 -0500 Original-Received: from mail-yx0-f172.google.com ([209.85.213.172]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PW7gP-0006nx-1H for 7700@debbugs.gnu.org; Fri, 24 Dec 2010 08:27:45 -0500 Original-Received: by yxt33 with SMTP id 33so3088390yxt.3 for <7700@debbugs.gnu.org>; Fri, 24 Dec 2010 05:34:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type; bh=/MBuRyZdTNg8TIRAZw6zQqnBS+c60pzQ/JYr6ii4tIw=; b=u/jDB8CaQOkye2PsE7yVnLaQnVb1fBW72Fyafvky6r7s+KuQHbuKRM1esytZsT/Tld jGFfeJ6QeZ7i0jjb3nDdDM/siCd214rM7jK1EHr7pUFqZ51GVzBW8km/7rlOc2Rb85bp vTH7g90x+tGo9OX7gbJ4knQulwJsUhkLg/8ug= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=dbkrlTbUzBM4dqnL5c+k6kd+sWo3yS2EscEv9Htw+gK8/qDRiYyz2hFw9kTjJLw7N9 ZWXXm/MYc8IPSfsYlN+ZzAKU9EsHVy4rDM7fVhTiqRHJ4mMunbxqqS/qBv6rtzhHdnMW McuBkqbmHvH4/16ArR5VrIIBqiQF5AJOepTm8= Original-Received: by 10.91.199.13 with SMTP id b13mr798847agq.94.1293197664580; Fri, 24 Dec 2010 05:34:24 -0800 (PST) Original-Received: by 10.90.227.16 with HTTP; Fri, 24 Dec 2010 05:34:24 -0800 (PST) In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Fri, 24 Dec 2010 08:28:02 -0500 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) 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: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:42801 Archived-At: On Fri, Dec 24, 2010 at 13:13, Lennart Borgman wrote: > On Fri, Dec 24, 2010 at 12:39 PM, Dani Moncayo wrote: >> On Fri, Dec 24, 2010 at 04:25, Lennart Borgman >> wrote: >>> On Fri, Dec 24, 2010 at 3:39 AM, Stefan Monnier >>> wrote: >>>>> I use C-y ("grab to next end of line") quite a bit. >>>> >>>> I'd much rather have a prefix key that lets me use any standard movement >>>> to select the text to grab from the buffer (so " C-e" would do >>>> what C-y does and " M-f" would do more or less what C-w does). >>> >>> >>> I like the logic/mnemonic but wouldn't it would be cumbersome to use it? >>> >> >> Not much, provided that the key was required only one time. I >> think would be good to have that key as a switch to turn "grabbing >> mode" on/off. > > You have to do it every time you want to grab something more. A common > situation is that you have moved from the last hit and then want to > grab more. > Maybe there was a misunderstanding here: I didn't mean to be a prefix argument only for the following command. I meant it to be a command to switch "grabbing" on/off (for the entire Isearch session). >>> I suggest instead that any standard forward movement command while in >>> isearch forward mode should select the text to grab WITHOUT any prefix >>> key. For backward movement I suggest a similar logic. >>> >> >> I prefer Stefan's proposal because with that there would be no need to >> alter the current meaning of prefix arguments in movement commands, >> and thus, you could use movement commands _even with prefix arguments_ >> to both (a) grab text from the buffer, > > Why should that be different from my proposal? > >> and (b) leave Isearch mode and >> move point (all in a single operation, as you can do currently). > > You just leave isearch once after the search so this way of solving > the problems leads to more key strokes, doesn't it? > > And besides, if you happen to forget to leave isearch before a forward > movement command you are still at the right point after it. So you can > just leave it there. > I definitively misunderstood you. Your proposal is basically what I had in my mind, but always with "grabbing" switched on. In that case I like it, but I would make a small adjustment: Let's suppose that you are in forward Isearch mode and have grabbed a couple of words after the point. Then you change your mind and want to grab only the first word. In that case, would be convenient to allow M-b without exiting Isearch mode. Thus, I propose two alternatives: a) In Isearch (forward or backward), every movement command would update the grabbed text. If the last grabbed text was in a different side of the point than current, switch the direction of the Isearch. b) The same, but replacing the direction switching with "exit Isearch mode and move point in the buffer". -- Dani Moncayo