2016-08-09 5 views
0

DevExpress의 설명서를 보았지만 범례의 상징을 변경하는 방법을 찾을 수 없었습니다.dxChart에서 범례 기호를 변경하는 방법

누구든지 나를 도와 줄 수 있습니까?

JS :

var dataSource = [{ 
    country: "USA", 
    hydro: 59.8, 
}, { 
    country: "China", 
    hydro: 74.2, 
}, { 
    country: "Russia", 
    hydro: 40, 
}, { 
    country: "Japan", 
    hydro: 22.6, 
}, { 
    country: "India", 
    hydro: 19, 
}, { 
    country: "Germany", 
    hydro: 6.1, 
}]; 

var chart = $("#chart").dxChart({ 
    dataSource: dataSource, 
    commonSeriesSettings: { 
     argumentField: "country", 
     type: 'line' 
    }, 
    margin: { 
     bottom: 20 
    }, 
    argumentAxis: { 
     valueMarginsEnabled: false, 
     discreteAxisDivisionMode: "crossLabels", 
     grid: { 
      visible: true 
     } 
    }, 
    series: [ 
     { valueField: "hydro", name: "Hydro-electric" } 
    ], 
    legend: { 
     verticalAlignment: "bottom", 
     horizontalAlignment: "center", 
     itemTextPosition: "bottom" 
    }, 
    title: { 
     text: "Energy Consumption in 2004", 
    } 
}) 

HTML :

<!DOCTYPE html> 
<html xmlns="http://www.w3.org/1999/xhtml"> 
<head> 
</head> 
<body class="dx-viewport"> 
    <div class="demo-container"> 
     <div id="chart-demo"> 
      <div id="chart"></div> 
     </div> 
    </div> 
</body> 
</html> 

출력 :

enter image description here

위 예제에서 범례 기호는 기본 "square"입니다. "square"에서 "cross"로 변경해야합니다.

답변

1

불행히도 dxChart에서 기본 범례 항목 기호를 변경할 방법이 없습니다.

관련 문제