Page 1 of 1
xubuntu: 'Open with XnView MP'?
Posted: Sat Aug 04, 2012 1:00 pm
by Akovia
Hi,
I've searched the forums and tried some of the scripts offered, but none seem to work. I'm trying to use a custom action in thunar to be able to R-Click an image or directory and launch xnview from there with no success. It seems like vnviewmp doesn't accept any type of command line parameters so I'm kinda lost how to make a working script for this.
xubuntu 12.04
xnviewmp Version 0.51 (Jun 26 2012)
Re: 'Open with XnView MP' on xubuntu?
Posted: Tue Aug 07, 2012 12:12 pm
by xnview
you can start xnview like "xnview file.jpg"
Re: 'Open with XnView MP' on xubuntu?
Posted: Tue Aug 07, 2012 9:32 pm
by Akovia
Thanks for the reply. Unfortunately that isn't working for me. The window launches but is completely empty with only the title of the window listed.
ex..
Code: Select all
$xnviewmp picture.jpg
XNVIEW restoreGeometry before : 640 480
XNVIEW restoreGeometry after : 1680 1050
QMetaObject::invokeMethod: No such method MyTabBar::layoutTabs()
QSslSocket: cannot resolve SSLv2_client_method
QSslSocket: cannot resolve SSLv2_server_method
w.init
XNVIEW 1 ok
## XNVIEW RESIZE : 1680 1050
## MyTabWidget :: resizeEvent : 1680 1050
XNVIEW 2 ok
w.start
## MyTabWidget :: resizeEvent : 1680 981
## XNVIEW RESIZE : 1680 981
I've tried with both double and single quotes with the same result.
Re: 'Open with XnView MP' on xubuntu?
Posted: Wed Aug 08, 2012 4:28 am
by dvb
Have you installed from a .deb? My XUbuntu opens pictures from thunar quite ok. Thunar lists it in the "open with" programs. The only thing is, that at least x64 0.51 version from .deb can't open pictures with spaces in path.
Re: 'Open with XnView MP' on xubuntu?
Posted: Wed Aug 08, 2012 11:38 am
by Akovia
Have you installed from a .deb?
yes
My XUbuntu opens pictures from thunar quite ok. Thunar lists it in the "open with" programs.
It's not listed in my thunar as one of the default programs to open with, but I can scroll down and find it under "Open With Other Application". Unfortunately it's the same result.
The only thing is, that at least x64 0.51 version from .deb can't open pictures with spaces in path.
I'm using the x32 flavor. Are you saying that there is a version that can handle spaces?
Re: 'Open with XnView MP' on xubuntu?
Posted: Wed Aug 08, 2012 2:39 pm
by xnview
could you post the ocntent of xnview (shell script)
Re: 'Open with XnView MP' on xubuntu?
Posted: Wed Aug 08, 2012 9:48 pm
by Akovia
Hi,
I used the script from this thread.
http://newsgroup.xnview.com/viewtopic.php?f=62&t=18560
Code: Select all
#!/bin/sh
dirname=`dirname $0`
LD_LIBRARY_PATH=$dirname
export LD_LIBRARY_PATH
QT_PLUGIN_PATH=$dirname
export QT_PLUGIN_PATH
$dirname/xnview $@
I don't really understand it so it's hard for me to troubleshoot. So when it didn't work, I stopped trying.
You are correct that it will work on files without spaces, but that doesn't really help me as most of my pictures to have spaces in the filename. Quoting seems to be no help at all either.
Re: 'Open with XnView MP' on xubuntu?
Posted: Fri Aug 10, 2012 5:03 am
by dvb
Akovia wrote:It's not listed in my thunar as one of the default programs to open with, but I can scroll down and find it under "Open With Other Application". Unfortunately it's the same result.
Well, you can select it once there and make sure, that the "Use s default for this kind of file" checkbox at the bottom is checked. I did the same. And I didn't use any scripts, it was under "Open With Other Application" out of the box.
Akovia wrote:I'm using the x32 flavor. Are you saying that there is a version that can handle spaces?
Just checked x32 v0.51 .deb under Xubuntu 12.04 and Ubuntu 11.04 and it opens files with spaces in path.
Re: 'Open with XnView MP' on xubuntu?
Posted: Fri Aug 10, 2012 12:04 pm
by Akovia
Well I installed the deb from this site which is stated to be the same version. "Version 0.51 (Jun 26 2012)"
I thought it would state that the newest version was already installed, but it installed without protest. The only difference I could find between them is the command to launch them.
xnviewmp from repositories = xnviewmp
xnviewmp from deb on site = xnview
Launching $xnviewmp picture with spaces.jpg (fails)
Launching $xnview picture with spaces.jpg (works)
So it's working now but I have two of the exact same versions installed from different sources. Maybe that will help determine where the problem is. Either way I'm tickled now that I can use my custom action.
Well, you can select it once there and make sure, that the "Use s default for this kind of file" checkbox at the bottom is checked. I did the same. And I didn't use any scripts, it was under "Open With Other Application" out of the box.
I get that you can do this but I prefer to use feh or gthumb as my quickie viewer, which is why I keep a custom action for xnview and don't have to navigate any sub-menus to launch it.
Thank you for verifying it worked for you which led me to try the deb from the site. Much appreciated!
p.s. BTW, when you asked if I installed from .deb before I said yes as opposed to installing from source. I now realize that this software has no source offering. Sorry if my answer was misleading.
Re: 'Open with XnView MP' on xubuntu?
Posted: Fri Aug 10, 2012 12:33 pm
by Akovia
I looked in the ubuntu software center and checked the version there instead of from inside the program.
It's listed as.. "xnviewmp 0.51-1~getdeb1"
I had added the getdeb ppa for some other software a while back and didn't realize this is where xnviewmp was coming from in the software center. When I saw it in the software center with a few great reviews, I thought it was an official release. Maybe this info will help someone out in the future and be a warning to stick to the releases here until/if there is an official deb in the repositories.
Consider this thread Solved/Closed
Re: xubuntu: 'Open with XnView MP'?
Posted: Thu Aug 31, 2017 2:46 pm
by fixitmanarizona
I realize this is an old thread but searching for what I needed found it even though I'm on Xubuntu 16.04.
It may be helpful for other users on Xubuntu 16.04 (and above.)
YES you may create a custom action to open folders and/or files with XNview in Thunar!
My installed version of Xnview is 0.84 X32 (January 2017)
My installed version of Xubuntu is 16.04.3, Thunar version 1.6.11
It's quite simple using the graphic interface rather than a script/terminal.
Edit>configure custom actions
click the + (add)
popup will open
in basic view tab, type "open with XNview" (or whatever you prefer to see in your right click dialog)
Optionally type in a description.
in the line labeled "command" click the folder icon on the right. this should open usr/bin, and you can select the xnviewmp (in my case) executable. The line will now read: /usr/bin/xnviewmp %f
Do not check the use startup notification box.
Click the icon and search for Xnview, choose an icon (or choose any icon you prefer!)
In appearance conditions tab:
check only "directories" and "image files" .... you probably do not want folders with only text files, or files of only .txt or .doc or whatever, opening in Xnview...
click OK.
You may need to restart Thunar.
To remove, or edit the custom action, simply select Edit>configure custom actions again, and you can edit or remove it from there. A common mistake in Thunar is NOT selecting the proper appearance conditions (folders=directories, image files) in that tab, and editing makes it easy to change that without starting all over.
Now, when you right click on a folder, or on an image such as a .jpg, in Thunar, you can select your custom action.
Folders will open with XNview in the last folder view you selected.
Files will open in full screen (at least that's the way mine works) but you can just hit the escape button (or F11) on your keyboard, which will remove that full screen view and show Xnview opened to the folder the image is in. You can also right click and select full screen, which does the same thing.
This is probably configurable, however, I like the feature as-is and haven't tried to modify this behavior to open a picture in a tab, or in folder view.