Ruben Dashyan
95c7235831
[poincare] Align implementation of shallowReduce in Symbol and Function
2020-02-12 15:13:16 +01:00
Ruben Dashyan
70c9d063a2
[poincare/symbol] Use replaceWithInPlace in shallowReduce
2020-02-12 15:13:16 +01:00
Ruben Dashyan
686b74cfe4
[poincare/constant] Remove unused parameters from templatedApproximate
2020-02-12 15:13:16 +01:00
Ruben Dashyan
961a0f5f2b
[poincare/constant] Simplify shallowReduce
2020-02-12 15:13:16 +01:00
Ruben Dashyan
c238c5f736
[poincare/symbol_abstract] Remove unnecessary friend class Store
2020-02-12 15:13:16 +01:00
Ruben Dashyan
f0bfb41cab
[poincare/symbol_abstract] Factor serialize
2020-02-12 15:13:16 +01:00
Ruben Dashyan
87c1f4f39c
[poincare] Remove redundancy
...
TreeNode::serialize(char * buffer, int bufferSize, ...) returns
the number of chars it did write in buffer, null-terminating char
excluded.
strlcpy(char * dst, const char * src, size_t len) returns the length of
src.
Hence the min.
The case where bufferSize equals 0 does not need to be handled separately
since it is already contained in the min.
2020-02-12 15:13:16 +01:00
Ruben Dashyan
e4820a52f7
[poincare/symbol_abstract] Make nodeSize private
2020-02-12 15:13:16 +01:00
Ruben Dashyan
4bdc2043c8
[poincare/power] coding style in denominator
2020-02-12 15:13:16 +01:00
Ruben Dashyan
1556e2daad
[poincare/power] Simplify denominator
2020-02-12 15:13:16 +01:00
Ruben Dashyan
55e01fbfd4
[poincare/parser] Remove currentTokenIsReservedFunction and currentTokenIsSpecialIdentifier
...
Use GetReservedFunction and IsSpecialIdentifierName instead.
2020-02-12 15:13:16 +01:00
Ruben Dashyan
9a3e0e9bd3
[poincare/parser] Simplify GetReservedFunction
2020-02-12 15:13:16 +01:00
Ruben Dashyan
4ef46b4fdb
[poincare/parser] IsReservedFunctionName returns a pointer
...
and is hence renamed GetReservedFunction
2020-02-12 15:13:16 +01:00
Ruben Dashyan
967343f75d
[poincare/parser] Remove IsReservedName unused parameter
...
The function is only called in apps/shared/function.
2020-02-12 15:13:16 +01:00
Ruben Dashyan
ab80741838
[poincare/test/simplification] Remove redundant tests
2020-02-12 15:13:16 +01:00
Ruben Dashyan
caa7e6fbbf
[poincare/test/helper] Print richer information when test fails
2020-02-12 15:13:16 +01:00
Ruben Dashyan
3271fc90a4
[poincare/test] Clean header inclusions
2020-02-12 15:13:16 +01:00
Ruben Dashyan
5d1cc521f4
[poincare/expression] Mark nbChildren variable as const in deepBeautify
2020-02-12 15:13:16 +01:00
Ruben Dashyan
6ff28bf5ea
[poincare/addition] Do not recompute the number of children in shallowBeautify
2020-02-12 15:13:16 +01:00
Léa Saviot
4e6378fe18
[test/regression] Add a logistic test
2020-02-12 15:13:16 +01:00
Léa Saviot
a8ead6b66e
[apps/regression] Better initialisation of logistic model coefficients
...
It provides a better fit for:
x = {0.0, 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0}
y = {5.0, 9.0, 40.0, 64.0, 144.0, 200.0, 269.0, 278.0, 290.0, 295.0}
(coeffs should be {64.9, 1.0, 297.4})
2020-02-12 15:13:16 +01:00
Léa Saviot
3747b5a4b0
[apps/regression] Virtualize only the specialized part of initCoefs
2020-02-12 15:13:16 +01:00
Léa Saviot
2c497d4f55
Revert "[escher] Force relayouting in a table view"
...
This reverts commit 94281b906d5135f4d3181ca248f572e32be9119c.
The commit created a lot of blinking in the calculation history (for
instance for multiple lines of 56) + "the table's size might be
miscomputed" due to the layouting order (but we have not searched for an
example of such a miscomputation)
2020-02-12 15:13:16 +01:00
Ruben Dashyan
5787d50a45
Revert "[apps/calculation/edit_expression_controller] Define viewWillAppear"
...
This reverts commit 960736203ff2f816688868e3397d178d931fa3c3.
2020-02-12 15:13:16 +01:00
Ruben Dashyan
7f4dd1255a
Revert "[escher/layout_field] Factor insertLayoutAtCursor"
...
This reverts commit b06cac4fcce0c1ab3fedd6c44846983962316749.
2020-02-12 15:13:16 +01:00
Émilie Feral
3a19939a64
[apps/regression] Missing ;
2020-02-12 15:13:16 +01:00
Ruben Dashyan
89aa0ac302
[apps/regression/graph_controller] Clean moveCursorHorizontally
2020-02-12 15:13:16 +01:00
Ruben Dashyan
2fb6824947
[apps/shared/interactive_curve_view_controller] Rewrite comment about addMargin
2020-02-12 15:13:16 +01:00
Ruben Dashyan
8cb2b99254
[apps/graph/calculation_graph_controller] Remove handleLeftRightEvent
2020-02-12 15:13:16 +01:00
Ruben Dashyan
bc0b5c092a
[escher/layout_field] Factor insertLayoutAtCursor
2020-02-12 15:13:16 +01:00
Ruben Dashyan
89ea31d190
[eshcer/layout_field] Factor handleEvent
2020-02-12 15:13:16 +01:00
Ruben Dashyan
d604df85b2
[escher/layout_field] Remove magic number
2020-02-12 15:13:16 +01:00
Ruben Dashyan
7fce83d1dd
[escher/expression_field] Detect whether view's height did change by memoizing the height
...
Such changes used to be detected only when the height was equal to the
maximal allowed value, by detecting whether the height shifted from or
to that maximal value. For that purpose, a boolean was memoized in
InputViewController and in Calculation::EditExpressionController.
2020-02-12 15:13:16 +01:00
Ruben Dashyan
40d75ffefa
[escher/expression_field] Remove unused reload() method
2020-02-12 15:13:16 +01:00
Ruben Dashyan
3bc3532358
[escher/expression_field] Replace maximalHeight() by k_maximalHeight
...
To harmonize with k_minimalHeight
2020-02-12 15:13:16 +01:00
Ruben Dashyan
b832a9e9f4
[apps/calculation/edit_expression_controller] Define viewWillAppear
2020-02-12 15:13:16 +01:00
Ruben Dashyan
b624e47ccb
[apps/calculation/edit_expression_controller] Remove dummy viewDidDisappear
...
HistoryController does not override ViewController's default
viewDidDisappear.
2020-02-12 15:13:15 +01:00
Ruben Dashyan
7a49e23e3b
[apps/calculation] Factor HistoryController::reload
2020-02-12 15:13:15 +01:00
Émilie Feral
e550712ccc
[apps/settings] Separation is always below the CellWithSeparator
2020-02-12 15:13:15 +01:00
Émilie Feral
f7fc8da94d
[apps/settings] Use a MessageTableCellWithGaugeWithSeparator in the main
...
controller to mimic two tables
2020-02-12 15:13:15 +01:00
Émilie Feral
953c9dfe64
[apps/settings] Create a parent class CellWithSeparator to
...
MessageTableCellWithEditableTextWithSeparator for future factorization
2020-02-12 15:13:15 +01:00
Émilie Feral
3627dc0c0f
[apps/code] Choose editor font size from GlobalPreferences
2020-02-12 15:13:15 +01:00
Émilie Feral
c2dabf6510
[apps/code] Choose console text size from GlobalPreferences
2020-02-12 15:13:15 +01:00
Émilie Feral
b3d45833d0
[apps/settings] Add a menu "Font size" in settings
2020-02-12 15:13:15 +01:00
Émilie Feral
d48006f994
[apps/settings] Add messages about font sizes
2020-02-12 15:13:15 +01:00
Émilie Feral
39a6fdaf1c
[apps/settings] MainController: get rid of magic numbers
2020-02-12 15:13:15 +01:00
Émilie Feral
4a41ec0fda
[apps] GlobalPreferences: add font (Large or Small)
2020-02-12 15:13:15 +01:00
Léa Saviot
1434158bee
[apps/graph] Faster curve navigation after some time
...
If the user presses the LEft/Right keys for a long time, the cursor will
move faster.
2020-02-12 15:13:15 +01:00
Léa Saviot
b9bc9008ac
[ion] Detect long repeated events
...
This will be use for instance to sroll faster if the user presses the
directional keys for a long time
2020-02-12 15:13:15 +01:00
Léa Saviot
973c2149d4
[ion/battery] Battery level has some hysteresis
...
This prevents a blinking battery pictogra wwhen the battery level is at
the limit between two states.
2020-02-12 15:13:15 +01:00