Commit Graph

7312 Commits

Author SHA1 Message Date
Émilie Feral
d11967f41a [poincare] Fix CharLayout: avoid adding multiplication sign between Sto
and another expression
2018-05-24 14:49:00 +02:00
Émilie Feral
386ebc5bfc [poincare] Decimal: fix buffer overflow in convertToText 2018-05-23 10:26:52 +02:00
Émilie Feral
84a78c8a9b [probability] Add comment for future improvement in Binomial law
computation
2018-05-23 10:14:21 +02:00
Émilie Feral
0ee32e15be [shared] Curve view: Avoid drawing all bars in histograms when bars
overlap each other due to pixel resolution
2018-05-23 10:14:21 +02:00
Émilie Feral
f2887e895d [probability] Increase the cap of parameters on binomial law 2018-05-23 10:14:21 +02:00
Émilie Feral
7f6d1f0e31 [probability] Fix evalution of the binomial density: some computation
were done in float instead of in double
2018-05-23 10:14:21 +02:00
Émilie Feral
da8286d3f7 [code] Escaping the input loop on a 'home' event should be handled by
the code app instead of the console controller to ensure to escape the
input loop even when the toolbox (or any modal) is displayed
2018-05-23 10:01:15 +02:00
Émilie Feral
5cfe20ad15 [code] Move ConsoleController from MenuController to App 2018-05-23 10:01:15 +02:00
Émilie Feral
2bd93844cd [poincare] Bug Product([1 1], 1, 3): if the intermediate result is
nullptr, escape the evaluation and return an undefined expression
2018-05-23 09:56:26 +02:00
Émilie Feral
f2d096be63 [emscripten] Add WHITELISTED symbols to call 'input()' outside a
function in Python
2018-05-22 17:48:48 +02:00
Romain Goyet
8fc32900c2 [emscripten] Sort ASYNC symbols 2018-05-22 15:59:20 +02:00
Romain Goyet
bb10e13aab [emscripten] Allow "input()" to be called outside of a function 2018-05-22 15:59:20 +02:00
Léa Saviot
7fec844759 Makefile: Version 1.5.0
Change-Id: I1f887fc12dc74586bfe30f3ab015c412166c1f81
2018-05-17 17:56:42 +02:00
Émilie Feral
eaabe7e486 [poincare] Set default edition mode to 2D 2018-05-17 17:56:20 +02:00
Émilie Feral
58d10403e2 [apps/sequence] Fix maxFirstIndex for double recursive sequences 2018-05-17 17:32:55 +02:00
Léa Saviot
f2d1247cf9 [code] Invalid the script node. If we don't, layouting the subviews
would use the deleted python heap.
using the python heap before

Change-Id: Icf77e7723d843ff415b8e2da11f5ab64eba48aef
2018-05-17 17:23:55 +02:00
Émilie Feral
b2b141aae4 [escher] Fix underscore replacement for subscript insertion in textfield 2018-05-17 16:53:16 +02:00
Émilie Feral
8541c2cb7e [sequence] Add a pop-up when the user tries to set the first term
index to a value above 1000
2018-05-17 15:39:14 +02:00
Émilie Feral
3a29f086a0 [sequence] Fix u(0), u(1) layout in sequence list 2018-05-17 15:39:14 +02:00
Léa Saviot
7e9b4c1a60 [apps/code] Fix buffer indexes
Change-Id: Ib5748d59fd762af9337e00115f0db4ac5d6d08a9
2018-05-17 15:26:46 +02:00
Léa Saviot
6aaab293d6 [apps/code] Change memcpy to memmove on overlapping buffers
Change-Id: Ic85b177375a4030ad80c8c539ee0084fb095ad44
2018-05-17 15:26:46 +02:00
Léa Saviot
8240d3d0df [poincare] Fix layout engine buffer access
Change-Id: I8db088bc036456a0524f1115517da1c6459a829d
2018-05-17 14:30:08 +02:00
Léa Saviot
6d18d228bf [poincare] Fix power layout serialization
Change-Id: Ib8fa0ead7e4de57504c41b3d353d5d60b58c300f
2018-05-17 14:09:52 +02:00
Émilie Feral
c3b35302aa [escher] Clean Expression layout field 2018-05-17 13:53:10 +02:00
Émilie Feral
5dcfbf83e9 [escher] ExpressionLayoutFieldDelegate should not take a text as
parameter but a layout
Warning: in ExpressionField: the serialized layout is not guaranteed to
be small enough to fill in the text buffer
2018-05-17 13:53:10 +02:00
Émilie Feral
33ac117424 [ion] blackbox keyboard scan
The scan of keyboard in Blackbox should indicate that no
key is pressed in order to avoid interrupting all simplification
2018-05-17 13:45:21 +02:00
Léa Saviot
3953ca1c67 [escher] Remove duplicate method
Change-Id: Iac03f002cb6928831a8d640f1bcdeba116f71d06
2018-05-17 13:42:20 +02:00
Léa Saviot
b752ab0389 [escher] Add bool forceCursorRightOfText in handleEventWithText
Change-Id: I9124a1bacfce821fc761ddefc4d8b43de82dbc21
2018-05-17 13:42:20 +02:00
Léa Saviot
2e03812cdb [poincare] Fix cursor position when layout field is not editing
Change-Id: I39fa348a3e567621f4574b2e331b75a836353306
2018-05-17 13:42:20 +02:00
Léa Saviot
05334823e5 [escher] Handle empty text in ExpressionLayoutField::handleEventWithText
Change-Id: Ieb8433a7cf24341b576ab76014cc4cf1e36d929b
2018-05-17 13:42:20 +02:00
Léa Saviot
804d221565 [poincare] Remove case in MatrixLayout::removePointedChildAndMoveCursor
Change-Id: Ib4d2ea118bb6fdcb10dcbbbd80f234130f1c539f
2018-05-17 13:22:05 +02:00
Léa Saviot
6c096eadcd [poincare] Fix cursor position in matrix layout child insertion
Change-Id: I7eab5968181cf4ecd9d3e6600d310322b98f6339
2018-05-17 13:22:05 +02:00
Léa Saviot
d84c91f547 [escher] Reorganize event handling in ExpressionLayoutField
Change-Id: I41f7ccbe742c344d1710eca844715ec2e2ec0fbc
2018-05-17 13:22:05 +02:00
Léa Saviot
08b3f73b9c [escher] Return true when layout too big to be handled
Change-Id: If15f032c4d1666021435927d90f500afbdee3bfd
2018-05-17 13:22:05 +02:00
Léa Saviot
bde05b3d8b [escher] Fix layout count verification in ExprLayField::handleEvWText
Change-Id: Ie56e61aa10c907c6ab0dac8814b9ed46aac669f8
2018-05-17 13:22:05 +02:00
Émilie Feral
6035bd904b [escher] Expression layout: Prevent from inserting XNT when the field is full 2018-05-16 19:20:34 +02:00
Émilie Feral
8b0225ec0e [calculation] Fix bug: update strlcpy with real size of buffer 2018-05-16 19:19:48 +02:00
Émilie Feral
05cd2b5866 [shared] Sequence/Function: on graph zoom on center if the cursor is undefined 2018-05-16 18:51:35 +02:00
Émilie Feral
0c93a50018 [calculation] Increase the cache buffer to accept serialized layout
which would fit in calculation
2018-05-16 18:45:44 +02:00
Léa Saviot
372a214afb [poincare] Prevent insertion of a big layout in ExprLayField
For instance when copy-pasting a layout.

