From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.devel Subject: RE: global minor modes that can be overridden locally? [was: highlight-changes-mode] Date: Sun, 10 Dec 2006 17:58:08 -0800 Message-ID: References: <457CB9DE.8020704@student.lu.se> NNTP-Posting-Host: dough.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-15" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1165802325 11598 80.91.229.10 (11 Dec 2006 01:58:45 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 11 Dec 2006 01:58:45 +0000 (UTC) Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Dec 11 02:58:43 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by dough.gmane.org with esmtp (Exim 4.50) id 1GtaRD-0004Pi-KE for ged-emacs-devel@m.gmane.org; Mon, 11 Dec 2006 02:58:39 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GtaRD-00049x-6m for ged-emacs-devel@m.gmane.org; Sun, 10 Dec 2006 20:58:39 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1GtaR1-00049J-Ke for emacs-devel@gnu.org; Sun, 10 Dec 2006 20:58:27 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1GtaR0-00048j-5c for emacs-devel@gnu.org; Sun, 10 Dec 2006 20:58:27 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GtaR0-00048g-2Y for emacs-devel@gnu.org; Sun, 10 Dec 2006 20:58:26 -0500 Original-Received: from [148.87.113.118] (helo=rgminet01.oracle.com) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA:32) (Exim 4.52) id 1GtaQz-0004Ff-Uz for emacs-devel@gnu.org; Sun, 10 Dec 2006 20:58:26 -0500 Original-Received: from rgmgw2.us.oracle.com (rgmgw2.us.oracle.com [138.1.186.111]) by rgminet01.oracle.com (Switch-3.2.4/Switch-3.1.6) with ESMTP id kBB1wNth024348 for ; Sun, 10 Dec 2006 18:58:23 -0700 Original-Received: from rcsmt250.oracle.com (rcsmt250.oracle.com [148.87.90.195]) by rgmgw2.us.oracle.com (Switch-3.2.4/Switch-3.1.7) with ESMTP id kBB1wM47008176 for ; Sun, 10 Dec 2006 18:58:22 -0700 Original-Received: from dhcp-amer-csvpn-gw1-141-144-65-20.vpn.oracle.com by rcsmt251.oracle.com with ESMTP id 2271411611165802294; Sun, 10 Dec 2006 18:58:14 -0700 Original-To: X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.6604 (9.0.2911.0) In-Reply-To: <457CB9DE.8020704@student.lu.se> X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2962 Importance: Normal X-Brightmail-Tracker: AAAAAQAAAAI= X-Brightmail-Tracker: AAAAAQAAAAI= X-Whitelist: TRUE X-Whitelist: TRUE 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:63570 Archived-At: > >> Why not define a new sub foo-mode-locally to toggle it in > >> current buffer when it is a global minor mode? > > > > Not clear to me what you mean. > > That makes me wonder if I am misunderstanding something ... Are we not > talking about global minor mode and how to turn them on or off both > globally in all buffers and locally in just one buffer? Yes. Currently, there is no way to do the latter; a global minor mode is not overridden locally. This would be a possible new feature. > I meant that foo-mode should toggle the global minor mode in all buffers > and foo-mode-locally should toggle it in just the current buffer. Should > not that be possible? Yes. The advantage of that would be that it would avoid using C-u. The disadvantage would be that it would be a separate command. You might be right that that would be simpler. I assume that it would act just like foo-mode does wrt turning on and off explicitly (i.e. with a prefix arg).