mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-19 00:37:25 +01:00
[apps/reg] Calculation column size depends on regression type
This commit is contained in:
@@ -230,7 +230,17 @@ void CalculationController::willDisplayCellAtLocation(HighlightCell * cell, int
|
||||
}
|
||||
|
||||
KDCoordinate CalculationController::columnWidth(int i) {
|
||||
return i == 0 ? k_calculationTitleCellWidth : k_calculationCellWidth;
|
||||
if (i == 0) {
|
||||
return k_smallCalculationCellWidth;
|
||||
}
|
||||
Model::Type currentType = m_store->seriesRegressionType(m_store->indexOfKthNonEmptySeries(i-1));
|
||||
if (currentType == Model::Type::Quartic) {
|
||||
return k_quarticCalculationCellWidth;
|
||||
}
|
||||
if (currentType == Model::Type::Cubic) {
|
||||
return k_cubicCalculationCellWidth;
|
||||
}
|
||||
return k_smallCalculationCellWidth;
|
||||
}
|
||||
|
||||
KDCoordinate CalculationController::rowHeight(int j) {
|
||||
|
||||
@@ -64,8 +64,9 @@ private:
|
||||
static constexpr int k_regressionCellIndex = 9;
|
||||
|
||||
static constexpr KDCoordinate k_cellHeight = 25;
|
||||
static constexpr KDCoordinate k_calculationTitleCellWidth = Ion::Display::Width/2 - Metric::CommonRightMargin/2 - Metric::CommonLeftMargin/2;
|
||||
static constexpr KDCoordinate k_calculationCellWidth = 195;
|
||||
static constexpr KDCoordinate k_smallCalculationCellWidth = Ion::Display::Width/2 - Metric::CommonRightMargin/2 - Metric::CommonLeftMargin/2;
|
||||
static constexpr KDCoordinate k_cubicCalculationCellWidth = 150;
|
||||
static constexpr KDCoordinate k_quarticCalculationCellWidth = 195;
|
||||
static constexpr KDCoordinate k_margin = 8;
|
||||
static constexpr KDCoordinate k_r2CellMargin = 2;
|
||||
static constexpr KDCoordinate k_scrollBarMargin = Metric::CommonRightMargin;
|
||||
|
||||
Reference in New Issue
Block a user