Change-Id: I5967a601b783b81cb537ab4b46e03118f3bd6cdc
2018-05-16 18:37:02 +02:00
Léa Saviot
c2d273bba5 [escher/poincare] ExprLayoutField cannot have more than 152 descendants
If the number of layouts could be infinite, we would have memory
problems. A Layout uses at least one char when being serialized, so we
use the same limit as the char limit in TextField.

Change-Id: Ib8f9c05d04a4dde5b6ca96a732e3e4175dd65b9c
2018-05-16 18:37:02 +02:00
Léa Saviot
f1635515a8 [poincare] Make ExpressionLayoutField::insertLayoutAtCursor private
Change-Id: I809a04a87b933ef18dd6c02d29502ccf443ffa46
2018-05-16 18:37:02 +02:00
Léa Saviot
8c275ca2b6 [poincare] Remone unused function ExpressionLayout::insertLayoutAtCursor
Change-Id: I5906146998229641976d8a4fe3fd16c56f060085
2018-05-16 18:37:02 +02:00
Léa Saviot
22b0c4c8b1 [escher] Remove duplicate function
Change-Id: I6301f10bf1598a81956909137109ed1a721d3a1a
ExpressionLayoutField::insertLayoutFromTextAtCursor
ExpressionField::handleEventWithText
2018-05-16 18:37:02 +02:00
Émilie Feral
1108ef21db [calculation] Do not memoize the expression layouts but the expressions
final height to avoid overflowing the heap. The expression layouts are
kept in the cell which are fewer then the number of calculations
2018-05-16 18:36:45 +02:00
Léa Saviot
a67f422ab7 [apps/sequence] Fix first/second term index display.
Before, it was always u0 and u1.

Change-Id: Iad5a3992a16f4b4a55e295b24f6a784a17f2807b
2018-05-16 18:36:34 +02:00
Léa Saviot
0294ebc448 [escher] Fix signed/unsigned int comparison
Change-Id: I72b6dc3f46ee585814a540fc999001e113db0ea1
2018-05-16 17:34:34 +02:00
Léa Saviot
96310c75c8 Revert "[poincare] Finer addition of parenthesis when serializing fraction"
This reverts commit a84686d262.

The reverted commit created serialization errors. For instance,
the layout 1/(2^(3) 3) , without the arenthesis, would serialize to
1/(2^3) * 3.

Change-Id: I1ec9b03e84247c9cc30cc643784283d28e6402a7
2018-05-16 17:33:02 +02:00
Léa Saviot
99f6d73e19 [apps/code] Put cursor inside parentheses when inserting function
In Code::VariableBoxController.

Change-Id: Ib129781d46159c017bcb02e97c6667b6084f5b67
2018-05-16 16:00:24 +02:00
Léa Saviot
291958a901 [apps/statistics] Fix buffer overflow in HistogramController.
Change-Id: Idf8f8701ba7b7d18b92dc7b21108387c0fa0aa3a
2018-05-16 15:58:06 +02:00