|
christinFeb 7, 2023 via iPhone
1
在最外层指定字号大小
|
|
kaifeijiFeb 7, 2023
2
toolbox.feature.saveAsImage.pixelRatio
|
|
3
渲染方式使用 svg (放大不会糊),外面的容器 css 添加 transform: scale(4);
示例代码: this.lineChart = echarts.init(this.$refs.phoneChart, null, { renderer: 'svg' }) |
|
liyang5945Feb 7, 2023
4
刚试了一下这种方式也可以,画出来后直接在 canvas 右键另存图片就行
this.lineChart = echarts.init(this.$refs.phoneChart, null, { renderer: 'canvas', devicePixelRatio:4 }) |
|
5
@liyang5945 #3 非常感谢,改成 svg 后解决了。🙌
|
|
6
@liyang5945 #4 修改 devicePixelRatio 参数更简单,牛逼
|
|
mynameislihuaFeb 8, 2023
7
学到了
|