As I understand, the checkbox for Keep meta-information past sessions controls Kate remembering the last edited place in the file and re-opens the file to that place. However, unchecking that box and deleting the sessions info (~/.kde/share/apps/kate/sessions) is resulting in Kate still remembering places in edited files, but not all of them. On the files it does occur on, it always occurs. Reproducible: Always Steps to Reproduce: 1. Uncheck meta information box 2. Re-open previously edited file Actual Results: 3. Kate opens file in last edited place (sometimes) Expected Results: Kate opens file with cursor and view at top of file Kate version 3.9.5 Kde version 4.95
Ben Cooksley over at the KDE forums has identified ~/.kde/share/config/katerc as the actual home for the last-edited-place information, along with tons of other information. Therefore, this bug report should become a wishlist request for Kate to add a GUI feature to disable the remembering of the last-edited-place. Renaming or better explaining the meta-information checkbox would also be helpful.
Changing this back to a bug because the solution listed above does not work in all (or most) cases. Kate still remembers the last edited place, even after unchecking the meta-information checkbox and deleting katerc.
There is a What's this help telling you that it's for instance about bookmarks. Looking at the code, the *document* it will save/load: - the encoding - the mode/filetype - the highlighting style - the indentation mode - the bookmarks - the state of the code folding This depends on the variable m_saveMetaData in KateDocManager. However, KateViewSpace::saveConfig() and ::restoreConfig() always calls write/readSessionConfig() of all views, saving the line/column in KateView::writeSessionConfig(). If you do not want the line/column tuples to be saved, KateViewSpace would need to honor m_saveMetaData from KateDocManager. Care to send a patch? Just follow http://kate-editor.org/get-it/ to build and patch Kate.
Btw, what's the problem with Kate remembering the cursor position?
The problem is that I don't want Kate to remember the cursor position, yet it insists (usually) on remembering the cursor position. I would like every document to open with the cursor at the top, rather than where it was when I last saved the document. At the very least a configurable setting to reset the cursor position on every load.
> At the very least a configurable setting to reset the cursor position on every load. I object, since if we add an option for such small details, we'll end up with thousands of options. There are two solutions: a) close this report as wont-fix b) honor this in the option [x] Keep Meta Data
Generally, I agree with you, and I would prefer option B, honoring this as part of Keep Meta Data. Isn't that exactly what this is - keeping metadata after the file has been closed? Were any case studies done to determine if this behavior is preferred by users of the software, or was it just added in for some other reason? Please don't close it as a Won't Fix until there's persuasive evidence that this is the designed behavior, rather than being because it didn't get put under Keep Meta Data. Thanks.
Created attachment 77643 [details] Patch to disable saving any viewspace metadata (cursor position, jump lists, etc.) if so configured I was in the code for something unrelated and happened to have seen this bug earlier today via a G+ link about junior jobs. This makes this part of katerc go from: [MainWindow0-Splitter 0] Children=MainWindow0-ViewSpace 0 Sizes=982 [MainWindow0-ViewSpace 0] Active View=file:///home/jdubovsky/test.txt Count=1 View 0=file:///home/jdubovsky/test.txt [MainWindow0-ViewSpace 0 file:///home/jdubovsky/kde/kate/kate/app/kateviewspace.cpp] CursorColumn=67 CursorLine=204 JumpList= ViMarks= to: [MainWindow0-Splitter 0] Children=MainWindow0-ViewSpace 0 Sizes=982 [MainWindow0-ViewSpace 0] Active View=file:///home/jdubovsky/test.txt Count=1 View 0=file:///home/jdubovsky/test.txt I don't know much at all about the internals of KEdit, but perhaps this patch will help.
Thinking about it, it's rather session related information. Maybe we should add an option to the Sessions config tab in "Elements of Sessions"?
Dear user, this wish list item is now closed, as it wasn't touched in the last two years and no contributor stepped up to implement it. The Kate/KTextEditor team is very small and we can just try to keep up with fixing bugs. Therefore wishs that show no activity for two years or more will be closed from now on to keep at least a bit overview about 'current' wishs of the users. If you want your feature to be implemented, please step up to provide some patch for it. If you think it is really needed, you can reopen your request, but keep in mind, if no new good arguments are made and no people get attracted to help out to implement it, it will expire in two years again. We have a nice website kate-editor.org that provides all the information needed to contribute, please make use of it. For highlighting improvements our user manual shows how to write syntax definition files. Greetings Christoph