You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by GitBox <gi...@apache.org> on 2022/11/06 08:54:39 UTC
[GitHub] [echarts] plainheart commented on issue #17874: Allow percentages in label width parameter
plainheart commented on issue #17874:
URL: https://github.com/apache/echarts/issues/17874#issuecomment-1304750075
Maybe you can try to use the [`labelLayout`](https://echarts.apache.org/option.html#series-bar.labelLayout) callback function to get the chart width and use it to calculate the position of the label.
Like this,
```js
labelLayout(params) {
// get chart width
const chartWidth = myChart.getWidth();
// ...
return {
// ...
}
}
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org