emacs-devel
[Top][All Lists]
Advanced

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

RE: Request for pointers and advice: displaying several buffers inside a


From: Ihor Radchenko
Subject: RE: Request for pointers and advice: displaying several buffers inside a single window
Date: Sat, 11 Apr 2020 16:11:34 +0800

> To be clear, there's no need to cycle among zones.
> No need to see only one at a time. You can see all
> of them all of the time, as well as see the other,
> non-zone text, of any and all buffers.
>
> What zones.el does not offer is showing the text
> of more than one buffer in the same Emacs window.

I was not able to achieve this. Do you mean that zones located more than
one screen away in the same buffer can be shown all together resulting
in a narrowing with multiple zones shown one after other without text
between them?

> Maybe consider this feedback as just letting you
> know that I, at least, don't quite understand
> what you're trying to do (or why).
>
> Emacs doesn't let you use the same window for
> multiple buffers, as far as I know.

I am trying to suggest something for displaying text from multiple
buffers in a single window. My idea is to modify Emacs buffer internals
to achieve this.

> Emacs doesn't let you use the same window for
> multiple buffers, as far as I know.
>
> You can finagle ways to show text from multiple
> buffers in the same window, e.g. by copying it.
> And if you do that, and you then want to edit
> the copies, then, yes, you'll need to then sync
> up the original buffers with your edits.
>
> Maybe there's a library that does that for you.

I am not aware of such library, except the one I am working on. However,
any lisp level implementation is likely to slow Emacs more than if it is
done on C level.

> I wonder what your reason is for wanting that?
> That "why" might help explain your request.

I think the reasons were discussed in
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=35419 and popped up
several times in internet:

- https://github.com/alphapapa/transclusion-in-emacs/
- https://lists.gnu.org/archive/html/emacs-devel/2018-07/msg00863.html
- 
https://www.reddit.com/r/orgmode/comments/fimdf7/nesting_many_org_source_files_into_the_same_window/

For me, the reasons are mostly related to org mode. For example, it
would be cool to have the same org heading in multiple places (and be
able to edit the heading from any of those places).


Drew Adams <address@hidden> writes:

>> I tried zones once, but abandoned exactly
>> because I was looking for showing all zones at once (not cycling
>> through them).
>
> To be clear, there's no need to cycle among zones.
> No need to see only one at a time. You can see all
> of them all of the time, as well as see the other,
> non-zone text, of any and all buffers.
>
> What zones.el does not offer is showing the text
> of more than one buffer in the same Emacs window.
>
>> > But if your question/request is about displaying text from different
>> buffers in the same Emacs window then zones.el won't help you.
>> 
>> Yep. Displaying and editing (with synchronised changes in those
>> buffers).
>
> See above.  You can display and edit all zones at
> the same time.  And there's no synchronization
> needed.  What you can't do with zones is show and
> edit the text of more than one buffer in the same
> Emacs window.
>
> I say all of this only in case it helps somehow.
> My intention is not to have you use zones.el.
>
> Maybe consider this feedback as just letting you
> know that I, at least, don't quite understand
> what you're trying to do (or why).
>
> Emacs doesn't let you use the same window for
> multiple buffers, as far as I know.
>
> You can finagle ways to show text from multiple
> buffers in the same window, e.g. by copying it.
> And if you do that, and you then want to edit
> the copies, then, yes, you'll need to then sync
> up the original buffers with your edits.
>
> Maybe there's a library that does that for you.
>
> There are libraries that let you put different
> parts of the same buffer in different major
> modes (in effect).  But that too is different
> from having multiple buffers in the same window.
>
> I wonder what your reason is for wanting that?
> That "why" might help explain your request.

-- 
Ihor Radchenko,
PhD,
Center for Advancing Materials Performance from the Nanoscale (CAMP-nano)
State Key Laboratory for Mechanical Behavior of Materials, Xi'an Jiaotong 
University, Xi'an, China
Email: address@hidden, address@hidden



reply via email to

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