On 1/18/07, Bart <bart@xxxxxxxxxxxx> wrote:
Maybe Script-fu has a similar capability, anyway this is natural to express in Python:
try:
floating = pdb.gimp_edit_paste(image.active_layer, False)
except RuntimeError:
# code that executes if gimp_edit_paste causes a runtime error goes here. I would expect this to just be the following:
return
Hi,
i'm developing a script that insert the clipboard as a layer (its based
on older existing scripts) and to avoid error messages to the user i'd
like to check up wether the clipboard is empty or not.
How to do that?
Maybe Script-fu has a similar capability, anyway this is natural to express in Python:
try:
floating = pdb.gimp_edit_paste(image.active_layer, False)
except RuntimeError:
# code that executes if gimp_edit_paste causes a runtime error goes here. I would expect this to just be the following:
return
_______________________________________________ Gimp-developer mailing list Gimp-developer@xxxxxxxxxxxxxxxxxxxxxx https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer