Bug 405895 - symbol viewer sort order not remembered
Summary: symbol viewer sort order not remembered
Status: RESOLVED FIXED
Alias: None
Product: kate
Classification: Applications
Component: application (show other bugs)
Version: 18.12.3
Platform: openSUSE Linux
: NOR minor
Target Milestone: ---
Assignee: KWrite Developers
URL:
Keywords: junior-jobs
Depends on:
Blocks:
 
Reported: 2019-03-26 13:48 UTC by Peer Frank
Modified: 2019-09-14 13:39 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In: 19.12.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Peer Frank 2019-03-26 13:48:25 UTC
Symbol viewer sorting default direction is ^ (z...a). The head button "Symbols ^" has to be clicked after every launch if one prefers a...z. The sorting direction is not stored on quit. 

KDE Plasma Version: 5.15.3
KDE Frameworks Version: 5.56.0
Qt Version: 5.12.2
Comment 1 Christoph Feck 2019-04-19 08:16:17 UTC
The code in https://cgit.kde.org/kate.git/tree/addons/symbolviewer/plugin_katesymbolviewer.cpp seems to only preserve the sorting order, but doesn't set a default order.
Comment 2 Tore Havn 2019-05-05 22:15:55 UTC
I've been looking at this for a bit, and while there shouldn't be any big technical issues with this, there is a question about the design.

At the moment, only the changes to the settings on the Symbol Viewer Configuration Page are saved. There is a checkbox to «Always sort symbols», but no setting for the sort direction.

In the Symbol Viewer it is possible to turn on and off sorting, and to set the direction. Changing the settings here have no impact on the configured settings however, and are never stored.

Should we:

A) Change the configuration page to add a sort direction option?
B) Change the settings behaviour for Symbol Viewer, so that the changes made in the Symbol Viewer itself are stored?
Comment 3 Peer Frank 2019-05-06 04:44:40 UTC
suggestion C: set default sorting to "a-z" with no setting stored. My guess is that the desire for inverse sorting direction is rather rare.
Comment 4 Lothar 2019-05-07 14:44:50 UTC
If anyone likes, give this a chance 
https://github.com/loh-tar/KatePlugin-IndexView
Comment 5 Tore Havn 2019-09-13 12:46:37 UTC
Git commit c68a443e73c7db5bde7de1e20fcff3513a1ed3ba by Tore Melangen Havn.
Committed on 12/09/2019 at 16:25.
Pushed by torehavn into branch 'symbolviewer-sorting'.

Added a line to set default sort order for the Symbolviewer.

M  +2    -0    addons/symbolviewer/plugin_katesymbolviewer.cpp

https://invent.kde.org/kde/kate/commit/c68a443e73c7db5bde7de1e20fcff3513a1ed3ba
Comment 6 Tore Havn 2019-09-13 12:46:42 UTC
Git commit c68a443e73c7db5bde7de1e20fcff3513a1ed3ba by Tore Melangen Havn.
Committed on 12/09/2019 at 16:25.
Pushed by scmsync into branch 'symbolviewer-sorting'.

Added a line to set default sort order for the Symbolviewer.

M  +2    -0    addons/symbolviewer/plugin_katesymbolviewer.cpp

https://commits.kde.org/kate/c68a443e73c7db5bde7de1e20fcff3513a1ed3ba
Comment 7 Tore Havn 2019-09-13 13:48:35 UTC
(In reply to Lothar from comment #4)
> If anyone likes, give this a chance 
> https://github.com/loh-tar/KatePlugin-IndexView

Thanks. I'll look more on this when I'm a bit more experienced, and see if it's something I can include.