I’m trying to add a context menu to convert selected image to .webp format. I already search for it but only for Nautilus and still figuring out how to do that in PCManFM-Qt.
Things that I already tried:
Could you please explain what are you trying to do (if possible in detail) and show us the .desktop file used and the .sh script willing to be executed?
I’m trying to create a context menu, (Right click > Convert WebP) so that all .png image file in the folder converted into .WebP file format. The context menu didn’t even show up.
I have tried to do the same as you are asking with other action (open a file with lximage-qt).
I think that it can help you despite the fact that the right click context menu only works over folders.
Instructions:
i) Create this folder:
~/.local/share/file-manager/actions
ii) Create a new file inside the created folder which filename must end in .desktop
Example: “open with lximage-qt.desktop”
$HOME/.local/share/file-manager/actions/open with lximage-qt.desktop
iii) Inside “open with lximage-qt.desktop” file, copy this:
[Desktop Entry]
Type=Action
Tooltip=open with lximage-qt
Profiles=profile-zero;
Name=open with lximage-qt
Icon=/usr/share/icons/gnome/32x32/apps/preferences-desktop-accessibility.png
Exec=/usr/bin/lximage-qt %u