Bug 479169

Summary: Need a "Restore to default settings" for specific apps, not just everything
Product: [Applications] kmenuedit Reporter: Igor Mironchik <igor.mironchik>
Component: generalAssignee: Plasma Bugs List <plasma-bugs-null>
Status: CONFIRMED ---    
Severity: wishlist CC: nate
Priority: NOR Keywords: usability
Version First Reported In: 5.27.10   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Igor Mironchik 2023-12-29 17:27:33 UTC
SUMMARY
***
NOTE: If you are reporting a crash, please try to attach a backtrace with debug symbols.
See https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports
***

Menu Editor doesn't delete *.desktop files from ./local/share/applications folder on deletion of entry from menu


STEPS TO REPRODUCE
1. Create new entry with Menu Editor and save changes.
2. Delete that entry and save changes.
3. 

OBSERVED RESULT

*.desktop file created with Menu Editor still in ./local/share/applications folder. This can lead to UI issues with applications installed by system. For example with Firefox. When it's installed by hands from archive and menu entry created with Menu Editor all works fine. But after deletion of Firefox and installing it with apt user has ugly experience with icons in Task Manager as *.desktop file still there, even with deleted entry with Menu Editor.

EXPECTED RESULT

*.desktop file should be deleted with menu entry by Menu Editor, to prevent such UI issues.


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: KDE neon 5.27
(available in About System)
KDE Plasma Version: 5.27.10
KDE Frameworks Version: 5.113.0
Qt Version: 5.15.11

ADDITIONAL INFORMATION
Comment 1 Nate Graham 2024-02-16 00:18:46 UTC
When you delete an entry in KMenuEdit, you're signaling to the system that you want to hide this item from the system. To do that, it has to put some special line of text in the custom .desktop file generated in ~/.local/share/applications. If deleting item deleted that file, the system would fall back to the system-provided version of it, undoing your changes.

I think you're looking for the "Edit > Restore to System Menu" menu item.
Comment 2 Igor Mironchik 2024-02-16 06:54:00 UTC
But "Restore to System Menu" will delete all my custom menu items! I just want to delete one custom menu item, and when I do it corresponding *.desktop file remain in ./local/share/applications folder, and it play in system, it can lead to strange errors when opening files.
Comment 3 Nate Graham 2024-02-16 18:27:02 UTC
That's fair, I guess we need a "Restore to default settings" for specific apps.