From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.devel,gmane.emacs.help Subject: RE: yank-repeat-newline Date: Tue, 26 Jul 2011 13:33:38 -0700 Message-ID: References: <4E2F11A3.3090102@easy-emacs.de> <87tya8rgrz.fsf@mithlond.arda> <4E2F1453.5010604@easy-emacs.de> <87pqkwrg2d.fsf@mithlond.arda> <4E2F1964.4040008@easy-emacs.de> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1311712440 25631 80.91.229.12 (26 Jul 2011 20:34:00 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 26 Jul 2011 20:34:00 +0000 (UTC) Cc: help-gnu-emacs@gnu.org, emacs-devel@gnu.org To: "=?iso-8859-1?Q?'Andreas_R=F6hler'?=" , "'Teemu Likonen'" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jul 26 22:33:56 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QloKB-00021S-5B for ged-emacs-devel@m.gmane.org; Tue, 26 Jul 2011 22:33:55 +0200 Original-Received: from localhost ([::1]:38553 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QloK9-0001us-VZ for ged-emacs-devel@m.gmane.org; Tue, 26 Jul 2011 16:33:53 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:59574) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QloK7-0001um-RS for emacs-devel@gnu.org; Tue, 26 Jul 2011 16:33:52 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QloK6-0006Mp-JJ for emacs-devel@gnu.org; Tue, 26 Jul 2011 16:33:51 -0400 Original-Received: from acsinet15.oracle.com ([141.146.126.227]:54303) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QloK6-0006MW-BZ; Tue, 26 Jul 2011 16:33:50 -0400 Original-Received: from acsinet22.oracle.com (acsinet22.oracle.com [141.146.126.238]) by acsinet15.oracle.com (Switch-3.4.4/Switch-3.4.4) with ESMTP id p6QKXj67008746 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 26 Jul 2011 20:33:46 GMT Original-Received: from acsmt357.oracle.com (acsmt357.oracle.com [141.146.40.157]) by acsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id p6QKXihQ001477 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 26 Jul 2011 20:33:44 GMT Original-Received: from abhmt106.oracle.com (abhmt106.oracle.com [141.146.116.58]) by acsmt357.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id p6QKXcTs009813; Tue, 26 Jul 2011 15:33:39 -0500 Original-Received: from dradamslap1 (/10.159.42.138) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Tue, 26 Jul 2011 13:33:38 -0700 X-Mailer: Microsoft Office Outlook 11 x-mimeole: Produced By Microsoft MimeOLE V6.00.2900.6109 In-Reply-To: <4E2F1964.4040008@easy-emacs.de> Thread-Index: AcxLzVv06rD0rK1TTuepQ6WBMNPeDwAAaKHw X-Source-IP: acsinet22.oracle.com [141.146.126.238] X-Auth-Type: Internal IP X-CT-RefId: str=0001.0A090207.4E2F24AB.002C:SCFMA922111,ss=1,re=-4.000,fgs=0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 1) X-Received-From: 141.146.126.227 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:142324 gmane.emacs.help:81796 Archived-At: > However, after all think Emacs could make a better use of these both > interactive codes by separating it. It's a kind of interference with > "P" "p" which makes things more complex then needed and doesn't > contribute - IMHO. > Will present the matter at emacs-devel. I suggest you think more about it, Andreas. You cannot "separate" the two behaviors if they are represented by exactly the same argument (value). How can any given prefix arg - that is, one single value, represent both the number of yanks and whether to add a newline to each yank? If it is one value then it cannot distinguish two things. Things are even simpler - you can forget about arguments, prefix or otherwise. You cannot separate the two command behaviors if you want them to be triggered by the _same user input event_ and you want nothing else to affect the behavior, besides the user. It does not matter how you communicate the user behavior to the command (prefix arg or otherwise): the problem is the same. Only the user behavior can distinguish the behaviors you want (unless you want to distinguish based on tide levels, time of day, etc.). So you need two different user behaviors - the user needs some way to let your command know what to do. Having the user distinguish using positive and non-positive prefix args is one way. But you need _some_ user-level difference. Describe to yourself exactly what you expect the different user inputs to be, which would distinguish the command behavior cases. Figure out what you want the _user_ to do differently in the two cases and then you'll know how to code it to get the behavior you want. Just think a little more about it, and I'm sure you'll have a Eureka moment.