all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Christopher Dimech <dimech@gmx.com>
To: Joost Kremers <joostkremers@fastmail.fm>
Cc: help-gnu-emacs@gnu.org
Subject: Re: Same file on two buffers - Two different major modes
Date: Wed, 4 Nov 2020 13:30:18 +0100	[thread overview]
Message-ID: <trinity-7e423512-4ea1-4f61-a689-ed22eac1f4cf-1604493018120@3c-app-mailcom-bs01> (raw)
In-Reply-To: <87v9elgw8v.fsf@fastmail.fm>

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
>



  reply	other threads:[~2020-11-04 12:30 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-04 11:37 Same file on two buffers - Two different major modes Christopher Dimech
2020-11-04 11:52 ` Philipp Stephani
2020-11-04 11:57   ` tomas
2020-11-04 11:55 ` tomas
2020-11-04 12:08 ` Joost Kremers
2020-11-04 12:30   ` Christopher Dimech [this message]
2020-11-04 21:40     ` Drew Adams
2020-11-04 21:47       ` Christopher Dimech
2020-11-04 22:16         ` Drew Adams
2020-11-05  0:50         ` Emanuel Berg via Users list for the GNU Emacs text editor
2020-11-04 12:30 ` Jean Louis
2020-11-04 21:18 ` Marcin Borkowski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=trinity-7e423512-4ea1-4f61-a689-ed22eac1f4cf-1604493018120@3c-app-mailcom-bs01 \
    --to=dimech@gmx.com \
    --cc=help-gnu-emacs@gnu.org \
    --cc=joostkremers@fastmail.fm \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.