From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Electricity (was: bug#5586: 23.1.92.1; Electric indentation and hungry backspace deletion in JavaScript mode (js-mode)) Date: Sun, 28 Mar 2010 21:47:07 -0400 Message-ID: References: <201002170031.46472.pogonyshev@gmx.net> <87aatsuqbu.fsf@stupidchicken.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1269827256 25919 80.91.229.12 (29 Mar 2010 01:47:36 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 29 Mar 2010 01:47:36 +0000 (UTC) Cc: emacs-devel@gnu.org To: Chong Yidong Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Mar 29 03:47:25 2010 Return-path: Envelope-to: ged-emacs-devel@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 1Nw44X-0001sB-7r for ged-emacs-devel@m.gmane.org; Mon, 29 Mar 2010 03:47:21 +0200 Original-Received: from localhost ([127.0.0.1]:45598 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Nw44W-00070d-KJ for ged-emacs-devel@m.gmane.org; Sun, 28 Mar 2010 21:47:20 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Nw44R-00070V-0f for emacs-devel@gnu.org; Sun, 28 Mar 2010 21:47:15 -0400 Original-Received: from [140.186.70.92] (port=38988 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Nw44O-00070N-GM for emacs-devel@gnu.org; Sun, 28 Mar 2010 21:47:13 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Nw44N-0007v8-8E for emacs-devel@gnu.org; Sun, 28 Mar 2010 21:47:12 -0400 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.183]:18841 helo=ironport2-out.pppoe.ca) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Nw44N-0007uy-21 for emacs-devel@gnu.org; Sun, 28 Mar 2010 21:47:11 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AvsEADajr0tMCqeD/2dsb2JhbACbKXK+J4UBBIse X-IronPort-AV: E=Sophos;i="4.51,325,1267419600"; d="scan'208";a="59566475" Original-Received: from 76-10-167-131.dsl.teksavvy.com (HELO ceviche.home) ([76.10.167.131]) by ironport2-out.pppoe.ca with ESMTP; 28 Mar 2010 21:47:07 -0400 Original-Received: by ceviche.home (Postfix, from userid 20848) id 7F61D660BF; Sun, 28 Mar 2010 21:47:07 -0400 (EDT) In-Reply-To: <87aatsuqbu.fsf@stupidchicken.com> (Chong Yidong's message of "Sun, 28 Mar 2010 16:46:45 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:122836 Archived-At: > I am still not happy about the way it's implemented in either mode---I > think Emacs needs some kind of centralized mechanism for this---but that > is a longer-term project. Agreed. If someone could try to survey the different kinds of "electricity" we have in Emacs packages, and the different ways they can be configured, it would be a good first step. Obvious one kind of electricity is when some keys (like ; } and such) cause reindentation of the current line additionally to self-insert. Other forms I would consider as potentially connected include: - SPC in auto-fill-mode - inserting () when you press just ( - do abbrev expansion when you hit SPC - newline-and-indent as an electric form of newline - insert `` or " or '' when you press " in LaTeX Stefan