You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@echarts.apache.org by GitBox <gi...@apache.org> on 2018/04/13 03:00:40 UTC

[GitHub] Leelily55 opened a new issue #8150: 绘制折线图出现异常情况

Leelily55 opened a new issue #8150: 绘制折线图出现异常情况
URL: https://github.com/apache/incubator-echarts/issues/8150
 
 
   <!--
   为了方便我们能够复现和修复 bug,请遵从下面的规范描述您的问题。
   -->
   
   
   ### One-line summary [问题简述]绘制折线图的时候,折线图的纵坐标和背景偶尔会出现如下情况:
   
   
   
   
   ### Version & Environment [版本及环境]
   + ECharts version [ECharts 版本]:  4.0.4
   + Browser version [浏览器类型和版本]: chrome最新版本 65.0.3325.181(正式版本) (32 位)
   + OS Version [操作系统类型和版本]: win7
   
   
   
   
   
   ### Expected behaviour [期望结果]
   ![image](https://user-images.githubusercontent.com/18433338/38714506-2d44b61e-3f09-11e8-9d63-b5a60ab7f181.png)
   
   
   
   
   
   ### ECharts option [ECharts配置项]
   <!-- Copy and paste your 'echarts option' here. -->
   <!-- [下方贴你的option,注意不要删掉下方 ```javascript 和 尾部的 ``` 字样。最好是我们能够直接运行的 option。如何得到能运行的 option 参见上方的 guidelines for contributing] -->
   ```javascript
   option = {
   legend: { //图例
                                               left:'right',
                                               data:['价格']
                                           },
                                           xAxis: [ //x坐标
                                               //                type: 'time',  //数据格式为时间
                                               {
                                                   type : 'category',
                                                   boundaryGap : true,
                                                   axisTick: {onGap:false},
                                                   splitLine: {show:false},
                                                   data : dateData
                                               }
                                           ],
                                           yAxis: [ //y坐标
                                               {
                                                   position:'left',
                                                   name : '(元/吨)',
                                                   min:function (value) {
                                                       return value.min - 1000
                                                   },
                                                   max:function (value) {
                                                       return value.max + 1000
                                                   },
                                                   interval:500
                                               },{
                                                   //                    gridIndex: 1,
                                                   splitNumber: 2,
                                                   axisLabel: {show: false},
                                                   axisLine: {show: false},
                                                   axisTick: {show: false},
                                                   splitLine: {show: false}
                                               }
   
                                           ],
                                           tooltip: { //提示框
                                               trigger: 'axis',
                                               axisPointer: {
                                                   type: 'cross'
                                               }
                                           },
                                           // toolbox: { //工具
                                           //     feature: {
                                           //         saveAsImage: {show: true}, //保存图片
                                           //         right:10
                                           //     }
                                           // },
                                           grid: [
                                               {
                                                   x: 80,
                                                   y:50,
                                                   x2:60,
                                                   y2:30
                                               }
                                           ],
                                           series: [{
                                               name: '价格',
                                               type: 'line',
                                               smooth: true,
                                               data: price
                                           }]
   
   }
   
   ```
   
   
   
   
   ### Other comments [其他信息]
   <!-- For example: Screenshot or Online demo -->
   <!-- [例如,截图或线上实例 (JSFiddle/JSBin/Codepen)] -->
   ![image](https://user-images.githubusercontent.com/18433338/38714463-f46ef2aa-3f08-11e8-8294-06ece97c7ab7.png)
   上图是不正常情况,请问有什么解决方法吗,感激不尽!!!!
   
   
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@echarts.apache.org
For additional commands, e-mail: dev-help@echarts.apache.org