The size of the ExternalText events shared buffer is now defined as the
size of the SDL_TextInputEvent 'text' field, as it should.
Also fix a wrong parameter being passed to a strlcpy.
Change-Id: I6a57d49d61fec8a009c4711efce564c65544e571
Generate an ExternalText event when catching a SDL_TextInputEvent whose
text cannot be boiled down to one of the regular events.
Change-Id: I036fa2a153c8351979521d7f8cba6b62aa64604b
Added an event to represent the typing of text that is not on the
device's keyboard. ExternalText event's text is read from a buffer, that
will be filled when the event is generated.
ExternalText only exists on the simulator.
Change-Id: Ie78d2c7c2de91da986a1ce2130a5ecd123db48ee
A previous fix to prevent AlphaLock from interfering with the long press
feature broke the long press selection. Revert the changes and find
another solution to the previous problem.
We compare the alpha status to both the state of the Alpha key and the
Lock, which makes sense : Lock is supposed to mimic Alpha being
continuously pressed.
Change-Id: I1349eb83f8971d3a5efcb10de020bb6c0aed64a1
Checking wether the range that has been computed is suitable is now
done in Poincare::Zoom by SanitizeRange.
Change-Id: Ib7ff73a3beae29996b1a773744021ad85c6ba946
Create a method to clean up an ill-formed range, ie a range whose bounds
are not finite, or where max <= min.
Change-Id: If4525e65f95385cfa970be72bbcc21ad84286bfa
This method, that prevented the graph from panning when moving the
cursor for the first time, caused more problems than it solved.
For instance, the graph for 1/(1-x) was not symmetrical because of it.
Change-Id: Ibb22e38ec0ace6b219c0e42dda481c98b5f717f0
Rework the logic so that :
- an undefined function will be displayed with a clealry defined
null range.
- display both an undefined function and a correct function at the
same time will not affect the correct range.
Change-Id: Ife9dc0d2ace667cab5a6b8826347078fca33e4d5
Method yForCursorFirstMove is supposed to expand the window so that the
first move of the cursor won't cause it to pan. It now filters extreme
values to prevent the original window to be totally squashed, such as
with the drawing of e^x and (x-100)(x+10) at the same time.
Change-Id: Icd6c26b01475a112c4231f293e03ab31d80d5e51
Add a clause in InterestingRangesForDisplay to detect strong variations.
This improve the graph for x^x or x^2+x+1 for instance.
Change-Id: I74214c2382cfe4b0e2603556dd8c6cbd450effc0
Added a tolerance when checking orthonormality, so that ranges that are
nearly orthonormal will be made orthonormal.
Change-Id: Ie3bf076086561e3ff6374e7daa9dd1a884c52d5a
When displaying f(x) = undef, the range now defaults to an orthonormal
range, centered on the origin, with axis unit 1.
Change-Id: Ie3515be0572af4849b8ebd113449f4444755b34f
Restore the permanence of the cursor between accesses to the graph
window.
The cursor used to be reset when the models had been modified. As there
is no longer a system in place to track these modifications, we manually
check if there is a curve beneath the cursor before reseting it.
Change-Id: I6f71fc17744b5bf1ee552c82126bb4a08b823629
Change some parameters to improve the output of
RangeWithRatioForDisplay. Notably, change how the size of the range is
weighed.
Change-Id: I7695c61c3f93482f3fed9c7d2183642573b02cff
When looking for a range with a certain ratio using
RangeWithRatioForDisplay, instead of looking for ranges of the form
0.01*1.1^n, search for ranges of the form a*10^k, with a being either 1,
2, or 5.
Change-Id: I2eaa229574a9a6aa4afa6eb1a3d57365d3d52801
The normalized status would not be refreshed after a call to setDefault
triggered by InteractiveCurveViewController::viewWillAppear.
Change-Id: I923ef3ca0585dbcc1f32b992d7dd1f4a3a206532
The method FunctionGraphController::yRangeForCursorFirstMove expands the
Y range to include the values of the first cursor moves on the left and
the right of the center. It has been modified to preserve
orthonormality.
Change-Id: I898ab9721e45e2acde261f8b94b80cab81b39a92