From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Kevin Rodgers Newsgroups: gmane.emacs.help Subject: Re: haml plus kill-rectangle hangs emacs Date: Tue, 06 Apr 2010 00:17:36 -0600 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1270534689 7983 80.91.229.12 (6 Apr 2010 06:18:09 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 6 Apr 2010 06:18:09 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Apr 06 08:18:07 2010 Return-path: Envelope-to: geh-help-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 1Nz26x-0006dV-0j for geh-help-gnu-emacs@m.gmane.org; Tue, 06 Apr 2010 08:18:07 +0200 Original-Received: from localhost ([127.0.0.1]:57611 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Nz26w-0003R4-Bk for geh-help-gnu-emacs@m.gmane.org; Tue, 06 Apr 2010 02:18:06 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Nz26Y-0003Qz-6m for help-gnu-emacs@gnu.org; Tue, 06 Apr 2010 02:17:42 -0400 Original-Received: from [140.186.70.92] (port=50485 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Nz26X-0003Qp-05 for help-gnu-emacs@gnu.org; Tue, 06 Apr 2010 02:17:41 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Nz26V-0006Zx-H3 for help-gnu-emacs@gnu.org; Tue, 06 Apr 2010 02:17:40 -0400 Original-Received: from lo.gmane.org ([80.91.229.12]:33668) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Nz26V-0006Zn-9g for help-gnu-emacs@gnu.org; Tue, 06 Apr 2010 02:17:39 -0400 Original-Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1Nz26T-00056W-8O for help-gnu-emacs@gnu.org; Tue, 06 Apr 2010 08:17:37 +0200 Original-Received: from c-71-237-24-138.hsd1.co.comcast.net ([71.237.24.138]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 06 Apr 2010 08:17:37 +0200 Original-Received: from kevin.d.rodgers by c-71-237-24-138.hsd1.co.comcast.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 06 Apr 2010 08:17:37 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 55 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: c-71-237-24-138.hsd1.co.comcast.net User-Agent: Thunderbird 2.0.0.24 (Macintosh/20100228) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:72609 Archived-At: Audrey Lee wrote: > Hello emacs people. > > I have bumped into an issue with emacs when I try to kill-rectangle > inside a file which is in haml-mode. > > I see 2 symptoms: > > 1. Emacs "hangs" > 2. The emacs process start hogging 99% of the CPU on my Mac. > > Here is info about my emacs: > > GNU Emacs 22.3.1 (i386-apple-darwin9.6.0, Carbon Version 1.6.0) > of 2009-01-02 on seijiz.local > > Question 1: > - In my .emacs, What might be some simple syntax I can use to > disable kill-rectangle while I am in haml-mode ? Commands can only be disabled globally, via the disabled property. But you can disable a keybinding locally, via local-unset-key, local-set-key, or define-key. E.g. (add-hook 'html-mode-hook (lambda () (local-set-key (where-is-internal 'kill-rectangle (current-local-map) t) 'undefined))) > Question 2: > - In my .emacs, What might be some simple syntax I can use to > connect a key to a function, but only for haml-mode, not globally. (add-hook 'html-mode-hook (lambda () (local-set-key SOME-KEY SOME-COMMAND))) > Question 3: > - Does emacs have some kind of debugger I can use to tell me what > files it is reading when I execute emacs commands? Emacs has a debugger you can use all the time. This is probably too intrusive, but you get the idea: (debug-on-entry 'load) > These are the only emacs questions I can think of today. Tomorrow is another day. :-) -- Kevin Rodgers Denver, Colorado, USA