How to Remove Calibre Menu Items?

Moderator: Forum moderators

Post Reply
JusGellin
Posts: 754
Joined: Fri Jan 19, 2024 11:12 pm
Has thanked: 90 times
Been thanked: 92 times

How to Remove Calibre Menu Items?

Post by JusGellin »

I installed Calibre as below:

radky wrote: Tue Jun 04, 2024 2:59 pm

Install Calibre in BookwormPup64 as restricted user (spot):

1 - Install the libxcb-cursor0 dependency (run the following in a terminal)

apt update && apt install libxcb-cursor0

2 - Download/install calibre from calibre-ebook.com (run the following in a terminal)

wget -nv -O- https://download.calibre-ebook.com/linux-installer.sh | sh /dev/stdin install_dir=/opt

3 - Install the attached (updated) calibre-run-as-spot-1.1.pet which converts the default calibre flatpak menu items to a Puppy-compatible format.
calibre-run-as-spot-1.1.pet

Later I wanted to just remove the menu items it made. So I removed all the calibre*.desktop files:
The menu items remained there.

I ran fixmenus and jwm -restart
The menu items remained.

I rebooted with a save.
The menu items remained.

They don't seem to want to go away.
Looking at the menu manager, it at first showed the items but now they are gone.
The menu items remain -- and they still work.

How can I permanently remove them so they won't work anymore?

JusGellin
Posts: 754
Joined: Fri Jan 19, 2024 11:12 pm
Has thanked: 90 times
Been thanked: 92 times

Re: How to Remove Calibre Menu Items?

Post by JusGellin »

I tried re-adding the calibre-gui.desktop. So now the menu manager shows Calibre again - its enabled

But the menu under Documents doesn't show Calibre.

It continues to show,E-book editor, E-book viewer and LRF viewer even though there are no desktop files for these.
They all still work from the menu.

Does this mean I messed up the menu system for these and would have to restore from a new installation?

User avatar
RSH
Posts: 127
Joined: Tue May 28, 2024 7:33 pm
Location: Kassel
Has thanked: 59 times
Been thanked: 39 times
Contact:

Re: How to Remove Calibre Menu Items?

Post by RSH »

There is different locations for the .desktop files.
The main location is /usr/share/applications.
Another one is /root/.local/share/applications.
I think to recall a third location, but can't recall where this was.

Instead of removing .desktop files you could add

NoDisplay=true

to the content of such .desktop file.

This will hide the entry from the menu.

Edit:

Of course it would help to have exact information about the Puppy etc. being used.

My OS: ArtStudio64 - a Woof-CE built from Bionic 18.04
Running in RAM only, no save file, no save folder
www.youtube.com/@RainerSteffenHain

User avatar
mikewalsh
Moderator
Posts: 6348
Joined: Tue Dec 03, 2019 1:40 pm
Location: King's Lynn, UK
Has thanked: 878 times
Been thanked: 2071 times

Re: How to Remove Calibre Menu Items?

Post by mikewalsh »

@JusGellin :-

As Rainer says, there are multiple locations for files that generate a Menu entry. /Usr/share/applications is the 'standard' one, /root/.local/share/applications is another. For Puppy, you could perhaps rig one up to run from /root/my-applications..... There is somewhere else, as Rainer says, but I can't remember it either.

You will also find, with many apps that are packed in the AppImage format, that when you fire them up, the very first thing you get is a wee window, which asks you if you want to integrate the app into your desktop environment. If you say no.....it refuses to launch! This, it appears, is part of the AppImage 'toolkit' that developers build them with.....and is checked by default (so most just leave it as-is).

I had one app, some years ago, that no matter how many times you deleted its Menu entry & icon, from every possible location, next boot it was back again. I eventually came to the conclusion that the binary itself had been coded to auto-regenerate any missing files...

It was only when I decided to uninstall the app in question that the errant behaviour finally ceased.

Mike. :o

JusGellin
Posts: 754
Joined: Fri Jan 19, 2024 11:12 pm
Has thanked: 90 times
Been thanked: 92 times

Re: How to Remove Calibre Menu Items?

Post by JusGellin »

@mikewalsh @RSH
Thanks for the good information to help me understand this more. I'll look further into this. I'd like to know enough to be able to make it do what I want it to, like if I wanted to clean up a menu item I could.

I should have listed the version of pup I'm using as well:
Its BookwormPup64_10.0.6

JusGellin
Posts: 754
Joined: Fri Jan 19, 2024 11:12 pm
Has thanked: 90 times
Been thanked: 92 times

Re: How to Remove Calibre Menu Items?

Post by JusGellin »

I found where those menu items were hiding that continued to cause them to still appear in the <menu> <Documents> menu:
/var/lib/flatpak/exports/share/applications
When I delete those *.desktop files, there is no more shown in the menu.

So, I'm always hesitant to just deleting things without knowing what it could cause. Is it ok to delete from there?

Thanks

User avatar
mikewalsh
Moderator
Posts: 6348
Joined: Tue Dec 03, 2019 1:40 pm
Location: King's Lynn, UK
Has thanked: 878 times
Been thanked: 2071 times

Re: How to Remove Calibre Menu Items?

Post by mikewalsh »

JusGellin wrote: Sat Jun 08, 2024 11:32 am

I found where those menu items were hiding that continued to cause them to still appear in the <menu> <Documents> menu:
/var/lib/flatpak/exports/share/applications
When I delete those *.desktop files, there is no more shown in the menu.

So, I'm always hesitant to just deleting things without knowing what it could cause. Is it ok to delete from there?

Thanks

I would assume so. If you've since removed the FlatPaks, there's no point leaving the .desktop files, is there? Many apps don't "cleanly" remove every little item when they uninstall, anyway - long experience has taught me this! - and config files'n'stuff usually get left behind in any case.

Nah; shouldn't hurt at all.

Mike. ;)

Post Reply

Return to “BookwormPup”