(12-05-2023, 06:30 AM)Tas_mania Wrote: Quote:Enter a file path in the Location field
Why not just find the file by clicking and navigating the little file manager in the pop-up box?
Because I have a file with a couple thousand lines that contain file paths like this: Q:/photo/image-005.tif (produced by exiftool).
Changing the /'s to \'s gives gimp's Open Image dialog something it understands.
However, copying/pasting from my file into gimp's Open Image dialog is exhausting.
So I wrote an emacs tweak that sends the file path to gimp via the shell command "gimp -a".
Interestingly, if the starting file path is Q:\photo\2023-005.tif, emacs passes this to the command shell: "C:\Program Files\GIMP 2\bin\gimp-2.10.exe" -a Q:/photo/2023-005.tif
Emacs has replaced my file path's \'s with /'s, and gimp's command receiver accepts that.
I am indebted to the gimp programmers who gave gimp a command line receiver.
I am indebted to all the gimp programmers and documenters. Gimp is a work of genius.
My emacs tweak:
(defun rjd-rungimpatpoint ()
"Runs gimp -a on the filepath at point.
Blanks in the file name require quoting."
(interactive)
;Tested only on Windows 7 64 bit Gimp 2.10.36 Tue 12/05/2023
;Change the path to the gimp executable to your gimp's path. Alternatively, set a variable to the path.
;The \ are a concession to Windows.
;You might wish to use async-shell-command
(shell-command (concat "\"C:\\Program Files\\GIMP 2\\bin\\gimp-2.10.exe\" -a " (ffap-file-at-point) " &") nil nil)
)
(12-05-2023, 01:49 PM)PixLab Wrote: [quote pid='36891' dateline='1701767954']
I'm saying this because in 2009/10 (the year I ditched definitively Microsoft for vey-very good),
In 2015, my attempt to "upgrade" from Windows 7 to Windows 10 bricked my motherboard. I decided to fire Microsoft. I installed ubuntu, dual boot, but it is infuriating. E.g., displayed characters are too small. I get the impression that even in 2023, unix/linux is in the hands of children. But I'm still trying.
(Sorry to go off topic, but I haven't forgotten.)
[/quote]