It is currently Fri Jun 05, 2026 8:51 pm


All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 8 posts ] 
Author Message
 Post subject: Script-fu "procedures" list
PostPosted: Mon Mar 07, 2011 6:56 pm  (#1) 
Offline
GimpChat Member
User avatar

Joined: Oct 29, 2010
Posts: 711
Location: Netherlands
Hi all,
I'd like to try my hand at script writing in Gimp.
I am familiar with the console and the browser.
However I'd rather use a Scheme editor like "racket" which is based on DrScheme.
I've searched my whole install to find a list of the procedures that are shown when you open the browser.
I plan on putting this list in a text file and then copy/paste what I need in the racket editor.
They should be somewhere for the procedure browser.
Programming in an editor specially designed for scheme makes you more comfortable.
It has debug facilities for instance.
Anyone know where to look in a Linux install?
Gerard.

_________________
Gentoo Linux always up-to-date.
Kernel-3.17.4 Python-2.7.8/3.3.5
Gimp-2.8.14

I use Linux only.
And Virtualbox with Win 7


Share on Facebook Share on Twitter Share on Orkut Share on Digg Share on MySpace Share on Delicious Share on Technorati
Top
 Post subject: Re: Script-fu "procedures" list
PostPosted: Tue Mar 08, 2011 2:37 am  (#2) 
Offline
Script Coder
User avatar

Joined: Apr 23, 2010
Posts: 1553
Location: not from Guildford after all
(gimp-procedural-db-dump filename)

_________________
Any sufficiently primitive technology is indistinguishable from a rock.


Top
 Post subject: Re: Script-fu "procedures" list
PostPosted: Tue Mar 08, 2011 6:40 am  (#3) 
Offline
GimpChat Member
User avatar

Joined: Oct 29, 2010
Posts: 711
Location: Netherlands
Thanks saulgoode.
Looks like I have to make my first script to make this work.
Gerard.

_________________
Gentoo Linux always up-to-date.
Kernel-3.17.4 Python-2.7.8/3.3.5
Gimp-2.8.14

I use Linux only.
And Virtualbox with Win 7


Top
 Post subject: Re: Script-fu "procedures" list
PostPosted: Tue Mar 08, 2011 7:45 am  (#4) 
Offline
Script Coder
User avatar

Joined: Jun 22, 2010
Posts: 1171
Location: Here and there
gerard82 wrote:
Thanks saulgoode.
Looks like I have to make my first script to make this work.
Gerard.


Just type it into the Script-Fu console Filters > Script-Fu > Console

Welcome to TinyScheme
Copyright (c) Dimitrios Souflis
Script-Fu Console - Interactive Scheme Development

> (gimp-procedural-db-dump "gimp-pdb.txt")
(#t)


Then you only have to find where it put the file.

_________________
Kevin


Top
 Post subject: Re: Script-fu "procedures" list
PostPosted: Tue Mar 08, 2011 2:04 pm  (#5) 
Offline
GimpChat Member
User avatar

Joined: Oct 29, 2010
Posts: 711
Location: Netherlands
Hi paynekj,
Works like a charm.
The only drawback is it contains a lot more than just the procedures.
Anyway it got me something I can browse any time I want.
I used "find" to find the file.
Thanks.
Gerard.

_________________
Gentoo Linux always up-to-date.
Kernel-3.17.4 Python-2.7.8/3.3.5
Gimp-2.8.14

I use Linux only.
And Virtualbox with Win 7


Top
 Post subject: Re: Script-fu "procedures" list
PostPosted: Tue Mar 08, 2011 2:34 pm  (#6) 
Offline
Script Coder
User avatar

Joined: Apr 23, 2010
Posts: 1553
Location: not from Guildford after all
gerard82 wrote:
The only drawback is it contains a lot more than just the procedures.

If you just want the procedure names, execute the following expression in the console:
(let loop ((procs (cadr (gimp-procedural-db-query ".*" ".*" ".*" ".*"  ".*" ".*" ".*" )))
           (port (open-output-file "procedure-names.txt")) )
   (if (null? procs)
     (close-output-port port)
     (begin
       (display (car procs) port)
       (newline port)
       (loop (cdr procs) port) )))


gerard82 wrote:
I used "find" to find the file.

On GNU/Linux, the directory in which files are saved, unless you include the full path, will be the same as where GIMP is run from -- typically ~/ (i.e., $HOME/). This will be the same directory where images are saved when you first start GIMP, unless you navigate to another folder.

_________________
Any sufficiently primitive technology is indistinguishable from a rock.


Top
 Post subject: Re: Script-fu "procedures" list
PostPosted: Wed Mar 09, 2011 9:33 am  (#7) 
Offline
GimpChat Member
User avatar

Joined: Oct 29, 2010
Posts: 711
Location: Netherlands
Thanks saulgoode and paynejk!
Looking at your script saulgoode I'll have a lot to learn.
In the coming 2.8 a lot of procedures have changed wording.
This list will come in handy to change existing scripts by find/replace.
Gerard.

_________________
Gentoo Linux always up-to-date.
Kernel-3.17.4 Python-2.7.8/3.3.5
Gimp-2.8.14

I use Linux only.
And Virtualbox with Win 7


Top
 Post subject: Re: Script-fu "procedures" list
PostPosted: Wed Mar 09, 2011 10:33 am  (#8) 
Offline
GimpChat Member
User avatar

Joined: Jul 04, 2010
Posts: 2253
Location: Retired Moderator Slowly Returning to the Living.
Both of them worked beautifully! I have some nice info to look through!

Thanks much!

_________________
Artists aren't crazy! We're eccentric! ~G.M. Ross

Image

My Sigs = My Photos
Check out my work at http://www.flickr.com/photos/photomastergreg.


Top
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC - 5 hours [ DST ]


cron

* Login  



Powered by phpBB3 © phpBB Group