fix:散点图X轴改为512

This commit is contained in:
xiaoguangbin 2024-07-10 16:10:04 +08:00
parent 421672dd1d
commit 78337da23b

View File

@ -100,7 +100,7 @@ const twoDOption = {
show: false,
},
min: 0,
max: 1024,
max: 512,
interval: 128,
},
yAxis: {
@ -435,7 +435,7 @@ export default {
let graphicHeight = this.$refs.TwoChartRef.clientHeight
graphic1.shape.height = graphicHeight
let minleft = this.myChart.convertToPixel({ xAxisId: '2' }, 0)
let maxRight = this.myChart.convertToPixel({ xAxisId: '2' }, 1024)
let maxRight = this.myChart.convertToPixel({ xAxisId: '2' }, 512)
graphic1.position = [
this.myChart.convertToPixel({ xAxisId: '2' }, minX),
this.myChart.convertToPixel({ yAxisId: '3' }, maxY),
@ -582,7 +582,7 @@ export default {
const [graphic1, graphic2] = this.dragOption.graphic
const { minX, maxX, minY, maxY, color } = this.boundaryData
this.twoDOption.xAxis.min = 0
this.twoDOption.xAxis.max = 1024
this.twoDOption.xAxis.max = 512
this.twoDOption.yAxis.min = 0
this.twoDOption.yAxis.max = 4096
@ -637,7 +637,7 @@ export default {
const [x1, y2, x2, y1] = [...point1, ...point2] //
const rangeNumberFuncX = rangeNumber(0, 1024)
const rangeNumberFuncX = rangeNumber(0, 512)
const rangeNumberFuncY = rangeNumber(0, 4096)
this.twoDOption.xAxis.min = rangeNumberFuncX(x1)