[Feature] Get the height and width of the rectangle when using series->type:treemap->label:formatter function
What problem does this feature solve?
import * as echarts from 'echarts' chart = proxy.$echarts.init(document.getElementById('myEcharts'),
2: treemap
3: chart.setOption->label->formatter:params
Can't get the height and width of the rectangle when using series->type:treemap->label:formatter function
What does the proposed API look like?
Get the height and width of the rectangle when using series->type:treemap->label:formatter function
I'm afraid you can't have this information. What kind of effect do you want to make?
I'm afraid you can't have this information. What kind of effect do you want to make?
@Ovilia thank you for your reply.
In label:formatter function, I want to figure out how many text rows to show out by the width and height of the rectangle.
and I fount that the order of label:formatter is ahead of labelLayout function(labelLayout can get the width and height of the rectangle).
I’m sorry, but unfortunately, that’s not possible with Apache ECharts.
I’m sorry, but unfortunately, that’s not possible with Apache ECharts.
@Ovilia OK,I see.
May I ask the reason why developer who use Treemap cannot control the number of lines in the label:formatter? or any other way you recommend so we can get that effect?
and we see it's easy to return the width&height data by looking at the source code.