From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?ISO-8859-1?Q?R=FCdiger?= Sonderfeld Newsgroups: gmane.emacs.devel Subject: Re: why do some programming modes have customize hooks and others do not? Date: Mon, 20 Oct 2014 00:44:18 +0200 Message-ID: <2128728.y75FreRA9t@descartes> References: <87bnp9eir3.fsf@ferrier.me.uk> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1413758701 2901 80.91.229.3 (19 Oct 2014 22:45:01 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 19 Oct 2014 22:45:01 +0000 (UTC) Cc: Stefan Monnier , Nic Ferrier To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Oct 20 00:44:53 2014 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1XfzDZ-00011K-Io for ged-emacs-devel@m.gmane.org; Mon, 20 Oct 2014 00:44:53 +0200 Original-Received: from localhost ([::1]:41331 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XfzDZ-0002Re-4l for ged-emacs-devel@m.gmane.org; Sun, 19 Oct 2014 18:44:53 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:57988) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XfzDO-0002Qi-Uv for emacs-devel@gnu.org; Sun, 19 Oct 2014 18:44:50 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XfzDH-0008G9-Eo for emacs-devel@gnu.org; Sun, 19 Oct 2014 18:44:42 -0400 Original-Received: from ptmx.org ([178.63.28.110]:34642) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XfzDH-0008G4-8g for emacs-devel@gnu.org; Sun, 19 Oct 2014 18:44:35 -0400 Original-Received: from localhost (localhost [127.0.0.1]) by ptmx.org (Postfix) with ESMTP id 250C22C40A; Mon, 20 Oct 2014 00:44:33 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at ptmx.org Original-Received: from ptmx.org ([127.0.0.1]) by localhost (ptmx.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id XNeg+XGzpDZh; Mon, 20 Oct 2014 00:44:31 +0200 (CEST) Original-Received: from descartes.localnet (chello080109100138.16.15.univie.teleweb.at [80.109.100.138]) by ptmx.org (Postfix) with ESMTPSA id 9F02F23327; Mon, 20 Oct 2014 00:44:29 +0200 (CEST) User-Agent: KMail/4.13.3 (Linux/3.13.0-37-generic; KDE/4.13.3; x86_64; ; ) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 178.63.28.110 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:175570 Archived-At: On Saturday 18 October 2014 17:46:14 Stefan Monnier wrote: > Maybe define-derived-mode should define the hook with defcustom. > I guess we'd need some motivation (other than "consistency") for that= , > such as what would be the benefit to define the hook as a defcustom i= f > all the defcustom says is ":type hook". I've started working on a patch to add `:options' flags to mode hooks, = such as=20 `imenu-add-menubar-index' for modes supporting imenu or `eldoc-mode' fo= r modes=20 supporting eldoc. In that process I started adding `defcustom' for hoo= ks to=20 modes which lacked one. Since I'm currently busy with real work I stop= ped=20 working on it. If there is interest I could push the current state. B= ut this=20 could of course also be a motivation to add such a feature to `define-d= erived- mode'. Although I'm not sure how to best represent it. A `:hook-optio= ns'=20 would probably miss the point. Maybe a `:supported-minor-modes' option= ? Regards, R=C3=BCdiger