Javascript examples for highcharts:Pie Chart
Datalabels text overflow from plot area in pie chart
<html> <head> <title>Highcharts Demo</title> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> #container {/*from w ww .java2s. c o m*/ border: 1px solid black; } </style> </head> <body> <script src="https://code.highcharts.com/highcharts.js"></script> <script src="https://code.highcharts.com/modules/exporting.js"></script> <div id="container"></div> <script type="text/javascript"> Highcharts.chart('container', { chart: { type: 'pie', height: 218, width: 607, }, plotOptions: { pie: { dataLabels: { //useHTML: true, //crop: true, //overflow: 'none', enabled: true, format: '<b>{point.name}</b>: {point.percentage:.1f} %' } } }, series: [{ //size: '100%', innerSize: '60%', name: 'Brands', colorByPoint: true, data: [{ name: 'Chrome<br> some text ', y: 61.41, sliced: true, selected: true }, { name: 'Internet <br>Explorer <br> some text', y: 11.84 }, { name: 'Firefox', y: 10.85 }, { name: 'Edge', y: 4.67 }, { name: 'Safari', y: 4.18 }, { name: 'Sogou Explorer', y: 1.64 }, { name: 'Opera', y: 1.6 }, { name: 'QQ', y: 1.2 }, { name: 'Other', y: 2.61 }] }] }); </script> </body> </html>