[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Same file on two buffers - Two different major modes
From: |
Christopher Dimech |
Subject: |
Re: Same file on two buffers - Two different major modes |
Date: |
Wed, 4 Nov 2020 13:30:18 +0100 |
Se you get a shitty buffer! Is there a need for a fix? The
principal idea is to have the same buffer next to each other,
where one can change the major mode on each buffer, but saves
to the save buffer.
> Sent: Wednesday, November 04, 2020 at 1:08 PM
> From: "Joost Kremers" <joostkremers@fastmail.fm>
> To: "Christopher Dimech" <dimech@gmx.com>
> Cc: help-gnu-emacs@gnu.org
> Subject: Re: Same file on two buffers - Two different major modes
>
>
> On Wed, Nov 04 2020, Christopher Dimech wrote:
> > Can one have two buffers of the same file, next to each other,
> > but in different modes. When I change one buffer, the major mode
> > of the other is changing automatically.
>
> You probably have two *windows* displaying the *same* buffer. I don't think
> you
> can have two buffers visiting the same file, because visiting a file first
> checks if the file is already being visited.
>
> As pointed out by others, you could use an indirect buffer, but that's not a
> perfect solution, because it messes up font lock (apparently among other
> things).
>
> --
> Joost Kremers
> Life has its moments
>
Re: Same file on two buffers - Two different major modes, Jean Louis, 2020/11/04
Re: Same file on two buffers - Two different major modes, Marcin Borkowski, 2020/11/04