You are here

[SOLVED] Run Deskew plugin from Python-Fu console

I would like to run the (great!) Deskew plugin from the Python-Fu console.
The goal is to test it for an afterwards Python-Fu batch deskew plugin.

I'm a very GIMP Python-Fu beginner, so i followed what user "asperge" did in the post shown above (tested-working Script-Fu batch version):
1. get the image (active image)
2. get the drawable (active layer)
3. run plugin "deskew_plugin"

I put deskew.exe in the GIMP plugin folder, i opened GIMP, i loaded an image, then in the Python-Fu console i wrote:
pdb.gimp_deskew_plugin(image, drawable, 0, 0, 0, 0, 0)

The result is:
Traceback (most recent call last):
File "", line 1, in
RuntimeError: calling error

The working Script-Fu calling was:
(gimp-deskew-plugin 0 image drawable 0 0 0 0 0)

The only difference from the asperge's Script-Fu working version is that in my Phyton version there's no "0" before "image".
I guess it's the "run mode" parameter.
If i try to insert it, i have an error for too much parameters:
Traceback (most recent call last):
File "", line 1, in
TypeError: wrong number of parameters

Any idea?
(Windows 8 64 bit, GIMP 2.8.6)

SOLVED thanks to paynekj:


Subscribe to Comments for "[SOLVED] Run Deskew plugin from Python-Fu console"