GIMP Chat http://gimpchat.com/ |
|
script to load text file and create text layer http://gimpchat.com/viewtopic.php?f=9&t=19239 |
Page 1 of 1 |
Author: | bjlockie [ Thu Mar 18, 2021 4:04 pm ] |
Post subject: | script to load text file and create text layer |
I wrote this script and when I click on the font button I get the error dialog. Code: Select all (define (script-fu-text-box inText inFont inFontSize inTextColor)) I have a bunch of jpg picture files that have corresponding text files (same name but .txt instead of .jpg). I want the script to load the text of the corresponding text file. I'm hoping I can get the full path of the loaded jpg and replace .jpg with .txt and then load the text and create a text layer. I have hundreds of images with corresponding text files so I'm hoping I can run this from the command line. If someone wants give me a head start then that would be great. :-) |
Author: | Pocholo [ Fri Mar 19, 2021 1:08 am ] |
Post subject: | Re: script to load text file and create text layer |
It's been a long time since I work in scheming. I think you should learn python, is much easier that scheme. You should start here: Video from : www.youtube.com |
Author: | bjlockie [ Fri Mar 19, 2021 7:28 pm ] |
Post subject: | Re: script to load text file and create text layer |
thanks. |
Author: | ofnuts [ Sat Mar 20, 2021 5:38 am ] |
Post subject: | Re: script to load text file and create text layer |
bjlockie wrote: I wrote this script and when I click on the font button I get the error dialog. Code: Select all (define (script-fu-text-box inText inFont inFontSize inTextColor)) [ Image ] I have a bunch of jpg picture files that have corresponding text files (same name but .txt instead of .jpg). I want the script to load the text of the corresponding text file. I'm hoping I can get the full path of the loaded jpg and replace .jpg with .txt and then load the text and create a text layer. I have hundreds of images with corresponding text files so I'm hoping I can run this from the command line. If someone wants give me a head start then that would be great. :-) This would be a lot easier with ImageMagick and a shell script: https://legacy.imagemagick.org/Usage/annotating/ If you stick to Gimp, for a batch your don't need to register the script: https://stackoverflow.com/questions/444 ... 0#44435560 |
Author: | bjlockie [ Thu Apr 15, 2021 6:53 pm ] |
Post subject: | Re: script to load text file and create text layer |
The problem with ImageMagick is that won't save the text as a layer. I may use that though. |
Author: | Pocholo [ Thu Apr 15, 2021 10:26 pm ] |
Post subject: | Re: script to load text file and create text layer |
Where did you place the script? The script have to be install in: C:\Users\YourName\AppData\Roaming\GIMP\2.10\scripts |
Author: | paynekj [ Fri Apr 16, 2021 6:14 am ] |
Post subject: | Re: script to load text file and create text layer |
@bjlockie The error you are seeing was a bug in GIMP: https://gitlab.gnome.org/GNOME/gimp/-/issues/4641 which was fixed at GIMP 2.10.20 so I thing you need to update your version of GIMP to the latest: 2.10.24 |
Page 1 of 1 | All times are UTC - 5 hours [ DST ] |
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group http://www.phpbb.com/ |