Difference between revisions of "Pixel:setColor"
Line 2: | Line 2: | ||
'''Available since:''' Gideros 2016.06<br/> | '''Available since:''' Gideros 2016.06<br/> | ||
=== Description === | === Description === | ||
− | Sets the color of the Pixel | + | <translate>Sets the color of the Pixel</translate> |
<source lang="lua"> | <source lang="lua"> | ||
Pixel:setColor(color,alpha) | Pixel:setColor(color,alpha) | ||
</source> | </source> | ||
=== Parameters === | === Parameters === | ||
− | '''color''': (number) new color '''optional'''<br/> | + | '''color''': (number) <translate>new color</translate> '''optional'''<br/> |
− | '''alpha''': (number) New alpha value '''optional'''<br/> | + | '''alpha''': (number) <translate>New alpha value</translate> '''optional'''<br/> |
__NOTOC__ | __NOTOC__ | ||
'''Available since:''' Gideros 2011.6<br/> | '''Available since:''' Gideros 2011.6<br/> | ||
=== Description === | === Description === | ||
− | Sets two-colour gradient fill with optional rotation to Pixel. | + | <translate>Sets two-colour gradient fill with optional rotation to Pixel.</translate> |
<source lang="lua"> | <source lang="lua"> | ||
Pixel:setColor(color1,alpha1,color2,alpha2,angle) | Pixel:setColor(color1,alpha1,color2,alpha2,angle) | ||
</source> | </source> | ||
=== Parameters === | === Parameters === | ||
− | '''color1''': (number) First color of the gradient. <br/> | + | '''color1''': (number) <translate>First color of the gradient.</translate> <br/> |
− | '''alpha1''': (number) First alpha of the gradient. <br/> | + | '''alpha1''': (number) <translate>First alpha of the gradient.</translate> <br/> |
− | '''color2''': (number) Second color of the gradient. <br/> | + | '''color2''': (number) <translate>Second color of the gradient.</translate> <br/> |
− | '''alpha2''': (number) Second alpha of the gradient. <br/> | + | '''alpha2''': (number) <translate>Second alpha of the gradient.</translate> <br/> |
− | '''angle''': (number) Sets rotation of the gradient in degrees. Default value is 270: top-bottom gradient. '''optional'''<br/> | + | '''angle''': (number) <translate>Sets rotation of the gradient in degrees. Default value is 270: top-bottom gradient.</translate> '''optional'''<br/> |
__NOTOC__ | __NOTOC__ | ||
'''Available since:''' Gideros 2011.6<br/> | '''Available since:''' Gideros 2011.6<br/> | ||
=== Description === | === Description === | ||
− | Sets 4-colour gradient fill to Pixel. | + | <translate>Sets 4-colour gradient fill to Pixel.</translate> |
<source lang="lua"> | <source lang="lua"> | ||
Pixel:setColor(color1,alpha1,color2,alpha2,color3,alpha3,color4,alpha4) | Pixel:setColor(color1,alpha1,color2,alpha2,color3,alpha3,color4,alpha4) | ||
</source> | </source> | ||
=== Parameters === | === Parameters === | ||
− | '''color1''': (number) Color of top-left gradient corner. <br/> | + | '''color1''': (number) <translate>Color of top-left gradient corner.</translate> <br/> |
− | '''alpha1''': (number) Alpha of top-left gradient corner. <br/> | + | '''alpha1''': (number) <translate>Alpha of top-left gradient corner.</translate> <br/> |
− | '''color2''': (number) Color of top-right gradient corner. <br/> | + | '''color2''': (number) <translate>Color of top-right gradient corner.</translate> <br/> |
− | '''alpha2''': (number) Alpha of top-right gradient corner. <br/> | + | '''alpha2''': (number) <translate>Alpha of top-right gradient corner.</translate> <br/> |
− | '''color3''': (number) Color of bottom-right gradient corner. <br/> | + | '''color3''': (number) <translate>Color of bottom-right gradient corner.</translate> <br/> |
− | '''alpha3''': (number) Alpha of bottom-right gradient corner. <br/> | + | '''alpha3''': (number) <translate>Alpha of bottom-right gradient corner.</translate> <br/> |
− | '''color4''': (number) Color of bottom-left gradient corner. <br/> | + | '''color4''': (number) <translate>Color of bottom-left gradient corner.</translate> <br/> |
− | '''alpha4''': (number) Alpha of bottom-left gradient corner. <br/> | + | '''alpha4''': (number) <translate>Alpha of bottom-left gradient corner.</translate> <br/> |
Revision as of 13:34, 23 August 2018
Available since: Gideros 2016.06
Description
Sets the color of the Pixel
Pixel:setColor(color,alpha)
Parameters
color: (number) new color optional
alpha: (number) New alpha value optional
Available since: Gideros 2011.6
Description
Sets two-colour gradient fill with optional rotation to Pixel.
Pixel:setColor(color1,alpha1,color2,alpha2,angle)
Parameters
color1: (number) First color of the gradient.
alpha1: (number) First alpha of the gradient.
color2: (number) Second color of the gradient.
alpha2: (number) Second alpha of the gradient.
angle: (number) Sets rotation of the gradient in degrees. Default value is 270: top-bottom gradient. optional
Available since: Gideros 2011.6
Description
Sets 4-colour gradient fill to Pixel.
Pixel:setColor(color1,alpha1,color2,alpha2,color3,alpha3,color4,alpha4)
Parameters
color1: (number) Color of top-left gradient corner.
alpha1: (number) Alpha of top-left gradient corner.
color2: (number) Color of top-right gradient corner.
alpha2: (number) Alpha of top-right gradient corner.
color3: (number) Color of bottom-right gradient corner.
alpha3: (number) Alpha of bottom-right gradient corner.
color4: (number) Color of bottom-left gradient corner.
alpha4: (number) Alpha of bottom-left gradient corner.