> Message: 6 > Date: Sat, 13 Dec 2008 13:58:16 -0500 > From: Kevin Cozens <ke...@ve3syb.ca> > Subject: Re: [Gimp-user] Error while executing script > (Script Stop > Working in Windows 2.6.3) > To: gimp-user <gimp-user@lists.xcf.berkeley.edu> > Message-ID: <494405c8.9040...@ve3syb.ca> > Content-Type: text/plain; charset=us-ascii; format=flowed > > D.Jones (aka) Capnhud wrote: > > (colors (+ segments (if (= inSmooth TRUE) 1 0))) > [snip] > > (while (< counter segments) > > (gimp-gradient-segment-set-left-color theGradient > counter (car (gimp-image-pick-color img inLayer counter 0 > FALSE FALSE 0)) 100) > > (gimp-gradient-segment-set-right-color > theGradient counter (car (gimp-image-pick-color img inLayer > (+ counter (if (= inSmooth TRUE) 1 0)) 0 FALSE FALSE 0)) > 100) > > (set! counter (+ counter 1)) > > ) > [snip] > > what is the correct type for argument 3? > > The procedure database indicates that a FLOAT (ie. a > numerical value) is > expected for argument 3 of gimp-image-pick-color. Your > problem is due to > invalid use of the "=" operator in the two if > statements shown above. > > Your code has "(if (= inSmooth TRUE) 1 0)" where > in Smooth is a boolean value > provided by the SF-TOGGLE. The "=" operator is > for use when comparing numbers, > not booleans. Since inSmooth is a boolean, change your if > statement to read > (if inSmooth 1 0) > > -- > Cheers! > > Kevin.
Thanks for clarifying what the problem was. Those changes caused the script to function properly again. What I do not understand is why I was the only one that seem to have this problems while others indicated that the script without the changes worked just fine. Go figure:) _______________________________________________ Gimp-user mailing list Gimp-user@lists.XCF.Berkeley.EDU https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-user