Running
| Key | What it does |
|---|
F5 | Run the program |
Esc | Stop a running program |
Files
| Key | What it does |
|---|
Ctrl+N | New program |
Ctrl+O | Open a .cmc file |
Ctrl+S | Save (asks for a name the first time) |
Ctrl+Z | Undo (in the Text tab, the editor's undo; in Blocks, the block undo) |
Ctrl+Y | Redo in the Text tab |
Editing text
| Key | What it does |
|---|
Tab | Insert four spaces |
Enter | New line, keeping your indentation, plus four spaces after a block opener |
| Click a line number area | Nothing yet -- line numbers are just for looking |
Blocks
| Key or mouse | What it does |
|---|
| Click palette block | Add it to the end of the stack |
| Drag palette block | Drop it exactly where you want |
| Click a slot | Type an expression |
| Drag a value block into a slot | Fill the slot with that value |
| Right-click block | Delete, Copy, Move up, Move down |
| Drag onto the palette | Delete the block |
Delete | Delete the selected block |
Ctrl+Z | Undo |
| Click empty canvas | Deselect |
Dictionary and examples
Inside the dictionary: type in the search box to filter words. Inside the examples window: click a name to preview, double-click to open in the Text tab.
Terminal shortcuts
When using cmc in a terminal (not the IDE):
| Key | What it does |
|---|
Ctrl+C | Stop the running program |
Ctrl+D | Leave the REPL |
Type quit | Leave the REPL politely |
Next: Troubleshooting.