nyxt icon indicating copy to clipboard operation
nyxt copied to clipboard

Creating a buffer for internal page doesn't branch history

Open aadcg opened this issue 1 year ago • 5 comments

Currently when a user visits the changelog and clicks a link to slot, issuing history-backwards is a no-op since there are no known places to return to. From the user's perspective, this is very confusing. In other words, when (current-buffer) is an internal page, the invocation below returns nil. I'm not sure if this is a bug or a feature that is missing.

(with-history (history (current-buffer))
  (let ((owner (htree:owner history (id (current-buffer)))))
    (htree:all-parents history :owner owner)))

It would be nice if all internal pages had an isolated container for history entries.

aadcg avatar Jun 28 '23 12:06 aadcg

They are supposed to, it's almost certainly a bug and may be related to #3051.

Ambrevar avatar Jun 29 '23 10:06 Ambrevar

They are supposed to, it's almost certainly a bug and may be related to #3051.

I thought so too, but I created separate issues nonetheless.

aadcg avatar Jun 29 '23 11:06 aadcg

clicks a link to slot

Does this also happen with link hints? If not, that's #2950/#2634. Clicks not being properly inspected is a huge problem with our history mechanism, because there's too much noise/vacuum link clicks create.

That's why I really want to merge #2950—it fixes lots of problems, while only introducing a minor UX cludge for a rare use case.


Let's close this, unless it doesn't work with link hints too.

aartaka avatar Jun 29 '23 13:06 aartaka

@aartaka, this issue is not related to that.

Here's a simple recipe:

  • nyxt --failsafe
  • M-x changelog
  • M-x describe-command RET changelog
  • M-x history-backwards
  • "No backward history".

aadcg avatar Jun 29 '23 14:06 aadcg

Ah, it's this one. Then, the problem is the set of situations where we branch the history out from the current buffer. Now, it seems, history doesn't branch if we create an internal page. I guess it should.

Still, it's not related to internal pages themselves, it's about our history management not working to its full potential in regards to intuitiveness 😃

aartaka avatar Jun 29 '23 15:06 aartaka