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: web-mode.el Date: Mon, 18 Jun 2012 23:09:51 -0400 Message-ID: References: <4FD9F40C.90406@yandex.ru> <4FDA927D.50306@yandex.ru> <4FDC89B7.3050907@yandex.ru> <4FDFCF27.8000309@yandex.ru> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1340075408 19783 80.91.229.3 (19 Jun 2012 03:10:08 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 19 Jun 2012 03:10:08 +0000 (UTC) Cc: cyd@gnu.org, lennart.borgman@gmail.com, emacs-devel@gnu.org To: Dmitry Gutov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jun 19 05:10:07 2012 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 1SgopP-0001UI-J3 for ged-emacs-devel@m.gmane.org; Tue, 19 Jun 2012 05:10:03 +0200 Original-Received: from localhost ([::1]:40911 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SgopP-0006P2-9y for ged-emacs-devel@m.gmane.org; Mon, 18 Jun 2012 23:10:03 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:35916) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SgopL-0006Om-Fq for emacs-devel@gnu.org; Mon, 18 Jun 2012 23:10:00 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SgopJ-0003wC-RA for emacs-devel@gnu.org; Mon, 18 Jun 2012 23:09:59 -0400 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.182]:12071) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SgopH-0003v2-9H; Mon, 18 Jun 2012 23:09:55 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av0EAG6Zu09FxINN/2dsb2JhbABEtBGBCIIVAQEEAVYjBQsLDiYSFBgNJIgcBboJkEQDozOBWIMF X-IronPort-AV: E=Sophos;i="4.75,637,1330923600"; d="scan'208";a="191676965" Original-Received: from 69-196-131-77.dsl.teksavvy.com (HELO pastel.home) ([69.196.131.77]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 18 Jun 2012 23:09:52 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id B4913592C5; Mon, 18 Jun 2012 23:09:51 -0400 (EDT) In-Reply-To: <4FDFCF27.8000309@yandex.ru> (Dmitry Gutov's message of "Tue, 19 Jun 2012 05:00:23 +0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 206.248.154.182 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:151010 Archived-At: > compatibility. From what I understand, `widen' is used to counteract the > situation when a user calls `narrow-to-region' interactively. Yes, and that is a problem that needs fixing: as mentioned elsewhere on emacs-devel several months (years?) ago, Emacs needs to distinguish between "narrow as a way to make the rest invisible" and "narrow to pretend the rest doesn't exist at all". C-x n n does the first, while the second was used by Rmail, is used by Info, and could be used by a multi-major-mode. > It occurs to me that, once the supported interface is established, > introducing new syntax-table value becomes not strictly necessary because, > for example, a version of Lennart's `with-chunks' macro can be implemented > in Lisp by applying whitespace or comment-starter/ender syntax to foreign > chunks around the body calls (idea from mmm-noweb). > Is that right? That's right as long as you're willing to dynamically modify the buffer (with syntax-table text-properties) every time you move from one chunk to another. If you have many chunks, that can be a problem. This can happen if you push the idea of multi-major-mode a bit further and consider for example that comments and strings are really "text-mode chunks" embedded in "some other mode chunks". Stefan