[poincare] change createLayout signature

- CreateLayout depends on the float display mode and the number of
significant digits
- Float display mode does not have a default value anymore
This commit is contained in:
Émilie Feral
2018-04-23 16:17:34 +02:00
parent d94ed82ab8
commit b8af15f1ab
116 changed files with 251 additions and 275 deletions

View File

@@ -1,4 +1,5 @@
#include "function.h"
#include "poincare_helpers.h"
#include <string.h>
#include <cmath>
#include <assert.h>
@@ -48,7 +49,7 @@ Poincare::ExpressionLayout * ExpressionModel::layout() {
if (m_layout == nullptr) {
Expression * nonSimplifiedExpression = Expression::parse(m_text);
if (nonSimplifiedExpression != nullptr) {
m_layout = nonSimplifiedExpression->createLayout(PrintFloat::Mode::Decimal);
m_layout = PoincareHelpers::CreateLayout(nonSimplifiedExpression);
delete nonSimplifiedExpression;
}
}