Re: Improvement for measurement tool

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jul 6, 2009 at 5:19 PM, Sven Neumann<sven@xxxxxxxx> wrote:> Hi,>> On Mon, 2009-07-06 at 16:58 -0500, Chris Mohler wrote:>>> I had a little trouble finding docs on the named parameters (I ended>> up using help(gimpfu.register) in the console).  I've pasted the new>> register() below - one thing seemed strange: the 'params' parameter>> seems to require that I add the current image and drawable - is that>> correct?  Any other big mistakes here?  ;)>> Why does it require that? What's required is that you register all the> parameters that your function actually needs. If you need an image> parameter, then you should have PF_IMAGE in your input parameters. If> you also need a drawable, then this should be followed by PF_DRAWABLE.> But these are by no means obligatory. If you don't need an image nor a> drawable, then you can safely omit them.
Sorry - I did not phrase that very well.
When using the old, unnamed register() parameters, if you leave'params' empty, the main plug-in function still receives twoparameters - the current image and drawable.  Using the new, namedregister() parameters does not seem to do this anymore.
No big deal really, but I thought it odd that the behavior would be different.
Chris_______________________________________________Gimp-developer mailing listGimp-developer@xxxxxxxxxxxxxxxxxxxxxxxxxxx://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer

[Index of Archives]     [Video For Linux]     [Photo]     [Yosemite News]     [gtk]     [GIMP for Windows]     [KDE]     [GEGL]     [Gimp's Home]     [Gimp on GUI]     [Gimp on Windows]     [Steve's Art]

  Powered by Linux