Created attachment 164135 [details] Screen recording of the steps to reproduce SUMMARY When searching in the Application Dashboard, the search result shows all possible categories even though they don't contain any search result. What makes this especially problematic is that actual search results can get "hidden" by the empty categories and can only be seen by scrolling down. (see attached screen recording) STEPS TO REPRODUCE 1. Open Application Dashboard 2. Type something like Kate or Konsole to search OBSERVED RESULT Beside search results, lots of empty categories are shown. One maybe needs to scroll to down to see all actual ssearch results. EXPECTED RESULT Only search results are shown (that's the case in the P5 version of the Dashboard). SOFTWARE/OS VERSIONS KDE Plasma Version: 5.90 KDE Frameworks Version: 5.247 Qt Version: 6.6.1 ADDITIONAL INFORMATION Reproduced on up-to-date Neon Unstable installation and a VM with openSuse Krypton live image.
Can reproduce.
*** Bug 486105 has been marked as a duplicate of this bug. ***
Created attachment 172120 [details] Patch to fix the empty categories by enabling runnerModel.mergedResults Preliminarily results of investigating the cause of this bug: * To get "merged search results" like in kicker menu, add runnerModel.mergeResults = true; at bottom of onVisibleChanged() of Kicker.DashboardWindow.root in DashboardRepresentation.qml (see attached diff file). While this will not restore the exact same layout for search results as in Plasma 5, it _does_ effectively solve the problem of displaying empty categories that clutter the actual search results. (Shall I start a merge request?) * Couldn't find a way to restore the exact same behaviour as in Plasma 5 (grouping search results by categories, but don't show empty categories) after spending several hours on different days. If I got it right, the path forward should be to filter out all RunnerMatchesModels that contain no search results, but I couldn't figure out on which place I could inject code that would do this (possible candidates: DashboardRepresentation.qml? runnermodel.cpp? runnermatchesmodel.cpp?). It seems I would need to have better knowledge/undestanding of QML/Qt/C++ to tackle this. Why this worked fine in Plasma 5 I'm not sure. My two hypothesises are that either: * there was code that somehow was responsible for not showing empty categories, but it was (accidentally?) changed/deleted during conversion to Plasma 6; or * there was no actual code filtering out empty categories; this was just working implicitly "right" for Qt5, while something changed in Qt6 that makes it not working anymore (and adds the necessity to explicitly handle the filtering somewhere).
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-desktop/-/merge_requests/2439
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-desktop/-/merge_requests/2483
Git commit 7ca2c3a7ddee9f909634214e082921c3a065496d by Nate Graham, on behalf of Marco Martin. Committed on 30/08/2024 at 03:22. Pushed by ngraham into branch 'master'. Hide empty categories in ItemMultiGridView, hide empty categories so krunner search results don't get cluttered by them M +1 -0 applets/kicker/package/contents/ui/ItemMultiGridView.qml https://invent.kde.org/plasma/plasma-desktop/-/commit/7ca2c3a7ddee9f909634214e082921c3a065496d
Git commit 33b4cecfa94d4a4b0c5c10de8940026b18092fd5 by Nate Graham. Committed on 30/08/2024 at 04:20. Pushed by ngraham into branch 'Plasma/6.1'. Hide empty categories in ItemMultiGridView, hide empty categories so krunner search results don't get cluttered by them (cherry picked from commit 7ca2c3a7ddee9f909634214e082921c3a065496d) 7ca2c3a7 Hide empty categories Co-authored-by: Marco Martin <notmart@gmail.com> M +1 -0 applets/kicker/package/contents/ui/ItemMultiGridView.qml https://invent.kde.org/plasma/plasma-desktop/-/commit/33b4cecfa94d4a4b0c5c10de8940026b18092fd5