From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: so-long and special major modes Date: Tue, 08 Dec 2020 00:30:31 -0500 Message-ID: Reply-To: rms@gnu.org Content-Type: text/plain; charset=Utf-8 Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="12387"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Phil Sainty Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Dec 08 06:32:33 2020 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kmVc1-000388-CT for ged-emacs-devel@m.gmane-mx.org; Tue, 08 Dec 2020 06:32:33 +0100 Original-Received: from localhost ([::1]:48638 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kmVc0-0007Lm-CV for ged-emacs-devel@m.gmane-mx.org; Tue, 08 Dec 2020 00:32:32 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58508) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kmVa5-0006cI-94 for emacs-devel@gnu.org; Tue, 08 Dec 2020 00:30:33 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:43936) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kmVa5-0001ly-24; Tue, 08 Dec 2020 00:30:33 -0500 Original-Received: from rms by fencepost.gnu.org with local (Exim 4.82) (envelope-from ) id 1kmVa3-0001HU-Vj; Tue, 08 Dec 2020 00:30:32 -0500 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:260544 Archived-At: [[[ To any NSA and FBI agents reading my email: please consider ]]] [[[ whether defending the US Constitution against all enemies, ]]] [[[ foreign or domestic, requires you to follow Snowden's example. ]]] Emacs distinguishes two kinds of major modes: those that are for a kind of data, and those that correspond to special applications. In the former, q will self-insert. In the latter, q probably means "quit". The way to distinguish is to test the mode-class property of the major mode symbol. Dired, Rmail and Info are examples of special major modes. so-long-major-mode may be ok to use in an ordinary major mode, but it is no good in a special mode. In that situation, it is necessary to use so-long-minor-mode. -- Dr Richard Stallman Chief GNUisance of the GNU Project (https://gnu.org) Founder, Free Software Foundation (https://fsf.org) Internet Hall-of-Famer (https://internethalloffame.org)