MCPcopy Create free account
hub / github.com/PlotJuggler/PlotJuggler / applyDots

Method applyDots

pj_app/src/MainWindow.cpp:2141–2153  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2139}
2140
2141void MainWindow::applyDots(PlotWidget* plot) {
2142 if (plot == nullptr) {
2143 return;
2144 }
2145 // The Dots toggle flips the plot-level style between Lines and Lines+Dots,
2146 // leaving other styles (Dots, Sticks, Steps) chosen in the Curve Style panel
2147 // alone. setDefaultStyle restyles every curve and is inherited by new ones.
2148 const auto from = dots_ ? PlotWidgetBase::kLines : PlotWidgetBase::kLinesAndDots;
2149 const auto to = dots_ ? PlotWidgetBase::kLinesAndDots : PlotWidgetBase::kLines;
2150 if (plot->defaultCurveStyle() == from) {
2151 plot->setDefaultStyle(to);
2152 }
2153}
2154
2155void MainWindow::onPlotZoomChanged(PlotWidget* modified, QRectF rect) {
2156 if (!button_link_->isChecked()) {

Callers

nothing calls this directly

Calls 2

defaultCurveStyleMethod · 0.80
setDefaultStyleMethod · 0.80

Tested by

no test coverage detected