Hans Nowak wrote:
> You don't have to use fillColor[0], you can use tuple unpacking to name
> the elements of the tuple. E.g.
>
> def renderABezierPath(self, path, closePath=True, outlineColor=(1.0,
> 1.0, 1.0, 1.0), fillColor=(0.0, 0.0, 0.0, 0.25)):
> r, g, b, a = outlineColor
> fr, fg
KraftDiner wrote:
> I guess its all good...
> I just am not crazy about using fillColor[0] id rather use fillColor.r
> So is that a structure I need to define or a class...
> I'm kind of new to python what would that class or structure look like?
> and then do the default parameters still work?
T
NICE! :)
--
http://mail.python.org/mailman/listinfo/python-list
KraftDiner wrote:
> I guess its all good...
> I just am not crazy about using fillColor[0] id rather use fillColor.r
You don't have to use fillColor[0], you can use tuple unpacking to name
the elements of the tuple. E.g.
def renderABezierPath(self, path, closePath=True, outlineColor=(1.0,
1.0
I guess its all good...
I just am not crazy about using fillColor[0] id rather use fillColor.r
So is that a structure I need to define or a class...
I'm kind of new to python what would that class or structure look like?
and then do the default parameters still work?
--
http://mail.python.org/ma
KraftDiner wrote:
> I have defined a method as follows:
>
> def renderABezierPath(self, path, closePath=True, r=1.0, g=1.0, b=1.0,
> a=1.0, fr=0.0, fg=0.0, fb=0.0, fa=.25):
>
> Now wouldn't it be simpler if it was:
>
> def renderABezierPath(self, path, closePath=True, outlineColor,
> fillColor):
Il 2005-12-28, KraftDiner <[EMAIL PROTECTED]> ha scritto:
> I have defined a method as follows:
>
> def renderABezierPath(self, path, closePath=True, r=1.0, g=1.0, b=1.0,
> a=1.0, fr=0.0, fg=0.0, fb=0.0, fa=.25):
>
> Now wouldn't it be simpler if it was:
>
> def renderABezierPath(self, path, closeP
On 28 Dec 2005 12:37:32 -0800, KraftDiner <[EMAIL PROTECTED]> wrote:
>I have defined a method as follows:
>
>def renderABezierPath(self, path, closePath=True, r=1.0, g=1.0, b=1.0,
>a=1.0, fr=0.0, fg=0.0, fb=0.0, fa=.25):
>
>Now wouldn't it be simpler if it was:
>
>def renderABezierPath(self, path,
I have defined a method as follows:
def renderABezierPath(self, path, closePath=True, r=1.0, g=1.0, b=1.0,
a=1.0, fr=0.0, fg=0.0, fb=0.0, fa=.25):
Now wouldn't it be simpler if it was:
def renderABezierPath(self, path, closePath=True, outlineColor,
fillColor):
But how do you set default vaules