MCPcopy Create free account
hub / github.com/KDE/labplot / niceExtendChanged

Method niceExtendChanged

src/backend/worksheet/plots/cartesian/CartesianPlot.cpp:3604–3620  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3602}
3603
3604void CartesianPlotPrivate::niceExtendChanged() {
3605 DEBUG(Q_FUNC_INFO)
3606 for (const auto* cSystem : q->m_coordinateSystems) {
3607 const auto cs = static_cast<const CartesianCoordinateSystem*>(cSystem);
3608 int xIndex = cs->index(Dimension::X);
3609 int yIndex = cs->index(Dimension::Y);
3610 xRanges[xIndex].dirty = true;
3611 yRanges[yIndex].dirty = true;
3612 if (autoScale(Dimension::X, xIndex) && autoScale(Dimension::Y, yIndex))
3613 q->scaleAuto(xIndex, yIndex);
3614 else if (autoScale(Dimension::X, xIndex))
3615 q->scaleAuto(Dimension::X, xIndex, false);
3616 else if (autoScale(Dimension::Y, yIndex))
3617 q->scaleAuto(Dimension::Y, yIndex, false);
3618 }
3619 q->WorksheetElementContainer::retransform();
3620}
3621
3622void CartesianPlotPrivate::rangeFormatChanged(const Dimension dim) {
3623 DEBUG(Q_FUNC_INFO)

Callers

nothing calls this directly

Calls 2

scaleAutoMethod · 0.80
indexMethod · 0.45

Tested by

no test coverage detected