[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Emacs vs. TextMate (not trying to start an editor war)

From: Lennart Borgman (gmail)
Subject: Re: Emacs vs. TextMate (not trying to start an editor war)
Date: Sat, 12 Jul 2008 01:11:20 +0200
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/20071031 Thunderbird/ Mnenhy/

Tom Tromey wrote:
"Miles" == Miles Bader <address@hidden> writes:

Miles> What is really desirable, I think, is some way of transparently fooling
Miles> "whole buffer" modes into thinking they have control of a whole buffer,
Miles> when in fact, they just have control of part of one.  I think it's
Miles> probably possible to do this (perhaps using an extension of the indirect
Miles> buffer mechanism?) but afaik nobody has really looked at the problem
Miles> closely.

Have you looked at MuMaMo?  I thought it did this kind of thing.  But,
I have not looked at it and I don't know the details.

MuMaMo (which is part of nXhtml) does something like that, yes.

But it does this by trying to handle buffer local variables and fontification carefully. Doing it this way I could make it to work with Emacs 22. I think somewhere in the future with some more experience with this we may want to rewrite some structures in Emacs to better support this.

However my impression is that such structures should hide part of the buffer rather than just giving one continuous part of the buffer to the major mode. This will make it easier to handle major modes that parses the buffer.

Take for example XHTML buffers versus XHTML template buffers. For an XHTML buffer (ie containing an .xhtml file) the whole buffer can be parsed by nxml-mode (or a mode derived from it). For a template language the situation is different. In that case only (non-consecutive) parts can be parsed by nxml-mode.

This situation is today handled by MuMaMo + a patch to nxml-mode.

There are of course also other details to think of.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]