From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Joost Kremers Newsgroups: gmane.emacs.help Subject: Re: DWIM when yanking strings with leading or trailing spaces - an idea Date: 4 Mar 2016 09:45:11 GMT Message-ID: References: NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1457085034 10317 80.91.229.3 (4 Mar 2016 09:50:34 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 4 Mar 2016 09:50:34 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Mar 04 10:50:29 2016 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1abmNP-0005Ra-S1 for geh-help-gnu-emacs@m.gmane.org; Fri, 04 Mar 2016 10:50:27 +0100 Original-Received: from localhost ([::1]:39929 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1abmNP-0004hp-AD for geh-help-gnu-emacs@m.gmane.org; Fri, 04 Mar 2016 04:50:27 -0500 Original-Path: usenet.stanford.edu!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 35 Original-X-Trace: individual.net fLeIhjdwPblsNKmod6btSw5t0Tfgj3FBnRe7XVN0STP7qC1aIQ Cancel-Lock: sha1:8r8Dsg4kpgeOcZDPhfVxj4J4FDQ= Mail-Copies-To: nobody X-Editor: Emacs of course! User-Agent: slrn/1.0.1 (Linux) Original-Xref: usenet.stanford.edu gnu.emacs.help:217142 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:109435 Archived-At: Marcin Borkowski wrote: > In one case, it's easy: I have a function which inserts a dash, killing > any other punctuation in that place, and if region is active, it > surrounds it with dashes. /Extremely/ useful. Also, this: > http://mbork.pl/2015-10-31_Smart_comma_and_other_punctuation . Nice. For me, though, this: ,---- | And now that I have this, I think I could do a similar thing with C-t, | so that it transposes two chars before the point (as opposed as two | chars around the point) if there is a space before the point. `---- would be a bad idea, because I often use `transpose-chars' to correct things like "th emistake". Which I unfortunately type quite often... >> Anyway, my opinion shouldn't stop you from creating such a package, of >> course. I mean, it bugs you, so that should be enough of a reason, >> >> right? ;-) > > Yes and no. It's on the limit of the "automation horizon" (see > https://xkcd.com/1205/) ;-) So you basically posted your question looking for an excuse to do some coding? ;-) -- Joost Kremers joostkremers@fastmail.fm Selbst in die Unterwelt dringt durch Spalten Licht EN:SiS(9)