| 1101 | } |
| 1102 | |
| 1103 | void PlotViewWidget::initViewFromModel() |
| 1104 | { |
| 1105 | if (this->viewInitializedForModel || !this->model) |
| 1106 | return; |
| 1107 | |
| 1108 | const auto range = this->model->getReasonabelRangeToShowOnXAxisPer100Pixels(); |
| 1109 | if (range) |
| 1110 | { |
| 1111 | this->zoomToPixelsPerValueX = 100.0 / double(*range); |
| 1112 | this->update(); |
| 1113 | } |
| 1114 | } |
no test coverage detected