| 392 | } |
| 393 | |
| 394 | void StatisticsColumnWidget::showBoxPlot() { |
| 395 | // add plot |
| 396 | auto* plot = addPlot(&m_boxPlotWidget); |
| 397 | |
| 398 | auto axes = plot->children<Axis>(); |
| 399 | for (auto* axis : std::as_const(axes)) { |
| 400 | if (axis->orientation() == Axis::Orientation::Horizontal) { |
| 401 | axis->setLabelsPosition(Axis::LabelsPosition::NoLabels); |
| 402 | axis->setMajorTicksDirection(Axis::noTicks); |
| 403 | axis->majorGridLine()->setStyle(Qt::NoPen); |
| 404 | axis->minorGridLine()->setStyle(Qt::NoPen); |
| 405 | axis->title()->setText(QString()); |
| 406 | } else |
| 407 | axis->title()->setText(m_column->name()); |
| 408 | |
| 409 | axis->setMinorTicksDirection(Axis::noTicks); |
| 410 | } |
| 411 | QApplication::processEvents(QEventLoop::AllEvents, 100); |
| 412 | |
| 413 | auto* boxPlot = new BoxPlot(QString()); |
| 414 | boxPlot->setOrientation(BoxPlot::Orientation::Vertical); |
| 415 | boxPlot->setWhiskersType(BoxPlot::WhiskersType::IQR); |
| 416 | boxPlot->setDataColumns({m_column}); |
| 417 | |
| 418 | // add the child to the parent _after_ the data column was set so the theme settings are properly applied in loadThemeConfig(). |
| 419 | plot->addChild(boxPlot); |
| 420 | |
| 421 | m_boxPlotInitialized = true; |
| 422 | } |
| 423 | |
| 424 | void StatisticsColumnWidget::showBarPlot() { |
| 425 | // add plot |
nothing calls this directly
no test coverage detected