Commit Graph

721 Commits

Author SHA1 Message Date
Émilie Feral
6a2f11ef1b [escher] ExpressionTableCell & ExpressionTableCellWithExpression:
reloadScroll when displaying cell
2020-02-12 15:13:20 +01:00
Émilie Feral
74b5ca2f12 [escher] ExpressionTableCellWithExpression: avoid to add margins around
the accessory subview twice
2020-02-12 15:13:20 +01:00
Émilie Feral
3806a78141 [escher] ExpressionTableCellWithExpression: make the accessory
expression scrollable and set it as the first responder
2020-02-12 15:13:20 +01:00
Émilie Feral
4bd3dfd542 [escher] TableCell: the subviews are layoutted horizontally or
vertically. We add an option to decide which subviews should overlap on
top of the other if there is not enough space
2020-02-12 15:13:20 +01:00
Émilie Feral
5974149162 [escher] Metric: change name TableCellLabelTopMargin to
TableCellHorizontalMargin and add TableCellHorizontalMargin
2020-02-12 15:13:20 +01:00
Émilie Feral
9312d2bd65 [escher] ExpressionTableCell is composed of a ScrollableExpressionView
instead of an ExpressionView
2020-02-12 15:13:19 +01:00
Émilie Feral
9301dd510a [calculation][escher] Move ScrollableExpressionView from apps/calculation/ to
escher/
2020-02-12 15:13:19 +01:00
Émilie Feral
439c85eda5 [escher] TableCell: make the label margin optional 2020-02-12 15:13:19 +01:00
Émilie Feral
8915148e72 [escher] Add a class BurgerMenuView 2020-02-12 15:13:18 +01:00
Léa Saviot
d9b284c1ec [escher/text_input] ShiftUp/Down selects whole textfield on left/right 2020-02-12 15:13:18 +01:00
Léa Saviot
2eaf84cc73 [escher/app/modal_view] If will exit app, do not relayout
App::willBecomeInactive calls dismissModalViewController, which puts
back the previous repsonder and calls layoutSubviews on the
modalViewController. We do not want to do all these operations when the
app will be exited anyways.
2020-02-12 15:13:18 +01:00
Léa Saviot
3ff94b8930 [escher/text_input] Fix cursor position when deleting selection 2020-02-12 15:13:18 +01:00
Léa Saviot
cb53038909 [escher] Text input has alignment, not text field 2020-02-12 15:13:18 +01:00
Léa Saviot
aad1636238 [escher/text_input] Methods reordering 2020-02-12 15:13:18 +01:00
Léa Saviot
fb18b7cd69 [escher/text_input] Maxe some member variables protected 2020-02-12 15:13:18 +01:00
Léa Saviot
51742aef40 [escher/layout_cursor] Set height to the selection height
4
For instance, 123+- with "123+" selected, the cursor on the left of the
                  5
fraction will have the height of the selection.
2020-02-12 15:13:17 +01:00
Léa Saviot
c29ab14f20 [escher/layout_field] Better handling of layout recomputation
After a selection event, there is no need to recompute the layout. We
still need to dirty the union of the previous and next selection
rectangles.
2020-02-12 15:13:17 +01:00
Léa Saviot
f7ada7dac0 [escher/layout_field] Simplify the layout selection algorithm 2020-02-12 15:13:17 +01:00
Léa Saviot
efc8a238ea [escher] Rename deleteSelectedText -> deleteSelection 2020-02-12 15:13:17 +01:00
Léa Saviot
5de65e0d7e [escher/layout_field] Copy selection 2020-02-12 15:13:17 +01:00
Léa Saviot
2e589f6eac [escher] Delete selection on layouts 2020-02-12 15:13:17 +01:00
Léa Saviot
a959f9fa98 [poincare/lyt_cursor] When selecting, we add one full layout each time 2020-02-12 15:13:17 +01:00
Léa Saviot
03f07d65ed [escher/layout_field] Remove selection on simple left/right/up/down 2020-02-12 15:13:17 +01:00
Léa Saviot
377cca7e3d [escher/layout_field] Start handling selection 2020-02-12 15:13:17 +01:00
Léa Saviot
33b5f008a2 [escher/text_field] Selection 2020-02-12 15:13:17 +01:00
Léa Saviot
9c5843500a [escher/text_input] Fix reload and scroll after deleteSelectedText 2020-02-12 15:13:17 +01:00
Léa Saviot
20c761d3f0 [escher/text_area] Fix slection over wrote
Scenario: 34567          then press 0 -> we want 3067
           ** selected
2020-02-12 15:13:17 +01:00
Léa Saviot
e98b67634d [escher/text_area] Improve dirty tracking 2020-02-12 15:13:17 +01:00
Léa Saviot
b6f3b39086 [escher/text_input] Rename currentSelectionIsEmpty -> selectionIsEmpty 2020-02-12 15:13:17 +01:00
Léa Saviot
67008f454e [escher/text_area] Replace the selection when event with text 2020-02-12 15:13:17 +01:00
Léa Saviot
d05a95c87c [apps/code] Reset selection when leaving script editor 2020-02-12 15:13:17 +01:00
Léa Saviot
95d0715606 [escher/solid_text_area] Remove unused class 2020-02-12 15:13:17 +01:00
Léa Saviot
30923ed4c6 [escher/text_area] Select up/down 2020-02-12 15:13:17 +01:00
Léa Saviot
349b4f8532 [escher/text_area] Fix selection color 2020-02-12 15:13:17 +01:00
Léa Saviot
14cc6ffc59 [escher/text_area] Select and copy 2020-02-12 15:13:17 +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
Léa Saviot
984bfca68e [escher] ScrollView TODO comment 2020-02-12 15:13:15 +01:00
Léa Saviot
9f018eb9d9 [escher/view] setFrame and layoutSubviews can be forced 2020-02-12 15:13:15 +01:00
Léa Saviot
f85658f5e6 [escher/view] Inline some view methods 2020-02-12 15:13:15 +01:00
Ruben Dashyan
1c668dca52 [escher/layout_field] Remove unused enum class 2020-02-12 15:13:15 +01:00
Ruben Dashyan
ecd6cb29f1 [escher/expression_field] Rename k_textFieldHeight to k_minimalHeight
That constant has nothing to do with TextField. It is the minimal height
of ExpressionField.
2020-02-12 15:13:15 +01:00
Ruben Dashyan
063cc66ba2 [escher/layout_field] Make protected methods private
LayoutField has no derived class
2020-02-12 15:13:15 +01:00
Ruben Dashyan
737d76471b [escher/layout_field] Remove unused accessor 2020-02-12 15:13:15 +01:00
Léa Saviot
4e96a11a4c [escher/responder] Clean commonAncestor method 2019-12-20 11:49:30 +01:00
Léa Saviot
0412a45cea [escher/responder] Inline some methods 2019-12-20 11:49:30 +01:00
Romain Goyet
758c217120 [ion] ion_main takes const arguments 2019-10-16 10:01:00 +02:00
Émilie Feral
4d593a6149 [poincare] PrintFloat: take into account the distinction between char
and glyph length in ConvertFloatToText
2019-09-26 11:26:48 +02:00
Émilie Feral
3872785d57 [escher] Add Metric::CellMargin 2019-09-26 11:26:48 +02:00