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>
출력 :
위 예제에서 범례 기호는 기본 "square"입니다. "square"에서 "cross"로 변경해야합니다.