hex/ios/HEXShared/TypingLog
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Ryan Vogel c7e96f1808
iOS keyboard: the full keyboard on iPad, sized like Apple's iPad keyboards (#2313)
Why: on an iPad Hex always showed the dictation bar, which testers read as a bug
("Full keyboard doesn't work on iPad"; three TestFlight reports and three replies on X
in one day). The app stays iPhone-only, but iPadOS runs its keyboard as an iPad keyboard,
so this is Phase 1 of ~/dev/experiments/2026-11-22-hex-ipad-keyboard/scope.md.

What changed:
- KeyboardViewController: the idiom == .phone gate is gone (mountSurface and the emoji
  key). An iPad follows Settings › Keyboard as an iPhone does: Full by default, the
  dictation bar when chosen (it was always the bar on iPad). The bar itself is unchanged.
- KeyboardLayout: KeyboardPadSize (mini, 11-inch, 13-inch by the screen's shorter side)
  and KeyboardPadPlacement (docked or floating) beside KeyboardPhoneSize, and
  KeyboardMetrics.pad: Apple's key heights, row pitch, gaps and side insets per iPad and
  orientation, measured beside Apple's keyboard in the iPadOS 27.2 simulator, so Hex's
  four rows sit on Apple's bottom four from the screen's bottom (iPadOS leaves 20 pt under
  a third-party keyboard). Above them the strip (Apple's 44 pt bar, words centred) and 44
  pt kept clear for iPadOS's shortcut bar, which some apps draw over a custom keyboard's
  top (the dictation bar keeps the same room). Floating: Apple's floating keyboard (26 x
  38.25 pt keys, 54.3 pt pitch, 271 pt), no globe of Hex's own (iPadOS draws one under it).
  Docked: a hide-keyboard key (KeyKind.dismiss, dismissKeyboard()) ends the bottom row;
  the email/web rows' function keys are one letter wide there so it fits; no balloons, as
  Apple's docked iPad keyboard has none; labels keep their upright sizes turned.
- FullKeyboardView: on an iPad the orientation comes from the keyboard's width against
  the screen (an iPad's size classes stay regular either way), and the placement and
  height follow docking, floating and turning.
- Settings › Keyboard on iPad: "On iPad, Hex shows the dictation bar" is replaced. While
  Full is chosen the row says "The full keyboard works on iPad too" (zh-Hans "iPad 上也能
  使用完整键盘"); with the dictation bar chosen it says what the iPhone says (#2304's Full
  Access line). Auto-start shows only while the dictation bar is chosen, as on iPhone.
  README describes the iPad.

iPhone unchanged: every iPad value is behind KeyboardMetrics.pad, nil on an iPhone.

Verified (iPadOS 27.2 simulators, iPad mini A17 Pro, iPad Pro 11- and 13-inch M5):
- rows against Apple's in portrait, landscape and floating, light and dark: every row's
  top and bottom within 0.5 pt (one device pixel) of Apple's;
- real HID touches: typing with autocorrect (teh -> the), swipe typing (keyboard), a hold
  menu, the space-bar trackpad, 123 and #+= pages, the emoji panel, the hide key (iPadOS
  minimizes the keyboard to its bar, as with Apple's own hide key), docked either way up
  and floating;
- the Hex key's in-keyboard dictation (recording bar, stop; the simulator has no speech
  model, so no transcript), Hex's hosted recording bar, Paste dictation (a held
  dictation past its 30 s inserted on tap);
- a hardware keyboard: iPadOS minimizes Hex to its pill, typing goes to the field, Hex
  returns full size when it's detached; Stage Manager and Windowed Apps windows 375 pt
  wide and Slide Over: the docked keyboard still spans the screen;
- Settings row in English and Chinese; the dictation bar still shows on iPad when chosen;
- iPhone 17 Pro (iOS 27.2): the keyboard's pixels identical to origin/dev in the same
  field, light and dark;
- KeyboardLayoutTests (new testPad... cases, existing cases unchanged) and the full
  HEXMobile suite (732 tests, 3 skipped, 0 failures) on an iPhone 17 Pro and an iPad Pro
  13-inch simulator, iOS 27.2.

Not verified (no real iPad): memory, whether apps that draw iPadOS's shortcut bar over a
custom keyboard leave the strip clear, iPadOS 26.x.
2026-11-21 22:31:56 -05:00
..
DictationStages.swift ios: record raw typing logs from Hex's keyboard (experiment) (#2024) 2026-11-20 02:13:16 +00:00
TypingLogEvent.swift ios: record raw typing logs from Hex's keyboard (experiment) (#2024) 2026-11-20 02:13:16 +00:00
TypingLogger.swift iOS keyboard: the full keyboard on iPad, sized like Apple's iPad keyboards (#2313) 2026-11-21 22:31:56 -05:00
TypingLogSession.swift iOS: hold the bar to dictate, Learn how I type on, a plain centred Paste, and typing logs off (#2210) 2026-11-21 12:11:58 -05:00
TypingLogStore.swift ios: record raw typing logs from Hex's keyboard (experiment) (#2024) 2026-11-20 02:13:16 +00:00