Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Option to "not move" buffers with highlights to the top #541

Open
TehPeGaSuS opened this issue Jun 17, 2022 · 4 comments
Open

Option to "not move" buffers with highlights to the top #541

TehPeGaSuS opened this issue Jun 17, 2022 · 4 comments

Comments

@TehPeGaSuS
Copy link
Contributor

While for some people, with few networks and channels this might not be too bothersome, in my case (more than 250 buffers) it's a little more complicated, especially when I'm in the last buffers on the list.

Because even though I'm in the buffer I'm being highlighted in, that same buffer is sent to the top of the buffer list, which forces me to scroll down through the entire buffer list to get back to the network where that same buffer belongs.

This becomes a bit annoying especially when you're in help channels in different networks and you're highlighted in more than one, and since we have the "Notifications" icon that teleports us directly to the buffer, making the buffer list to remain untouched even when we are highlighted would be neat.

I hope I've made myself clear enough since English isn't my first language.

Cheers!

@oakkitten
Copy link
Collaborator

The idea behind moving hot buffers to the top is so that when you get a highlight, you can see the hot buffer when you open the buffer list, and when you get several highlights, you can see all buffers at once and can decide which one to tap on first. This is a poor man's solution, for the reason you mentioned, and also because the buffers end up on the top of the screen where these can be hard to reach.

While having an option to not move hot buffers to top is a perfectly reasonable request, a better solution would be to allows the user to see or at least to get to all hot buffers without shuffling them around. Ideas welcome! And a PR that implements the option would be welcome as well.

@TehPeGaSuS
Copy link
Contributor Author

Better a late reply then never.

The idea behind moving hot buffers to the top is so that when you get a highlight, you can see the hot buffer when you open the buffer list, and when you get several highlights, you can see all buffers at once and can decide which one to tap on first.

I've been thinking about this and I agree that having all hot buffers at the top is useful for the reasons stated above.

While having an option to not move hot buffers to top is a perfectly reasonable request, a better solution would be to allows the user to see or at least to get to all hot buffers without shuffling them around.

IMHO, we could have an option like Show hot buffers on top? (checked by default to keep the current behaviour), so users could choose.
We already have the option of tapping the 🔔 icon to be able to cycle around the hot buffers and we can select the appropriate notification from the notifications bar to go to a specific hot buffer. I, personally, use the latter more often.

Cheers

oakkitten added a commit that referenced this issue Mar 16, 2024
This changes the boolean preference “Sort buffer list” to a list preference,
with an option to only sort buffers by number.

This does NOT migrate the old setting!

Also, this changes `sortByHotAndMessageCountComparator` to also sort by
number. Not sorting by number could result in buffers appearing out of order
if they were moved. Not a big issue.

Closes #541
oakkitten added a commit that referenced this issue Mar 22, 2024
This changes the boolean preference “Sort buffer list” to a list preference,
with an option to only sort buffers by number.

This does NOT migrate the old setting!

Also, this changes `sortByHotAndMessageCountComparator` to also sort by
number. Not sorting by number could result in buffers appearing out of order
if they were moved. Not a big issue.

Closes #541
oakkitten added a commit that referenced this issue Mar 23, 2024
This changes the boolean preference “Sort buffer list” to a list preference,
with an option to only sort buffers by number.

This does NOT migrate the old setting!

Also, this changes `sortByHotAndMessageCountComparator` to also sort by
number. Not sorting by number could result in buffers appearing out of order
if they were moved. Not a big issue.

Closes #541
@oakkitten
Copy link
Collaborator

7f02197 is an experimental attempt at fixing the issue.

At large, assuming we don't do anything special about the hot buffers, and if all buffers do not fit the screen, the issues with them is as follows:

  1. You might have to scroll to a new hot buffer
  2. If the hot buffer is not on the screen, you don't know whether to scroll, up or down
  3. If there are many hot buffers, you can't easily see them all at once and can't pick and choose which one to open

Current master solves this in a dumb way, by placing all hot buffers together on the top, and scrolling to the top. It is simple but the obvious drawbacks are:

  • The position of the buffer list is lost
  • Buffer list may start to scroll while you are actively interacting with it
  • Reordering buffers means that you may fail to find a buffer you are looking for where it usually is
  • Scrolling animation + buffer move (well, remove + add) animation just don't look very good together

The branch pointing to 7f02197 adds an option to keep the buffer list ordered by number even when there are hot buffers, instead adding tappable arrows that scroll to the next hot buffer above or below visible buffers, if any. Also, automatic scrolling is only performed if the buffer list isn't visible, and only when we get a new hot buffer. While this works,

  • It solves the issue № 1 only partially, and doesn't solve issue № 3 at all
  • As it still does automatically scroll, the position might be lost

Now, we can add more options to suit more use-cases, but going this way will still have drawbacks. I wonder if anyone has better ideas.

@TehPeGaSuS
Copy link
Contributor Author

Also, automatic scrolling is only performed if the buffer list isn't visible

This is exactly what I was expecting not to happen. This is what I've said on IRC:

<PeGaSuS> in my case, sometimes I'm at the very end of all buffers (222 in my case). then I'm highlighted on buffer 107 but I don't want to check it right away but I need to say something on buffer 220. so, I need to scroll down through all buffers again to buffer 220

Yes, this only happens when the buffers list isn't visible but that's what happens most of the times.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants