From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alexander Katovsky Newsgroups: gmane.emacs.help Subject: Re: syntax parsing of non-contiguous regions Date: Mon, 21 Sep 2009 20:28:20 +0100 Message-ID: <4AB7D3D4.3000901@googlemail.com> References: <4AB53B94.2070307@googlemail.com> <4AB68EDF.7090902@easy-emacs.de> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1253569801 15319 80.91.229.12 (21 Sep 2009 21:50:01 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 21 Sep 2009 21:50:01 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: =?ISO-8859-1?Q?Andreas_R=F6hler?= Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Sep 21 23:49:54 2009 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1Mpqlc-0001Yj-SC for geh-help-gnu-emacs@m.gmane.org; Mon, 21 Sep 2009 23:49:53 +0200 Original-Received: from localhost ([127.0.0.1]:52138 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mpqlc-0007VP-EC for geh-help-gnu-emacs@m.gmane.org; Mon, 21 Sep 2009 17:49:52 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MpoYi-0004zg-2E for help-gnu-emacs@gnu.org; Mon, 21 Sep 2009 15:28:24 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MpoYc-0004wg-PL for help-gnu-emacs@gnu.org; Mon, 21 Sep 2009 15:28:23 -0400 Original-Received: from [199.232.76.173] (port=54388 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MpoYc-0004wd-Li for help-gnu-emacs@gnu.org; Mon, 21 Sep 2009 15:28:18 -0400 Original-Received: from mail-ew0-f211.google.com ([209.85.219.211]:58754) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MpoYc-00034m-6r for help-gnu-emacs@gnu.org; Mon, 21 Sep 2009 15:28:18 -0400 Original-Received: by ewy7 with SMTP id 7so3315558ewy.31 for ; Mon, 21 Sep 2009 12:28:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from :user-agent:mime-version:to:cc:subject:references:in-reply-to :content-type:content-transfer-encoding; bh=EIF9porhTYG9lAtjVJBg6GRqMnLExmfkC+MxjEIjI1w=; b=I59PQgBLx/irsPC5hq4+eIPMRhyrIPfW9WZ4Msa4FIjjFW3WsN6lwqjpe9lA5Mk3hh 6abQi6e3pwIeo3OiJ5qgZPa5cENcLnAgZ3yi95zMw9SIHouzdH1PAsK/8LXuds2uyT8R 22vPCzGRZeXBR3AhoSeHxN19GTHNc6ehtF1a4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; b=GwD5PMUU17XiLW4p8ef51haVULGauuuKYfATw8rWyX+pCo8khPD1NImXpKB0xXJeC/ ube5SHVCKCKZmbLa0vNlFNX6iuml7/ZanWDQmGQi4Lj8bdALIoIU1NWivRPJw9+iMmIn M1wr1+7EM2FiLcUtQeaYsD3rsBHV/CDxv+cYM= Original-Received: by 10.210.96.1 with SMTP id t1mr579ebb.17.1253561295058; Mon, 21 Sep 2009 12:28:15 -0700 (PDT) Original-Received: from ?192.168.1.65? (94-195-68-122.zone9.bethere.co.uk [94.195.68.122]) by mx.google.com with ESMTPS id 28sm46887eyg.17.2009.09.21.12.28.12 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 21 Sep 2009 12:28:13 -0700 (PDT) User-Agent: Thunderbird 2.0.0.16 (X11/20080724) In-Reply-To: <4AB68EDF.7090902@easy-emacs.de> X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) X-Mailman-Approved-At: Mon, 21 Sep 2009 17:47:38 -0400 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:68352 Archived-At: Hi, Thanks for your reply. The reason that I want to do this is to make a major mode that supports embedded code (i.e. two major modes). I have a strategy for doing this that would be well suited to my specific problem and is different from the multi-mode implementations I have seen. The new mode will be derived from the primary mode. The fontification in the primary mode will provide a hook that the derived mode can use to fontify the embedded code. This will work very elegantly if I can define the embedded code as a comment in the derived mode. In this way, the parent mode will simply ignore the embedded code entirely, so that it will not interfere in any way with the primary code, and I can decide what to do with it later.