From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Krishnakant Newsgroups: gmane.emacs.help Subject: Re: Major and minor modes Date: Wed, 14 Jun 2017 11:51:28 +0530 Message-ID: References: <5202e0d6-4476-4e97-a5cb-f1ee66d562c3@default> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: blaine.gmane.org 1497421344 25554 195.159.176.226 (14 Jun 2017 06:22:24 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Wed, 14 Jun 2017 06:22:24 +0000 (UTC) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 To: Drew Adams , Jean-Christophe Helary , Help Gnu Emacs mailing list Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Jun 14 08:22:20 2017 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dL1h4-0006FO-Nm for geh-help-gnu-emacs@m.gmane.org; Wed, 14 Jun 2017 08:22:18 +0200 Original-Received: from localhost ([::1]:46625 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dL1h8-0004L4-KR for geh-help-gnu-emacs@m.gmane.org; Wed, 14 Jun 2017 02:22:22 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:53545) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dL1gb-0004Jp-36 for help-gnu-emacs@gnu.org; Wed, 14 Jun 2017 02:21:50 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dL1gX-0006SP-Uy for help-gnu-emacs@gnu.org; Wed, 14 Jun 2017 02:21:49 -0400 Original-Received: from lb1.openmailbox.org ([5.79.108.160]:34530 helo=mail.openmailbox.org) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dL1gX-0006RU-MM for help-gnu-emacs@gnu.org; Wed, 14 Jun 2017 02:21:45 -0400 Original-Received: by mail.openmailbox.org (Postfix, from userid 20002) id 23593518A1A; Wed, 14 Jun 2017 08:21:42 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=openmailbox.org; s=openmailbox; t=1497421303; bh=O6wecrLyJq48rJtQ4PnhRXbpDiGooem19NKmxYEAT2c=; h=Subject:To:References:From:Date:In-Reply-To:From; b=NA/woHHiS0kCi5NNSWckg3NT7bPNZewc/I23+hh3an8ucUOaNBw7mx/nqjIRDABdD /4C6k2tOwDz4BLisIURbY4vHi+9jTOd4TSd7xEP0Obq1Zm4qBGptvq3Mt94V7AJEyD hi8QZW39i6hK9uDJwTbMug5qIdeeqv3MJRy7KLxU= DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=openmailbox.org; s=openmailbox; t=1497421302; bh=O6wecrLyJq48rJtQ4PnhRXbpDiGooem19NKmxYEAT2c=; h=Subject:To:References:From:Date:In-Reply-To:From; b=q7CZyUGgIknZN7+lk7JDcL+iUWFY2ruyUDrnkuwNm3EOrnm0+GJ5imjeUHOVp/C/Z KNdIx0WbYXKH9VUK/DbWWKJS0ZJKjC0i54QxdnqLpqbGKpFXeJ+V5rgGU0gmwLw4hc vNRA22v67LcUXjXqGwfZlpI4ajF3LAosLXqJPIjk= In-Reply-To: <5202e0d6-4476-4e97-a5cb-f1ee66d562c3@default> Content-Language: en-US X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 5.79.108.160 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:113444 Archived-At: Read my blog at https://digitallyfreeblog.wordpress.com/ Hopefully you will get more clarity on that subject. Happy hacking. Krishnakant. On Wednesday 14 June 2017 07:19 AM, Drew Adams wrote: >>> Can anyone explain to me clearly how Major modes and minor modes work >> together. Can any minor mode work within any major mode? How do these work >> together? >> >> Everything is explained in Chapter 20 of the Emacs Manual. > Depends what Emacs version you use. For versions 24 and 25 > it is chapter 23, "Major and Minor Modes". For version 23 > it is chapter 27, "Major Modes" and section and 57.1, "Minor > Modes". It is here: > http://www.gnu.org/software/emacs/manual/html_node/emacs/Modes.html > > In sum, a major mode is buffer-specific. > As such, it typically does something appropriate for that > buffer content. > > A minor mode can be buffer-specific (local) or not (global). > Minor-mode key bindings override major-mode key bindings. > A minor mode can do anything at all. What it does need not > be specific for the content of any particular buffer, and > hence for any particular major mode. >