Functiondojo.blendColors

<script src="../../js/dojo.js"></script>
defined in dojo/_base/Color.js

blend colors end and start with weight from 0 to 1, 0.5 being a 50/50 blend, can reuse a previously allocated dojo.Color object for the result

Usage

function (/*dojo.Color*/ start, /*dojo.Color*/ end, /*Number*/ weight, /*dojo.Color?*/ obj) (view source)
parametertypedescription
startdojo.Colortakes a named string, hex string, array of rgb or rgba values, an object with r, g, b, and a properties, or another dojo.Color object
fieldtypedescription
.r 
.sanitizeFunctionmakes sure that the object has correct attributes
.setColorFunctiontakes a named string, hex string, array of rgb or rgba values, an object with r, g, b, and a properties, or another dojo.Color object
.toCssFunctionreturns a css color string in rgb(a) representation
.toHexFunctionreturns a css color string in hexadecimal representation
.toRgbFunctionreturns 3 component array of rgb values
.toRgbaFunctionreturns a 4 component array of rgba values
.toStringFunctionreturns a visual representation of the color
._setFunction 
enddojo.Colortakes a named string, hex string, array of rgb or rgba values, an object with r, g, b, and a properties, or another dojo.Color object
fieldtypedescription
.r 
.sanitizeFunctionmakes sure that the object has correct attributes
.setColorFunctiontakes a named string, hex string, array of rgb or rgba values, an object with r, g, b, and a properties, or another dojo.Color object
.toCssFunctionreturns a css color string in rgb(a) representation
.toHexFunctionreturns a css color string in hexadecimal representation
.toRgbFunctionreturns 3 component array of rgb values
.toRgbaFunctionreturns a 4 component array of rgba values
.toStringFunctionreturns a visual representation of the color
._setFunction 
weightNumber 
objdojo.ColorOptional. takes a named string, hex string, array of rgb or rgba values, an object with r, g, b, and a properties, or another dojo.Color object
fieldtypedescription
.r 
.sanitizeFunctionmakes sure that the object has correct attributes
.setColorFunctiontakes a named string, hex string, array of rgb or rgba values, an object with r, g, b, and a properties, or another dojo.Color object
.toCssFunctionreturns a css color string in rgb(a) representation
.toHexFunctionreturns a css color string in hexadecimal representation
.toRgbFunctionreturns 3 component array of rgb values
.toRgbaFunctionreturns a 4 component array of rgba values
.toStringFunctionreturns a visual representation of the color
._setFunction