Commit Graph

82 Commits

Author SHA1 Message Date
Laury
7e64124ddc Revert #113 because of incompatibility with the workshop 2022-03-31 22:19:54 +02:00
Yaya-Cout
f862cb023a [apps/code] Add a setting for cursor saving (#125) 2022-01-14 13:42:30 +01:00
devdl11
0860e48cb6 For those who likes to code ❤ (#113) 2021-12-28 15:13:01 +01:00
Joachim LF
9b17d1b882 [Update] Epsilon 15.3.1 2021-01-21 19:56:06 +01:00
Hugo Saint-Vignes
d937bc692b [apps/code] Fix crashes on full buffer
Change-Id: If9297f1ca29015cad0cc1cdda3ad610fd1493392
2020-11-04 15:11:45 +01:00
Joachim LF
04901e3231 Fixed % in alpha lock 2020-07-13 10:38:22 +02:00
Joachim LF
d7ac7e19bb [Update] Epsilon 14 2020-07-13 10:36:47 +02:00
Léa Saviot
9a1ff2bd33 [apps/code] Status at the beginning of a script is one byte long
This saves space + avoids clashes with the NumWorks Workshop when
exchanging scripts
2020-06-05 11:28:12 +02:00
Léa Saviot
f763bb50ac [apps/code] Do not display subtitles in var box from console 2020-06-04 14:50:07 +02:00
Léa Saviot
cf6b9d580b [apps/code] rename Script::scriptContent() -> Script::content() 2020-06-04 14:50:06 +02:00
Léa Saviot
bba5b237d2 [apps/code] Display different varbox titles from editor and console 2020-06-04 14:50:06 +02:00
Léa Saviot
d1c8bbdaf7 [apps/code] The console marks imported script for the var box
After lauching the console, if we fetch a script we mark it as fetched.
When the variable box displays variables from imported scripts, it scans
all the variables from the scripts marked as fetched.
2020-06-04 14:50:06 +02:00
Léa Saviot
da2730dd64 [apps/code] Autocomplete at the end of tokens
Not at the end of "words" separated by spaces.
2020-06-04 14:50:05 +02:00
Léa Saviot
003317647e [apps/code] Display empty message in var box 2020-06-04 14:50:05 +02:00
Léa Saviot
bc4d96bc3f [apps/code] Reload the variable box less often 2020-06-04 14:50:04 +02:00
Léa Saviot
f412d95584 [apps/code] Load builtins according to autocompleted text 2020-06-04 14:50:04 +02:00
Léa Saviot
b9693f1f26 [apps/code] Load variable box with script index argument 2020-06-04 14:50:03 +02:00
Quentin Guidée
a2b8b603c5 Merge branch 'omega-dev-e13' of github.com:Omega-Numworks/Omega into omega-dev-e13 2020-02-17 17:10:42 +01:00
Romain Goyet
7f43b73049 [apps] Don't forget to call viewWillAppear
At the moment ViewController::viewWillAppear doesn't do anything, so
there is no real impact. But if we want to use it it needs to be called
from subclasses.
2020-02-17 10:31:24 -05:00
redgl0w
eaef26c1aa Update editor_controller.cpp 2020-02-17 09:53:30 +01:00
Léa Saviot
5a7c03d485 [apps/editor_controller] Fix backspace handling in text area
The editor controller handles backspace if it is at the beginning of a
line, to remove multiple spaces to match the indentation, but it should
not do so if there is an ongoing selection
2020-02-12 15:13:20 +01:00
Léa Saviot
8cf13adaf0 [apps/editor_controller] Handle deleted scripts in cleanStorageEmptySpace 2020-02-12 15:13:18 +01:00
Léa Saviot
344ea5a67a [apps/code] Handle Home event when in the toolbox
If editing a script, the empty space at the end of the script should be
moved to the end of the storage.
2020-02-12 15:13:18 +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
c1b792c23d [apps/code] Get out of script edition on usb enumeration
The storage needs to be in a clean state
2020-02-12 15:13:16 +01:00
Léa Saviot
5853e96947 [apps/code] Remove EditorController::m_areaBuffer
This was a very large buffer that took a lot of RAM space (the size of
the storage). Instead of having it, we just move the available space of
the storage at the end of the edited script, and move it back when the
edition finishes.
This is slower but saves a lot of space.
2020-02-12 15:13:16 +01:00
Léa Saviot
e8be088478 [apps/escher] Factorize TxtArea and Code::EditorCtrlr's k_indentSpaces 2019-08-08 16:22:28 +02:00
Ruben Dashyan
eb6d697927 [apps] Make app accessors static members of App classes 2019-07-19 15:06:25 +02:00
Ruben Dashyan
44809f4b3f Substitute Escher app() by Container::activeApp() 2019-07-19 15:06:25 +02:00
Ruben Dashyan
0490e3ab81 [apps] Define InputEventHandlerDelegate::inputEventHandlerDelegateApp() directly from ::app() 2019-07-19 15:06:25 +02:00
Romain Goyet
21907fb89a [apps] Get rid of App casts 2019-07-19 15:06:25 +02:00
Romain Goyet
45875dd642 [escher] Make app() a global function
This way it can easily be reached by anyone, including non-responders.
And it can easily be overwritten in namespaced apps.
2019-07-19 15:06:25 +02:00
Léa Saviot
5f549b514e [escher] Fix backspace on utf8 combining code point 2019-06-21 14:30:14 -04:00
Ruben Dashyan
5ee130a959 [apps/code/editor_controller] Fix backspace event handling
If there are only spaces on the left of the cursor, then a backspace
should remove two spaces (or one if there is only one of it). The number
of spaces was miscomputed.
2019-06-05 18:15:48 +02:00
Léa Saviot
4c5251f04f [unicode] Use unicode when dealing with chars - Part 2 2019-05-03 15:53:19 +02:00
Léa Saviot
bd2ea41fbe [apps/escher] Rename cursorTextLocation as cursorLocation 2019-05-03 15:53:19 +02:00
Léa Saviot
a7b51f92ee [apps] Remove compilation warning about unused variable 2019-05-03 15:53:19 +02:00
Léa Saviot
5c39cab73e [escher] Fix text inputs so they use UTF8 2019-05-03 15:53:19 +02:00
Émilie Feral
ea59e651ee [code] EditorController: save script before displaying the variable box 2018-11-23 12:04:03 +01:00
Émilie Feral
a4f7d83805 [code] Load Variable box content before compiling any other python code
to avoid memory exhaustion when displaying variable box
2018-11-23 12:04:03 +01:00
Émilie Feral
698332c355 [escher] InputTextDelegate and LayoutFieldDelegate don't inherit from
InputTextDelegate to avoid diamond inheritance
2018-11-23 12:04:03 +01:00
Émilie Feral
7778c694d1 [escher] Create an InputEventHandlerDelegate that gives the toolbox to
be used by an InputEventHandler
2018-11-23 12:04:02 +01:00
Émilie Feral
01e433a9f2 [escher] Clean Field and Input class hierarchy:
Class hierarchy:
- InputEventHandler
- TextInput
- EditableField derives from InputEventHandler
- LayoutField, TextField and ExpressioField derives from EditableField
- TextArea and TextField derives from TextInput
2018-11-23 12:04:02 +01:00
Émilie Feral
625c0acd8b [code] Fix EditorController: cannot use strcpy when the first char is a
flag that can be 0
2018-10-08 09:46:31 +02:00
Léa Saviot
c16d9e7ffe [apps/code] Load Python in the viewWillAppear of the controllers 2018-09-21 12:26:57 +02:00
Émilie Feral
58ad8bd87e [code] Fix handling of python heap by ConsoleController,
EditorController and VariableBoxController
2018-09-20 11:54:56 +02:00
Émilie Feral
afce751eb7 [code] Get rid of malloc: keep a buffer in Code::App to be used as python heap 2018-09-19 18:20:30 +02:00
Émilie Feral
032db99754 [code] EditorController: avoid dynamic allocation 2018-09-11 17:03:04 +02:00
Émilie Feral
79740e72b0 [code] Avoid dynamic allocation and useless string copy by keeping the
importation status flag in the areaBuffer
2018-09-11 17:03:04 +02:00
Romain Goyet
caff93cda0 [code] Avoid init/deinit-ing uPy in each editor redraw 2018-06-04 16:08:11 +02:00