2
AmChartsでAmchartグラフが生成されたときにデフォルトのズームを設定する方法があるかどうかを知りたい。ここでAmChartでデフォルトのズームを設定する
はコードです:
AmCharts.makeChart("chartdiv", {
type: "serial",
mouseWheelZoomEnabled: true,
fontFamily: "Montserrat",
path: "lib/amcharts/",
theme: "light",
fontSize: 12,
categoryField: "category",
precision: 0,
decimalSeparator: ",",
thousandsSeparator: ".",
plotAreaFillAlphas: 0.11,
plotAreaFillColors: "#61a1e6",
zoomOutButtonColor: "#D6E7F9",
sequencedAnimation: true,
startDuration: 1,
startEffect: "easeOutSine",
balloonText: "[[title]] [[category]]:[[value]]",
urlTarget: "#drill",
categoryAxis: {
autoRotateAngle: 0,
autoWrap: false,
gridPosition: "start",
axisAlpha: 0.16,
color: "#054bff",
gridAlpha: 0,
title: ""
},
chartScrollbar: {
"enabled": true
},
trendLines: [],
graphs: [
[LEGEND]
],
guides: [],
valueAxes: [{
[STACKED]
id: "ValueAxis-1",
axisAlpha: 0,
axisThickness: 0,
color: "#ff4444",
fillAlpha: 1,
gridAlpha: 0.17,
integersOnly: true,
title: ""
}],
allLabels: [],
balloon: {
fillAlpha: 0.95,
shadowAlpha: 0.11,
borderThickness: 5,
animationDuration: 2,
cornerRadius: 5
},
legend: {
markerBorderThickness: 4,
markerSize: 15,
markerType: "circle",
position: "right",
useGraphSettings: true,
valueText: ""
},
titles: [{
font: "Segoe UI",
bold: true,
color: "#17baef",
id: "Title-1",
size: 25,
text: "[TITLE]"
},
{
color: "#7adaf9",
id: "Title-2",
size: 15,
text: "[SUBTITLE1]"
},
{
color: "#7adaf9",
id: "Title-3",
size: 15,
text: "[SUBTITLE2]"
}
],
export: {
enabled: true,
}
})
はあなたの現在のAmChartコードを投稿することができますか?私はマップ上でデフォルトのズームを設定する方法を知っていますが、それが役に立つかどうかは分かりません。 – shaochuancs