menus: Place ListMenu as a keyboard-accesisble menu

Remove the `DataMenu`.

Replace `PrintMenu` with `ListMenu` as keyboard-accessible menu
(we can tuck the rarely used `PrintMenu` under `I/O`)

Add list product, sum, etc to `ListMenu`

Modify `ProgramMenu` to add special program entry characters.

Signed-off-by: Christophe de Dinechin <christophe@dinechin.org>
This commit is contained in:
Christophe de Dinechin 2024-03-27 19:20:08 +01:00
parent 765a97c6e7
commit 838938336e
9 changed files with 19 additions and 29 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 353 KiB

After

Width:  |  Height:  |  Size: 353 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 296 KiB

After

Width:  |  Height:  |  Size: 295 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 296 KiB

After

Width:  |  Height:  |  Size: 295 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 353 KiB

After

Width:  |  Height:  |  Size: 353 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 207 KiB

After

Width:  |  Height:  |  Size: 206 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 207 KiB

After

Width:  |  Height:  |  Size: 206 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 207 KiB

After

Width:  |  Height:  |  Size: 206 KiB

View file

@ -785,13 +785,20 @@ MENU(ProgramMenu,
// ----------------------------------------------------------------------------
// Programming menu
// ----------------------------------------------------------------------------
"«»", ID_SelfInsert,
"{}", ID_SelfInsert,
"[]", ID_SelfInsert,
"→ «»", ID_SelfInsert,
"→ ''", ID_SelfInsert,
"Eval", ID_Eval,
"Tests", ID_TestsMenu,
"Compare", ID_CompareMenu,
"Loops", ID_LoopsMenu,
"Bases", ID_BasesMenu,
"Stack", ID_StackMenu,
"Debug", ID_DebugMenu,
"Debug", ID_DebugMenu,
"Objects", ID_ObjectMenu,
"Lists", ID_ListMenu,
"Flags", ID_FlagsMenu,
@ -915,47 +922,30 @@ MENU(ListMenu,
"Size", ID_Size,
"Head", ID_Head,
"Tail", ID_Tail,
"Get", ID_Get,
"Sort", ID_Sort,
"QSort", ID_QuickSort,
"Reverse", ID_ReverseList,
"GetI", ID_GetI,
"PutI", ID_PutI,
"Put", ID_Put,
"RSort", ID_ReverseSort,
"RQSort", ID_ReverseQuickSort,
"Objects", ID_ObjectMenu,
"Matrix", ID_MatrixMenu,
"Vector", ID_VectorMenu,
"Data", ID_DataMenu);
"∑List", ID_ListSum,
"∏List", ID_ListProduct,
"∆List", ID_ListDifferences,
MENU(DataMenu,
// ----------------------------------------------------------------------------
// Operations on data
// ----------------------------------------------------------------------------
"→List", ID_ToList,
"Obj→", ID_Explode,
"Sort", ID_Sort,
"RSort", ID_ReverseSort,
"Map", ID_Map,
"Reduce", ID_Reduce,
"Filter", ID_Filter,
"", ID_Sum,
"", ID_Product,
"", ID_Unimplemented,
"Get", ID_Get,
"Put", ID_Put,
"GetI", ID_GetI,
"PutI", ID_PutI,
"Reverse", ID_ReverseList,
"Obj→", ID_Explode,
"Find", ID_Unimplemented,
"QSort", ID_QuickSort,
"RSort", ID_ReverseSort,
"RQSort", ID_ReverseQuickSort,
"Objects", ID_ObjectMenu,
"Lists", ID_ListMenu);
"Matrix", ID_MatrixMenu,
"Vector", ID_VectorMenu);
MENU(ObjectMenu,
@ -981,7 +971,7 @@ MENU(ObjectMenu,
"DTag", ID_dtag,
"Matrix", ID_MatrixMenu,
"List", ID_ListMenu,
"Data", ID_DataMenu);
"Vector", ID_VectorMenu);
MENU(UnitsConversionsMenu,

View file

@ -4129,7 +4129,7 @@ static const byte defaultShiftedCommand[2*user_interface::NUM_KEYS] =
OP2BYTES(KEY_1, 0),
OP2BYTES(KEY_2, 0),
OP2BYTES(KEY_3, menu::ID_ProgramMenu),
OP2BYTES(KEY_SUB, menu::ID_PrintingMenu),
OP2BYTES(KEY_SUB, menu::ID_ListMenu),
OP2BYTES(KEY_EXIT, command::ID_Off),
OP2BYTES(KEY_0, command::ID_SystemSetup),
OP2BYTES(KEY_DOT, command::ID_Show),