GithubHelp home page GithubHelp logo

Comments (3)

Boruch-Baum avatar Boruch-Baum commented on June 12, 2024

This bug would be solved by using the approach taken by package swap-buffers. I saw your response to Chris Rayner that you want the buffer contents to remain visible. You can do that and solve this bug by using their techniue but also copying the visible contents of each visible buffer into its temporary replacement.

I'm thinking now that this project should be combined with that other one, if both parties are interested. Once you solve this bug report, it seems that the only default major difference between the two packages from the end-user's perspective is that one displays the buffer content and the other doesn't. Combining the projects would also bring the advantage that the other package has more advanced labeling options because it's based upon package switch-window. From a content perspective, your code is simpler and smaller and doesn't need the extra dependency, so that's a plus for keeping it a separate package.

from bupper.

se7entyse7en avatar se7entyse7en commented on June 12, 2024

You can do that and solve this bug by using their techniue but also copying the visible contents of each visible buffer into its temporary replacement.

That was exactly what I was thinking, and I was exploring the idea of using indirect buffers. For closing #10, in order to ensure enough space for the overlays, what I did is to exactly copy and restore the whole buffer content. The reason is that in the case of a buffer with the first rows in the window that does not have enough space for the overlay, I insert the required amount of spaces.

This approach though won't fix the duplicated numbering, that's why I was thinking of using indirect buffers:

  • for each window I get the corresponding buffer,
  • clone an indirect buffer from the original one (so if the same buffer is visited from N windows, there will also be N indirect buffers),
  • at this point there's a 1:1 relationship between a window and an indirect buffer, hence numbering is fine,
  • I add the overlays,
  • prompt the selection,
  • swap the indirect buffers,
  • replace indirect buffers with the original ones,
  • delete all indirect buffers.

I'm thinking now that this project should be combined with that other one, if both parties are interested. Once you solve this bug report, it seems that the only default major difference between the two packages from the end-user's perspective is that one displays the buffer content and the other doesn't. Combining the projects would also bring the advantage that the other package has more advanced labeling options because it's based upon package switch-window. From a content perspective, your code is simpler and smaller and doesn't need the extra dependency, so that's a plus for keeping it a separate package.

Thanks a lot @Boruch-Baum for your interest, but at this point, I'm not interested in combining the two packages. The main reason is that I'm currently learning elisp and this package is a great playground. The effort of combining the two packages would make the development move slower compared to working as a solo-developer. For sure it's something that I'd gladly evaluate in the future.

from bupper.

se7entyse7en avatar se7entyse7en commented on June 12, 2024

@Boruch-Baum it would be great if you could give it another try! 🙏

from bupper.

Related Issues (3)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.