You are not logged in.

#1 2012-06-18 09:54:49

OhBoy
Member
Registered: 2012-06-07
Posts: 12

[Solved] Opening images on Nautilus

Hello everyone,

I'm using feh as my image viewer, and I wanted to be able to make it start when double clicking on an image, while using Nautilus. The problem is feh doesn't appear in the application list Nautilus has. How can I add it?

I'm not using Gnome, I just installed nautilus, and I'm using OpenBox as a stand-alone window manager. I'm not sure if that's enough information about the system.

I'm sorry if this has been posted before, but I couldn't find a thread about it.

Last edited by OhBoy (2018-03-06 10:28:33)

Offline

#2 2012-06-18 12:28:29

Terminator
Member
From: Belgium
Registered: 2012-05-07
Posts: 265

Re: [Solved] Opening images on Nautilus

Have a look at nautilus-actions, an extension that allows you to define custom commands to open certain files.

Last edited by Terminator (2012-06-18 12:28:59)

Offline

#3 2012-06-18 12:46:53

jakobcreutzfeldt
Member
Registered: 2011-05-12
Posts: 1,042

Re: [Solved] Opening images on Nautilus

You need to register some MIME types with it and give it a .desktop file so that Nautilus knows about feh.

Here's an example, which you could put in /usr/share/applications/feh.desktop. You'll want to edit it to specify an icon and to make sure that all the correct MIME types are listed (I just copied this from eog).

[Desktop Entry]
Name=feh
TryExec=feh
Exec=feh %U
Icon=eog
StartupNotify=true
Terminal=false
Type=Application
Categories=Graphics;RasterGraphics;Viewer;
MimeType=image/bmp;image/gif;image/jpeg;image/jpg;image/pjpeg;image/png;image/tiff;image/x-bmp;image/x-gray;image/x-icb;image/x-ico;image/x-png;image/x-portable-anymap;image/x-portable-bitmap;image/x-portable-graymap;image/x-portable-pixmap;image/x-xbitmap;image/x-xpixmap;image/x-pcx;image/svg+xml;image/svg+xml-compressed;image/vnd.wap.wbmp;

Then just run

# update-desktop-database

Last edited by jakobcreutzfeldt (2012-06-18 12:47:54)

Offline

#4 2012-06-19 09:34:48

OhBoy
Member
Registered: 2012-06-07
Posts: 12

Re: [Solved] Opening images on Nautilus

jakobcreutzfeldt wrote:

You need to register some MIME types with it and give it a .desktop file so that Nautilus knows about feh.

Here's an example, which you could put in /usr/share/applications/feh.desktop. You'll want to edit it to specify an icon and to make sure that all the correct MIME types are listed (I just copied this from eog).

[Desktop Entry]
Name=feh
TryExec=feh
Exec=feh %U
Icon=eog
StartupNotify=true
Terminal=false
Type=Application
Categories=Graphics;RasterGraphics;Viewer;
MimeType=image/bmp;image/gif;image/jpeg;image/jpg;image/pjpeg;image/png;image/tiff;image/x-bmp;image/x-gray;image/x-icb;image/x-ico;image/x-png;image/x-portable-anymap;image/x-portable-bitmap;image/x-portable-graymap;image/x-portable-pixmap;image/x-xbitmap;image/x-xpixmap;image/x-pcx;image/svg+xml;image/svg+xml-compressed;image/vnd.wap.wbmp;

Then just run

# update-desktop-database

That did it! Thank you!

Offline

#5 2012-06-19 11:02:24

ijanos
Member
From: Budapest, Hungary
Registered: 2008-03-30
Posts: 443

Re: [Solved] Opening images on Nautilus

jakobcreutzfeldt wrote:

Here's an example, which you could put in /usr/share/applications/feh.desktop. You'll want to edit it to specify an icon and to make sure that all the correct MIME types are listed (I just copied this from eog).

put it in ~/.local/share/applications instead.

Offline

Board footer

Powered by FluxBB