Do it with the GIMPScripting the GIMPScript-Fu ScriptingInteractive Demo

8.2.1. Interactive Demo

Demo

  1. Invoke the console by selecting: <Toolbox> Xtns Script-Fu Console .
  2. Close all the images.
  3. Create a new image with the background as its filling.
  4. At the command prompt of the console, type (gimp-image-list) and press enter.
  5. Record the index of the image. (it's inside the inner parenthesis)
  6. Type (gimp-image-get-active-drawable $image) and record the drawable number. (In the GIMP internals, a drawable is a base class for layers and such)
  7. Type (gimp-rect-select $image 10 10 50 80 ADD 0 0) and press enter.
  8. Type (gimp-rect-select $image 40 70 50 80 ADD 0 0) and press enter.
  9. Type (gimp-edit-bucket-fill $drawable FG-BUCKET-FILL NORMAL 100 0 0 0 0) and press enter.
  10. Note: Consult the DB browser for information regarding what every function and parameter here do.

Written by Shlomi Fish