enterCalc

EnterCalc Keyboard Actions and Context Matrix

This document defines keyboard behavior currently implemented in EnterCalc for iOS and macOS.

Sources:

Global Notes

Keyboard Matrix

Key Base Direct edit Rounding overlay History overlay
Insert Enter direct edit; caret to trailing boundary Already in direct edit; no extra action Blocked while overlay is active Blocked while overlay is active
Left Arrow Move display caret left (activates direct edit if possible) Move display caret left Decrease rounding precision step Suppressed
Right Arrow Move display caret right (activates direct edit if possible) Move display caret right Increase rounding precision step Suppressed
Down Arrow Open rounding overlay (unless turned off in Settings) Open rounding overlay (unless turned off in Settings) No-op (consumed) Suppressed
Up Arrow No mapped action No mapped action Close rounding overlay Suppressed
Shift + Down Arrow Increase display size (20pt) Increase display size Increase display size Increase display size
Shift + Up Arrow Decrease display size (20pt) Decrease display size Decrease display size Decrease display size
Shift + Left Arrow iPad: go to the page on the left Same Same Same
Shift + Right Arrow iPad: go to the page on the right Same Same Same
Command + Left / Right Arrow iPhone Duo and iPad: select the left or the right of two calculators shown side by side Same Same Same
Escape Clear all Exit direct edit Close overlay (rounding stays) Close overlay
End Clear all Exit direct edit Close overlay Close overlay
Backspace Delete one char/digit via model backspace Delete one char/digit before caret Remove rounding and close overlay Clear history and close overlay
Forward Delete Delete one char/digit via model backspace Delete one char/digit before caret Remove rounding and close overlay Clear history and close overlay
Return / Enter / Keypad Enter Evaluate Exit direct edit Close overlay Nothing
Space None None Press the control Tab has moved to Reuse the history row Tab has moved to
Digits 0-9 Input digit Insert at display caret Not handled here Suppressed
Decimal . Input decimal separator Insert decimal at display caret Not handled here Suppressed
+ - * / Set operator Set operator (exits direct edit in model flow) Not handled here Suppressed
% Apply percent Apply percent Not handled here Suppressed
( and ) Input parentheses Input parentheses Not handled here Suppressed
= Evaluate Evaluate path applies; direct edit Enter key exits edit Not handled here Suppressed
Currency symbols ($, €, £, etc.) Activate currency input mode with symbol Same behavior at caret position Not handled here Suppressed

Turning off Down Arrow to round

Settings has a switch that turns off the Down Arrow shortcut for the rounding overlay: Disable press down to round on the Mac, and Disable swipe down to round on iPhone and iPad, where the same switch also turns off the swipe and an iPad keyboard’s Down Arrow (#154). With it on, rounding is still reachable from its menu command and the rounding function key. Shift + Down Arrow still resizes the display.

Currency Mode

The calculator is in currency mode exactly when a currency symbol is showing; there is no separate mode selection. Entering one (by typing a currency symbol as above, or with the on-screen currency key beside the mode label) switches the mode label from Basic to Currency.

The on-screen key toggles: pressing it once applies the symbol chosen in Settings, and pressing it again leaves currency mode and removes the symbol without changing the entered value. It clears whichever symbol is active, including one typed on a hardware keyboard that differs from the configured one, so it is always a reliable way back to Basic.

Which symbol the key applies is chosen in Settings. It defaults to the device region’s currency (en-GB gives £, en-US gives $, de-DE gives €) until the user picks one.

Platform Notes

Resizing the display (macOS)

The split between the display and the keypad can be dragged, which leaves it unreachable without a pointer. Shift + Down Arrow makes the display bigger and Shift + Up Arrow smaller, as if pulling its lower edge (#164). Each press moves it 20 points, within the same limits the drag handle respects, and stops at either end rather than wrapping.

These are menu commands under View → Increase / Decrease Display Size, not just key bindings, so they are discoverable and reachable by VoiceOver. The menu owns the shortcut: the app’s key monitor deliberately ignores Shift + Up/Down so a single press applies a single step, and so Shift + Down does not open the rounding overlay the way a bare Down Arrow does.

The step is not animated: it lands immediately, matching how dragging behaves.

Choosing a mode (macOS and iPad)

Command + 1 selects Basic and Command + 2 selects Currency, for the focused page (#142). They are menu items under View → Mode, checked for the current mode, so they are discoverable and reachable by VoiceOver. The same list opens from the mode name in the display. Further modes get the next numbers.

Changing mode keeps the value on the display and can be undone, the same as the currency key.

Switching pages (iPad)

Shift + Left/Right Arrow moves between calculator pages, as menu commands so they are discoverable and reachable by VoiceOver.

The arrow names the page to go to: Shift + Right shows the page on the right, the same convention as Ctrl + Right for Spaces and the side the page dots grow on. #83 originally had it follow the swipe’s finger direction (dragging left reveals the page on the right, so Shift + Left did too), but that read as inverted on a keyboard in 1.1.0 QA, where an arrow is taken as “go this way” rather than “push the content this way”.

On the iPhone Duo (#168) and the iPad in landscape (#172) with two calculators side by side, Command + Left Arrow and Command + Right Arrow move the keyboard to the left or the right calculator: typed keys, Shift + Left/Right and the panes then go to that one, its display keeps full contrast while the other’s dims, Settings (⌘,) opens as a card over that calculator, and VoiceOver says which calculator is active and what it shows.

Shift + Right past the last page opens a new page, the same as swiping onward from it, so the shortcut is not a more limited way to get around than the gesture. Shift + Left stops at the first page rather than wrapping.

macOS has no equivalent because its pages are separate windows; see below.

Investigated for #83 and deliberately not implemented. macOS already cycles an app’s windows with **Cmd + ** (a system shortcut, on by default), and every calculator window appears in the standard **Window** menu. Adding Shift + Left/Right on top would duplicate that, take two more key combinations away from the calculator, and mean teaching the local key monitor to ignore them, the same trap that made Shift + Down open the rounding overlay instead of resizing. The app's key monitor passes Cmd + straight through, so window cycling already works.

Command Shortcuts

Overlay Priority Rules

Tab and Space (#164)

Every control can be reached from the keyboard, on the Mac and on iPhone and iPad with a keyboard:

On the Mac this works whatever the system’s Keyboard navigation setting. On iPhone and iPad, Tab and Space come from Full Keyboard Access (Settings → Accessibility → Keyboards), which each person turns on themselves; EnterCalc’s keys are the same either way.