| Summary: | Bookmarks are lost after the file is reloaded from "Documents modified on Disk" window | ||
|---|---|---|---|
| Product: | [Applications] kate | Reporter: | Dmitri Koulikoff <kde> |
| Component: | general | Assignee: | KWrite Developers <kwrite-bugs-null> |
| Status: | CONFIRMED --- | ||
| Severity: | wishlist | CC: | christoph, nfxjfg |
| Priority: | NOR | ||
| Version First Reported In: | 21.12.1 | ||
| Target Milestone: | --- | ||
| Platform: | Slackware | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
|
Description
Dmitri Koulikoff
2022-01-17 13:36:26 UTC
They are only restored if the text lines for the marks have not changed. e.g. if you insert a new line at the beginning of the document externally, all marks will vanish. If you just append lines, all should stay. This is handled in bool KTextEditor::DocumentPrivate::documentReload() (In reply to Christoph Cullmann from comment #1) > They are only restored if the text lines for the marks have not changed. > e.g. if you insert a new line at the beginning of the document externally, > all marks will vanish. > If you just append lines, all should stay. > This is handled in bool KTextEditor::DocumentPrivate::documentReload() The lines with the bookmarks I'm losing never change. Even if a line is changed the bookmark must not be lost, since a diff is available. Hi, the algorithm is as described below. And no, there is no diff available as that is not implemented in the editor. Naturally one can improve this by implementing a more versatile detection how to move the bookmarks, but that must be done. At the moment, if lines move, their bookmarks are lost. You are free to improve this behavior or find somebody how does that. And this is no grave bug, sorry, not each and every behavior that doesn't fit your needs is a grave issue. For others it is inconvenient if bookmarks end up on wrong lines. (In reply to Christoph Cullmann from comment #3) > Hi, > > the algorithm is as described below. > > And no, there is no diff available as that is not implemented in the editor. The diffs are available at the moment I press "Reload" since below is a button "See the diff". > > Naturally one can improve this by implementing a more versatile detection > how to move the bookmarks, but that must be done. I could but I have no time. > > At the moment, if lines move, their bookmarks are lost. It is very easy to implement not to do that. Just leave them where they are. > > You are free to improve this behavior or find somebody how does that. Thanks, If I had time or a guy I'd do that, but I do not. > > And this is no grave bug, sorry, not each and every behavior that doesn't > fit your needs is a grave issue. This is really a grave bug as I have to restore 100 bookmarks every week. Is not it? > For others it is inconvenient if bookmarks end up on wrong lines. It is much better than losing them completely. Make a poll. *** Bug 407602 has been marked as a duplicate of this bug. *** |