Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
xnviewmp open with gimp error message
#4
(04-06-2025, 09:34 PM)zugzwang134 Wrote: Ofnuts

Thanks for the reply.  xnviewmp must be passing gimp the name of the image file, because the image file is being opened.  Assuming that  xnviewmp is calling xdg-open, why is it, that after gimp successfully opens the image file,  gimp immediately tries to open /home/steve/ ?  It is as if gimp does not play well with xdg-open.  I still wonder if there is a relevant setting in gimp, to handle this.

When I configure xnviewmp to open with a *.sh file instead, nothing happens.  This seems consistent with your idea that xnviewmp is calling xdg-open.  So, it there is no joy fixing the problem on the gimp side, it seems as if I am going to have to write some sort of  app (perhaps in java, if bash can't do it) that can catch the "app-open" event, and can also catch the name of the file being opened.  Hypothetically, the intermediate app would then call gimp, passing gimp the file name.

I suspect, without knowing for sure, that a java app (for example) can catch the app-startup event.  Further, I have just verified that in a bash terminal, the gimp-2.10 /my-path/myfile command works ok.  So, the missing piece, which may be impossible to remedy, would be for the java app (et al) to catch the file-name parameter being sent by the xdg-open command.

If catching the file name is not directly feasible, the problem may still be solvable.  That is, the java app, could be written to open the file, and then the app could interrogate the name of the file it has just opened.

I am a retired programmer with an amateurish knowledge of batch java.  I have no idea if any of this is feasible, or what the cleanest solution would be, if there is no joy to be found on the gimp side.

I welcome anyone's ideas about either a gimp setting, a separate opinion on whether xdg-open is involved, or how to write the java app (or app in any other language) that would catch the app-startup-event, and also (somehow) determine the name of the file being sent by xdg-open.

You can have xnviewmp use about anything to open the file (including just a bash script) so can log somewhere what is received by the application asked to open the file. But IMHO this is likely just a configuration problem, because is it likely working for thousands of people (otherwise you wouldn't be the first to ask here).
Reply


Messages In This Thread
RE: xnviewmp open with gimp error message - by Ofnuts - 04-06-2025, 10:06 PM

Forum Jump: