Skip to content

Commit f5c0d6d

Browse files
committed
fix: alawys use drawPath for now
1 parent 9ae2b61 commit f5c0d6d

File tree

1 file changed

+13
-8
lines changed

1 file changed

+13
-8
lines changed

src/charting/renderer/LineChartRenderer.ts

+13-8
Original file line numberDiff line numberDiff line change
@@ -448,19 +448,24 @@ export class LineChartRenderer extends LineRadarRenderer {
448448
// result = true;
449449
}
450450

451-
if (isAndroid || dataSet.isDashedLineEnabled()) {
452-
trans.pathValueToPixel(this.linePath);
453-
this.drawPath(c, this.linePath, this.mRenderPaint);
454-
} else {
455-
const points = res[0];
456-
const length = res[1];
457-
c.drawLines(points, 0, length, this.mRenderPaint, trans.getValueToPixelMatrix());
458-
}
451+
// if (isAndroid || dataSet.isDashedLineEnabled()) {
452+
trans.pathValueToPixel(this.linePath);
453+
this.drawPath(c, this.linePath, this.mRenderPaint);
454+
// } else {
455+
// const points = res[0];
456+
// const length = res[1];
457+
// this.drawLines(c, points, 0, length, this.mRenderPaint, trans.getValueToPixelMatrix());
458+
// }
459459

460460
return result;
461461
}
462462

463463
@profile
464+
drawLines(canvas: Canvas, points: number[], offest, length, paint: Paint, matrix: Matrix) {
465+
console.log('drawLines', points.length, length, typeof points, Array.isArray(points));
466+
canvas.drawLines(points, offest, length, paint, matrix);
467+
}
468+
464469
protected drawFill(c: Canvas, dataSet: ILineDataSet, spline: Path, trans: Transformer, bounds: XBounds) {
465470
const xKey = dataSet.xProperty;
466471
let fillMin = dataSet.getFillFormatter().getFillLinePosition(dataSet, this.mChart);

0 commit comments

Comments
 (0)