[poincare] Clean: convertFloatToText should be in PrintFloat instead of

Complex
This commit is contained in:
Émilie Feral
2018-02-14 17:45:06 +01:00
committed by EmilieNumworks
parent d9150d4faa
commit 6de71ae145
118 changed files with 392 additions and 388 deletions

View File

@@ -154,9 +154,9 @@ void VariableBoxController::ContentViewController::willDisplayCellForIndex(Highl
const Matrix * matrixEvaluation = static_cast<const Matrix *>(evaluation);
myCell->setExpression(matrixEvaluation);
char buffer[2*PrintFloat::bufferSizeForFloatsWithPrecision(2)+1];
int numberOfChars = Complex<float>::convertFloatToText(matrixEvaluation->numberOfRows(), buffer, PrintFloat::bufferSizeForFloatsWithPrecision(2), 2, Expression::FloatDisplayMode::Decimal);
int numberOfChars = PrintFloat::convertFloatToText<float>(matrixEvaluation->numberOfRows(), buffer, PrintFloat::bufferSizeForFloatsWithPrecision(2), 2, PrintFloat::Mode::Decimal);
buffer[numberOfChars++] = 'x';
Complex<float>::convertFloatToText(matrixEvaluation->numberOfColumns(), buffer+numberOfChars, PrintFloat::bufferSizeForFloatsWithPrecision(2), 2, Expression::FloatDisplayMode::Decimal);
PrintFloat::convertFloatToText<float>(matrixEvaluation->numberOfColumns(), buffer+numberOfChars, PrintFloat::bufferSizeForFloatsWithPrecision(2), 2, PrintFloat::Mode::Decimal);
myCell->setSubtitle(buffer);
} else {
myCell->setExpression(nullptr);