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: Re: OS X Lion and "ApplePressAndHoldEnabled" Date: Mon, 20 Jun 2011 14:06:33 -0400 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1308596069 3305 80.91.229.12 (20 Jun 2011 18:54:29 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 20 Jun 2011 18:54:29 +0000 (UTC) Cc: emacs-devel@gnu.org To: Tim Harper Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Jun 20 20:54:26 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 1QYjc9-0002vu-Rr for ged-emacs-devel@m.gmane.org; Mon, 20 Jun 2011 20:54:25 +0200 Original-Received: from localhost ([::1]:59326 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QYjc9-0004qt-5F for ged-emacs-devel@m.gmane.org; Mon, 20 Jun 2011 14:54:25 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:51521) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QYirs-0007qy-MO for emacs-devel@gnu.org; Mon, 20 Jun 2011 14:06:37 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QYirr-0005Qf-1D for emacs-devel@gnu.org; Mon, 20 Jun 2011 14:06:36 -0400 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.181]:31355 helo=ironport2-out.pppoe.ca) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QYirq-0005OD-Kf for emacs-devel@gnu.org; Mon, 20 Jun 2011 14:06:34 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av0EAPWL/01FpYrD/2dsb2JhbABTpmF4iHO/ZII9g20EnVmEIg X-IronPort-AV: E=Sophos;i="4.65,395,1304308800"; d="scan'208";a="116701204" Original-Received: from 69-165-138-195.dsl.teksavvy.com (HELO pastel.home) ([69.165.138.195]) by ironport2-out.pppoe.ca with ESMTP/TLS/ADH-AES256-SHA; 20 Jun 2011 14:06:33 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id 23E8859011; Mon, 20 Jun 2011 14:06:33 -0400 (EDT) In-Reply-To: (Tim Harper's message of "Wed, 15 Jun 2011 14:58:16 -0600") 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-Received-From: 206.248.154.181 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:140732 Archived-At: > In the latest version of OS X Apple has introduced "Press and Hold". > In Emacs, it's on by default. This translates to in Emacs, any alphanumeric > key, when held down not in combination of any key modifiers, only one key > press is emitted, in contrast with the previous behavior where the key is > repeated as fast as your system repeat rate is set. IIUC this is because "press and hold" is then interpreted as "choose among various chars" instead of "auto-repeat". This feature makes sense when the key is bound to self-insert-command (whether you like it or not is another issue, but at least I don't see a reason why Emacs should necessarily disable it rather than obey the user's system-wide preference for it), but it clearly makes no sense when the key is bound to some unrelated command. Not sure how/if Emacs can enable/disable it selectively depending on the current binding of the key. > Fortunately, there is a workaround, shown to me by hober of #emacs. If this > is added at the top of your emacs config file (such that it is executed > before the frame is fully initialized): > (ns-set-resource nil "ApplePressAndHoldEnabled" "NO") Maybe we should include it in lisp/term/mac-win.el for now? Stefan