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? Date: Fri, 29 Dec 2006 14:40:44 -0800 Message-ID: References: NNTP-Posting-Host: dough.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1167432125 27002 80.91.229.10 (29 Dec 2006 22:42:05 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 29 Dec 2006 22:42:05 +0000 (UTC) Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Dec 29 23:42:04 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 1H0QQN-0008EF-Qe for ged-emacs-devel@m.gmane.org; Fri, 29 Dec 2006 23:42:04 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1H0QQN-0007q1-9O for ged-emacs-devel@m.gmane.org; Fri, 29 Dec 2006 17:42:03 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1H0QPK-0006n1-ML for emacs-devel@gnu.org; Fri, 29 Dec 2006 17:40:58 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1H0QPJ-0006lE-Ju for emacs-devel@gnu.org; Fri, 29 Dec 2006 17:40:57 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1H0QPJ-0006kv-AA for emacs-devel@gnu.org; Fri, 29 Dec 2006 17:40:57 -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 1H0QPI-00023Q-UP for emacs-devel@gnu.org; Fri, 29 Dec 2006 17:40:57 -0500 Original-Received: from rgmgw1.us.oracle.com (rgmgw1.us.oracle.com [138.1.186.110]) by rgminet01.oracle.com (Switch-3.2.4/Switch-3.1.6) with ESMTP id kBTMesAj000866 for ; Fri, 29 Dec 2006 15:40:54 -0700 Original-Received: from rcsmt250.oracle.com (rcsmt250.oracle.com [148.87.90.195]) by rgmgw1.us.oracle.com (Switch-3.2.4/Switch-3.1.7) with ESMTP id kBTMerca006119 for ; Fri, 29 Dec 2006 15:40:53 -0700 Original-Received: from dhcp-amer-whq-csvpn-gw3-141-144-80-134.vpn.oracle.com by rcsmt250.oracle.com with ESMTP id 2325379661167432049; Fri, 29 Dec 2006 15:40:49 -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: Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3028 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:64451 Archived-At: > > `define-global-minor-mode' is new in Emacs 22. I think we have the > > opportunity now to correct its name to avoid confusing users. > > As the original inventor of the name (and code) of > define-global-minor-mode, > I agree that it's not ideal. I hope we can come up with something better. > But note that the operation really defines a new global minor mode whose > effect is to turn on in most buffers the other (buffer-local) minor-mode. > Calling it make-minor-mode-global would be wrong, because it would make it > seem like it will change the buffer-local minor-mode to a global one, > whereas the buffer-local minor-mode is actually unaffected. I see. So it is not quite analogous to `make-variable-buffer-local'. I do think it's important that we come up with some name, now, that doesn't encourage confusion of this with the true global minor mode (via :global t). If we don't do that now, it will engender confusion that lasts, I fear. I don't really have a better name suggestion than `make-minor-mode-global', which I think is anyway better than `define-global-minor-mode'. BTW, I came up with that name based on the first line of the doc string: "Make global-mode out of the buffer-local minor mode." If that macro name is misleading, for the reason you gave, then so is the first line of the doc string, IMO. And the doc string should be at least as clear as the macro name. If a longer name can be tolerated, perhaps something like `make-global-minor-mode-for-local-minor-mode' (ugh!) or `make-global-for-local-minor-mode' (ugh) or `globally-extend-minor-mode'. Maybe that last one is OK, but the doc string needs to explain well what the nebulous "extend" means. Anyone have a good idea? I really think we should try to come up with a good name now, before the release.