giuspen / cherrytree

cherrytree
https://www.giuspen.net/cherrytree/
Other
3.29k stars 457 forks source link

Scrollbar position/line not remembered for individual nodes #2460

Open BileDemon opened 3 months ago

BileDemon commented 3 months ago

Version, Operative system CherryTree 1.1.0 / Kubuntu 23.10

Describe the bug Unfortunately with the latest version 1.1.0 CherryTree somehow doesn't remember any individual scrollbar positions or line numbers anymore, when switching between nodes. Only the very last scrollbar position is taken into account, no matter which node I select. Can you please revert this behaviour to how it was before, where it remembered the scrollbar positions AT LEAST for the last 3 or 4 nodes. If possible, can you please extend this to even more nodes, because sometimes it was upsetting how CherryTree regularly forgot the scrollbar position when I clicked around in the tree too much.

To Reproduce

  1. Select any random node in the tree, click on text in line number 308 or something.
  2. Select any other node, which contains at least as many lines: The scrollbar goes directly to line 308.
  3. Click on a different line number, like 555.
  4. Select yet another node in the tree. The scrollbar goes directly to line 555.
giuspen commented 3 months ago

Sure I'll fix this in the next few days

giuspen commented 3 months ago

This should be now fixed. If you could try the test build from https://www.giuspen.net/cherrytree/#testing (called 1.1.0+5) and report if that works as expected or still has issues it would be very useful

BileDemon commented 3 months ago

Yes, the test version works really great. Each node remembers its individual line number, the scroll bar matches the last edit positions. I can even edit as many nodes as I want, and it no longer seems to forget what I edited much earlier.

This is so much better. Thanks for fixing this!