Version: (using KDE 4.1.2) Installed from: Ubuntu Packages When the number of profiles gets large (>10 or so), the list in the profile applet gets really confusing and hard to use. It would be very nice, if the list of profiles would use the same order that hopefully will be used by konsole itself at some stage, as soon as wish #168530 is handled. Together with the previously reported wish #173832 , this would give the konsole profile applet basically the same features as the konsole profile menu provides itself.
This is just to add links to the related bugs: bug 173832 wishes for icons in the konsole profile plasmoid, bug 168530 wishes for ordering of konsole profile in the konsole menu.
Is it being looked at? (I'm currently on 4.9 beta2) - Gilboa
I second this wish. Entries in the konsole profiles widget should be sorted the same way as in the konsole "Manage Profiles..." GUI or the "Settings->Switch Profile" menu. Currently (KDE 4.9) these entries are sorted alphabetically. This would be fine for the widget, too. The user could decide to choose profile names that will order the entries in an acceptable way. Also the same profiles would be sorted the same way on different PCs.
I use this widget extensively as I support many systems for my job. The lack of an ordered list (even if it just alphabetic is fine with me) is making this very difficult to use. Is anyone actually looking at this? Please understand I'm not complaining as this work is done by volunteers, but I need to know if I need to look at some other options as my list has now grown to over 50 entries and it's very difficult to quickly locate which profile I need.
I can confirm this bug for openSUSE 12.3 (x86_64) with KDE 4.10.2 and Konsole version 2.10.2. The Konsole profiles seem to have no sorting - at least not alphabetically, which makes finding a specific profile very time consuming.
I can also confirm this on Gentoo Linux (x86_64) with KDE 4.10.2 and Konsole version 2.10.2: no sorting algorithm recognizable, but alphabetical sorting would be desired. In Gentoo Linux, the "Konsole Profiles" widget is in package "kde-base/kdeplasma-addons". Within this source package, one can find "./applets/konsoleprofiles/package/contents/ui/konsoleprofiles.qml". This UI definition contains a "ListView" (with id=view), which seems to hold the profiles we would like to have sorted. But according to http://qt-project.org/forums/viewthread/11108 there is no simple function "ListView.sort()", yet. Quote Andre: "Instead, you could create your model from C++ and use a QSortFilterProxyModel to do the sorting, and then expose that model to your QML." But since I have almost no KDE development experience, this is way too difficult for me to implement. I also found in "./dataengines/konsoleprofiles/konsoleprofilesengine.cpp" a function implementation for "void KonsoleProfilesEngine::loadProfiles()", which seems to look like a good way to sort the profiles. But again: My KDE development skills are not sufficient to even understand, what exactly happens there. But maybe this information might help somebody else to fix this nasty problem. Please. :)
(In reply to comment #6) > I can also confirm this on Gentoo Linux (x86_64) with KDE 4.10.2 and Konsole > version 2.10.2: no sorting algorithm recognizable, but alphabetical sorting > would be desired. Same here with openSUSE 12.3 (x86_64) with KDE 4.10.2. > In Gentoo Linux, the "Konsole Profiles" widget is in package > "kde-base/kdeplasma-addons". Within this source package, one can find > "./applets/konsoleprofiles/package/contents/ui/konsoleprofiles.qml". This UI > definition contains a "ListView" (with id=view), which seems to hold the > profiles we would like to have sorted. > > But according to http://qt-project.org/forums/viewthread/11108 there is no > simple function "ListView.sort()", yet. Quote Andre: "Instead, you could > create your model from C++ and use a QSortFilterProxyModel to do the > sorting, and then expose that model to your QML." > > But since I have almost no KDE development experience, this is way too > difficult for me to implement. > > I also found in "./dataengines/konsoleprofiles/konsoleprofilesengine.cpp" a > function implementation for "void KonsoleProfilesEngine::loadProfiles()", > which seems to look like a good way to sort the profiles. But again: My KDE > development skills are not sufficient to even understand, what exactly > happens there. > > But maybe this information might help somebody else to fix this nasty > problem. Please. :) In fact after learning how QML, DataSource, DataModel, etc. works, fixing this isn't too complicated (as always). Basically you just have to replace the DataModel by a SortFilterModel and to choose an appropriate sortRole and sortOrder. See the attached patch which has to be applied to konsoleprofiles.qml
Created attachment 81839 [details] Patch to konsoleprofiles.qml to enable alphabetical sorting of ListView entries.
I confirm this bug for 4.9.*, 4.10.* and 4.11.* on Fedora 18 and 19. The patch proposed by Norbert Eicker fix the problem. I have to apply it manually every time Fedora update kde. Please apply the patch to trunk.
*** This bug has been confirmed by popular vote. ***
(In reply to comment #9) > I confirm this bug for 4.9.*, 4.10.* and 4.11.* on Fedora 18 and 19. > > The patch proposed by Norbert Eicker fix the problem. > > I have to apply it manually every time Fedora update kde. > > Please apply the patch to trunk. ACK. Works just fine on KDE 4.11.97 (4.12 beta) on Fedora 20. - Gilboa
Git commit f815a5213dde02ce0ae4a6a3c84e66c871421de4 by Christoph Feck, on behalf of Norbert Eicker. Committed on 09/02/2014 at 16:59. Pushed by cfeck into branch 'master'. Sort profiles in Konsole profiles applet FIXED-IN: 4.13 M +6 -2 applets/konsoleprofiles/package/contents/ui/konsoleprofiles.qml http://commits.kde.org/kdeplasma-addons/f815a5213dde02ce0ae4a6a3c84e66c871421de4
Thanks Norbert for the patch! In the future, please use https://reviewboard.kde.org/ for proposing patches.