Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/KDChart/Cartesian/KDChartCartesianAxis.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -861,6 +861,8 @@ void CartesianAxis::paintCtx(PaintContext *context)
break;
}

if (!qIsFinite(labelPos.x()) || !qIsFinite(labelPos.y()))
continue;
tickLabel->setGeometry(QRect(labelPos.toPoint(), size.toSize()));

if (step == Painting) {
Expand Down
2 changes: 2 additions & 0 deletions src/KDChart/ReverseMapper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,8 @@ void ReverseMapper::addLine(int row, int column, const QPointF &from, const QPoi
}
const QPointF lineVector(right - left);
const qreal lineVectorLength = sqrt(lineVector.x() * lineVector.x() + lineVector.y() * lineVector.y());
if (!qIsFinite(lineVectorLength) || qFuzzyIsNull(lineVectorLength))
return;
const QPointF lineVectorUnit(lineVector / lineVectorLength);
const QPointF normOfLineVectorUnit(-lineVectorUnit.y(), lineVectorUnit.x());
// now the four polygon end points:
Expand Down
Loading