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 2020/09/22 01:53:21 UTC

[GitHub] [incubator-echarts] susiwen8 commented on a change in pull request #13210: Feat: multiple value axis alignment

susiwen8 commented on a change in pull request #13210:
URL: https://github.com/apache/incubator-echarts/pull/13210#discussion_r492436816



##########
File path: src/component/axis/AxisBuilder.ts
##########
@@ -372,7 +372,7 @@ const builders: Record<'axisLine' | 'axisTickLabel' | 'axisName', AxisElementsBu
         const textStyleModel = axisModel.getModel('nameTextStyle');
         const gap = axisModel.get('nameGap') || 0;
 
-        const extent = axisModel.axis.getExtent();
+        const extent = axisModel.axis.getGridExtent();
         const gapSignal = extent[0] > extent[1] ? -1 : 1;

Review comment:
       Sorry for this late reply
   The reason why `splitline` of two axis cannot align in most case, it's because axis will fill the `grid`[code](https://github.com/apache/incubator-echarts/blob/next/src/coord/cartesian/Grid.ts#L166).  `axis` will be split evenly by using `grid extent`. What I trying to do is calculate the `proportion` of axis in this grid, each axis has same standard which is `unionExtent`.   




----------------------------------------------------------------
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.

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