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: [mentoring] a darkroom/writeroom mode for Emacs Date: Tue, 09 Dec 2014 19:54:32 -0500 Message-ID: References: <20141203142859.24393.98673@vcs.savannah.gnu.org> <20141203215426.GA15791@thyrsus.com> <87ppbzplcw.fsf@newcastle.ac.uk> <83iohr48kr.fsf@gnu.org> <83388u4bps.fsf@gnu.org> <83y4qm2uz9.fsf@gnu.org> <83vblq2los.fsf@gnu.org> <87vblpjq24.fsf@uwakimon.sk.tsukuba.ac.jp> <83mw7119yz.fsf@gnu.org> <87sigqiaaz.fsf@gmx.us> <878uihhv5q.fsf@gmx.us> <87wq60ub14.fsf@gmx.us> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1418172911 10941 80.91.229.3 (10 Dec 2014 00:55:11 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 10 Dec 2014 00:55:11 +0000 (UTC) Cc: joaotavora@gmail.com, emacs-devel@gnu.org To: Rasmus Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Dec 10 01:55:04 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 1XyVYV-0002g0-AT for ged-emacs-devel@m.gmane.org; Wed, 10 Dec 2014 01:55:03 +0100 Original-Received: from localhost ([::1]:43003 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XyVYV-00060a-0P for ged-emacs-devel@m.gmane.org; Tue, 09 Dec 2014 19:55:03 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:43940) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XyVYA-00060I-DI for emacs-devel@gnu.org; Tue, 09 Dec 2014 19:54:49 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XyVY2-0006C5-U0 for emacs-devel@gnu.org; Tue, 09 Dec 2014 19:54:42 -0500 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.181]:21158) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XyVY2-0006C1-QL for emacs-devel@gnu.org; Tue, 09 Dec 2014 19:54:34 -0500 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Aj4PAOwQflQXW5Ml/2dsb2JhbABbgweDYIVaxRkEBAICgSQXAQEBAQEBfIQDAQEDAVYjEAs0EhQYDSSISgnWWQEBCAIBH5A8MweESAWLAZIxj3OEAoQZIYJ3AQEB X-IPAS-Result: Aj4PAOwQflQXW5Ml/2dsb2JhbABbgweDYIVaxRkEBAICgSQXAQEBAQEBfIQDAQEDAVYjEAs0EhQYDSSISgnWWQEBCAIBH5A8MweESAWLAZIxj3OEAoQZIYJ3AQEB X-IronPort-AV: E=Sophos;i="5.07,502,1413259200"; d="scan'208";a="100024563" Original-Received: from 23-91-147-37.cpe.pppoe.ca (HELO pastel.home) ([23.91.147.37]) by ironport2-out.teksavvy.com with ESMTP/TLS/DHE-RSA-AES256-SHA; 09 Dec 2014 19:54:34 -0500 Original-Received: by pastel.home (Postfix, from userid 20848) id C36CD864F; Tue, 9 Dec 2014 19:54:32 -0500 (EST) In-Reply-To: <87wq60ub14.fsf@gmx.us> (rasmus@gmx.us's message of "Tue, 09 Dec 2014 15:56:39 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.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:179613 Archived-At: >>> Yes, I got rid of it. You probably also need a hook when exiting. Or = the >>> functions in the hook are called with different argument when entering = and >>> exiting the minor-mode. >> I didn't provide the hook. There is the minor mode hook that is normally >> provided. Do you think any more are needed? > IMO: Yes. Cdlatex-org-mode is also a minor mode. So is paredit. I'm not > sure we want to use the same functions for these three projects. > E.g. visual-line-mode may be of interest to your mode, but not to paredit. > See `run-hook-with-args' and `run-hooks' and the like. I think Jo=E3o got it right here: define-minor-mode already defines a hook for that particular minor mode and there shouldn't be a need to define any extra one. Stefan