Bug 385919 - Code folding is not kept after the restart of KDevelop
Summary: Code folding is not kept after the restart of KDevelop
Status: RESOLVED FIXED
Alias: None
Product: kdevelop
Classification: Applications
Component: All build tools (show other bugs)
Version: 5.1.2
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: kdevelop-bugs-null
URL: https://phabricator.kde.org/D11601
Keywords:
Depends on:
Blocks:
 
Reported: 2017-10-18 15:48 UTC by Silviu
Modified: 2018-03-25 20:37 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In: 5.3.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Silviu 2017-10-18 15:48:31 UTC
In the last used file I fold all nodes (top level folding)
I restarted KDevelop but all nodes are unfolded, so it didn't keep the last folding nodes.
Comment 1 Kevin Funk 2018-03-25 20:37:35 UTC
Git commit 9d4bd89706ee67a0e335eda3f1732f3eda1f1c23 by Kevin Funk.
Committed on 25/03/2018 at 20:32.
Pushed by kfunk into branch 'master'.

Properly save state of KTextEditor Views

Summary:
Call the KTextEditor::View methods for reading & storing the state:
- KTextEditor::View::readSessionConfig()
- KTextEditor::View::writeSessionConfig()

Remove our implementation of storing the state of ...:
- Cursor
- Selection

By using the KTextEditor methods we do save the states of ...:
- Cursor
- Dynamic Word Wrap
- Text Folding nodes
- ...

Thus, with this patch the storing & retrieving of the selection state is
lost. To be honest, I don't see that as a super useful feature anyway.

FIXED-IN: 5.3.0

Reviewers: mwolff

Reviewed By: mwolff

Subscribers: mwolff, kdevelop-devel

Differential Revision: https://phabricator.kde.org/D11601

M  +12   -31   kdevplatform/shell/textdocument.cpp
M  +3    -2    kdevplatform/shell/textdocument.h
M  +5    -4    kdevplatform/shell/workingsets/workingset.cpp
M  +4    -4    kdevplatform/sublime/view.cpp
M  +18   -4    kdevplatform/sublime/view.h

https://commits.kde.org/kdevelop/9d4bd89706ee67a0e335eda3f1732f3eda1f1c23