buttons (exporting properties)

exporting에 사용할 메뉴를 설정 합니다.

Info

name type required(default) description
contextButtons object 선택 메뉴 항목 설정

contextButtons Info

name type required(default) description
className string 선택('ibcharts-contextbutton') 버튼 클래스
menuClassName string 선택('ibcharts-contextmenu') 메뉴 클래스
menuItems array 선택([printChart, separator, downloadJPEG, downloadPDF, downloadSVG]) 메뉴 아이템 설정

menuItems Info

name type required(default) description
text string 선택 아이템에 표시할 문구
textKey string 선택 Lang 파일에서 참조한 텍스트
onclick function 선택 클릭 시 동작

Example

myChart.setOptions({
  exporting: {
    enabled: true,
    url: '../../assets/ibchart/Down2Image.jsp', // jsp 경로
    buttons: {
      contextButton: {
        menuItems: [ // default: [printChart, separator, downloadJPEG, downloadPDF, downloadSVG]
          {
            text: '차트 사이즈 축소',
            // textKey: "차트 사이즈 축소", // text와 동시에 설정 시 text로 표시
            onclick: function (e) {
                myChart.setSize(500, 300);
            }
          },
          "printChart", // defaut로 설정되어 있는 항목을 string으로 설정 시 사용 가능
          "separator",  // 구분선
          "downloadJPEG"
        ]
      }
    }
  },
})

제공 버전

version desc
7.3.1.26 기능 추가