Check documentation for the latest version of dhtmlxSuite fill DHTMLX Docs

fill

Fills the chart area with the specified background color.

Value type: string, function

Background color can be defined by:

  • some fixed value
var chart =  new dhtmlXChart({
        view:"radar",
    fill:"#66cc33",
        ...
})
  • a string template
var chart =  new dhtmlXChart({
        view:"radar",
    fill:"#color#",
        ...
})
  • a function that takes data object as an argument
var chart =  new dhtmlXChart({
        view:"radar",
    fill:function(obj){
        if (obj.sales > 5) return "#ff9900";
        else return "#66cc00";
    },
        ...
})
Back to top