Gimp-Forum.net
Plug-in: plugin-heal-selection.py - Printable Version

+- Gimp-Forum.net (https://www.gimp-forum.net)
+-- Forum: GIMP (https://www.gimp-forum.net/Forum-GIMP)
+--- Forum: Gimp 2.10 (https://www.gimp-forum.net/Forum-Gimp-2-10)
+--- Thread: Plug-in: plugin-heal-selection.py (/Thread-Plug-in-plugin-heal-selection-py)



Plug-in: plugin-heal-selection.py - RStJohn - 07-29-2017

GIMP VER: 2.9.5 CCE
oP sys w10 64

When I run plugin-heal-selection.py, I get this:

GIMP-CCE Message

WARNING: Plug-In "plugin-heal-selection.py"
(C:\Users\Rich\AppData\Roaming\GIMP\2.9\plug-ins\plugin-heal-selection.py)
called deprecated procedure 'gimp-selection-combine'.
It should call 'gimp-image-select-item' instead!

This, I think, is the offending line: pdb.gimp_selection_combine(orgSelection, CHANNEL_OP_SUBTRACT)
It works, however, the above message box appears and the selection 'ants' remain (no big deal) in the image.

I've tried editing the script with the indicated fix but it fails when run. I am a complete novice with python. So if someone here can fix and update it you could be a hero. 
Any ideas?


RE: Plug-in: plugin-heal-selection.py - rich2005 - 07-29-2017

The attached is the one I fixed for my Gimp 2.9.5  
Guessing you are using Partha's Gimp 2.9.5 So just tried it in a Win VM. Seems to work ok

Remember to unzip it

note: I did try to change the Win shortcut to run in compatibility mode (--pdb-compat-mode=on) but Windows was having none of that. I wonder why? If you can that to work, you will not be troubled by those 'deprecated procedure' messages.

edit: Got it, the switch has to be outside of the quotes. Whoever in M$ decided spaces in file/folder names was a good idea should have been shot Smile

[attachment=650]


RE: Plug-in: plugin-heal-selection.py - RStJohn - 08-06-2017

Many thanks, truly appreciate you! It works fine.


RE: Plug-in: plugin-heal-selection.py - Ofnuts - 08-06-2017

Plenty of scripts will give "deprecated" messages with Gimp 2.9, because it's a "development" release. This doesn't make them buggy. If you make a private copy, it will "hide" the official copy and you may miss other more important fixes. I think you can squelch these messages with the proper parameter in your Gimp shortcut:


Code:
     --pdb-compat-mode {off|on|warn}
              If the PDB should provide aliases for deprecated functions.

In 2.9.5 you are likely to have "warn" by default, and you would just have to change this to "on".