hex/ios/HEXMobileTests
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Ryan Vogel 3a2cf8dff3 iOS keyboard: the top bar is Apple's prediction bar, as thick as Apple's, with its bubble and dividers
What: on an iPhone the strip above the keys is now Apple's whole prediction bar
instead of the part below its pill. Measured as a black box beside Hex in the same
plain field on iOS 26.5 and 27.2 (iPhone 17 Pro, Air, 17 Pro Max and SE, upright
and turned, light and dark): Apple's bar is 44 pt from the keyboard's top edge on
every iPhone, row 1's keycaps 8 pt under it upright and 6 pt turned; its words,
dividers and highlight centre 25 pt down; the highlight behind a pending
autocorrection fills its cell across, a 38 pt capsule from 6 pt down to the bar's
bottom; the dividers are 1 x 24 pt, hidden beside the highlight. So:
- upright the strip is 44 pt (was 38) with 8 pt under it: Hex grows 6 pt upward
  (rows stay on the same screen pixels) and its top edge is Apple's exactly:
  253 pt on a 17 Pro (was 247), 260 on an SE (254), 272 on an Air or Pro Max (266);
  on iOS 26 260 and 270 (254, 264)
- turned the strip is 44 pt (was 42) with 6 pt under it (was 8): same height
- the words sit 25 pt down (were 20 pt below a 6 pt lower edge), a pending word
  gets Apple's cell-wide bubble instead of an 18 pt chip around it, dividers are
  24 pt (were 18) and hide beside the bubble
- the Hex key takes a 59 pt cell at its end of the bar, as Apple's writing tools
  icon has at the other (TestFlight screenshot, iPhone 17 Pro Max, iOS 27.2.1),
  with a divider between it and the word beside it; the three cells share the
  rest (they were thirds of the bar with the Hex key's room cut from one). The
  key keeps its 44 x 28 pt mark, centred in its cell on the words' line, and its
  touch area now spans the whole cell across.
- the 17 pt band iOS sometimes adds above a third-party keyboard is not designed
  for: there Hex is 17 pt taller than Apple's. Height is one value per phone,
  orientation and iOS version.
- a view shorter than Hex asks for (Spotlight, #2280): the bar gives up its 6 pt
  over the old 38 pt strip first, so up to 6 pt short every key stays whole and in
  place; beyond that the rows shrink as before.
- iOS 18 (unmeasured) keeps the 38 pt strip and its numbers.
Replaces the 38 pt strip decision (PR #2256 era) and the small 18 pt chip. The
Duo, the iPad and the dictation bar keyboard (146 pt) are unchanged.

Code: KeyboardMetrics.appleBar, withAppleBar(turned:), appleBarIsMeasured
(systemMajorVersion >= 26), Apple's constants; stripTextCenter / stripPillHeight /
stripChipHeight follow it; fitted gives the bar's extra first; letterRows applies
it to the phone posture. KeyboardLayout: the Hex key's cell and centred mark,
slots as thirds of what the cell leaves. KeyboardStripView: cell-wide bubble,
dividers hidden beside it, divider beside the Hex key. The app's snapshot stage
gains bar states (revert, two cells, Paste, Paste dictation, Code from Messages,
selection) and --short-by.

Verified (Studio simulators): Hex's top edge equals Apple's to 0 pt upright on all
four phones on both iOS versions (turned 0 pt on 27.2, Hex 0.33 pt taller on 26.5),
key rows on the same screen pixels as origin/dev, the bubble at 6-44 pt as Apple's,
words 0.33 pt lower than Apple's. Real HID touches (17 Pro Max, 27.2): 9 points in
each cell pick that cell's word, the Hex key's cell never types; a sentence types
exactly upright and turned. Updated expected numbers in KeyboardLayoutTests (the
heights 247/254/266 -> 253/260/272, the strip 38/46/28 -> 44/52/38, Hex key x,
slot thirds, short views giving the bar first, iOS 18/25 keeping the old strip);
new cases for 6 pt short. xcodebuild test: all pass. code-shape passes.
2026-11-22 10:02:33 -05:00
..
Fixtures iOS: emoji panel with on-device suggestions (Experiments › Emoji) (#2051) 2026-11-20 15:53:24 +00:00
AutocorrectEngineTests.swift iOS: Hungarian keyboard with accent restoration and bilingual autocorrect (#2355) 2026-11-22 07:10:56 -05:00
CleanupTaggerTests.swift iOS keyboard: stale microphone errors clear, Hex key audio calls leave the main thread, counts read 1, 2, 3 (#2203) 2026-11-21 10:08:42 -05:00
CustomVocabularyTests.swift ios: custom vocabulary experiment (#1547) 2026-11-08 12:15:00 -05:00
DictationControllerTests.swift iOS: a working dictation is never taken away by a guess, and no speech model check sits forever (#2371) 2026-11-22 08:56:10 -05:00
DictationLanguageTests.swift iOS: dictate Latin American Spanish with Latin America's model, and keep a picked variant when the keyboard switches (#2193) 2026-11-21 09:53:34 -05:00
DictationLearningTests.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
DotScopeTests.swift fix(ios): eliminate handoff frame stalls and add overlapping ballistic swipe throw (t1153) (#757) 2026-10-31 22:14:22 -07:00
EmojiPanelLettersKeyTests.swift iOS dictation: no spaces or stray full stops around Chinese and Japanese; the bar's emoji panel says Back (#2347) 2026-11-22 03:47:53 -05:00
EmojiSuggesterTests.swift iOS keyboard: stop leaking views, capture web views, and emoji indices across shows (#2352) 2026-11-22 06:45:38 -05:00
FullKeyboardEngineTests.swift ios: add Dvorak punctuation keys experiment (#2373) 2026-11-22 09:31:25 -05:00
GreeklishRomanizerTests.swift iOS: add a Greeklish experiment for Greek dictation (#2366) 2026-11-22 08:51:48 -05:00
HangulComposerTests.swift iOS keyboard: Korean two-set (두벌식) layout with Hangul composition (experiment, off by default) (#2339) 2026-11-22 04:39:53 -05:00
HexKeyGestureTests.swift iOS: Undo dictation works after the cursor moves, and goes when it can't (#2240) 2026-11-21 15:15:23 -05:00
KeyboardBridgeTests.swift iOS: add a Greeklish experiment for Greek dictation (#2366) 2026-11-22 08:51:48 -05:00
KeyboardDuoCoverTests.swift ios: smaller key labels on the duo's cover screen (#2346) 2026-11-22 04:35:44 -05:00
KeyboardLayoutTests.swift iOS keyboard: the top bar is Apple's prediction bar, as thick as Apple's, with its bubble and dividers 2026-11-22 10:02:33 -05:00
KeyboardSwitchGuessTests.swift iOS: the dictation bar can start dictating by itself (Auto-start: never, on switch, always) (#2267) 2026-11-21 17:08:50 -05:00
KeyboardThemeTests.swift iOS keyboard: add a keyboard themes experiment (#2365) 2026-11-22 08:24:11 -05:00
LaggingField.swift iOS keyboard: Korean two-set (두벌식) layout with Hangul composition (experiment, off by default) (#2339) 2026-11-22 04:39:53 -05:00
LanguageLearningTests.swift ios: learn each language separately (experiment) (#2188) 2026-11-21 09:00:58 -05:00
ShiftStateMachineTests.swift ios: add Dvorak punctuation keys experiment (#2373) 2026-11-22 09:31:25 -05:00
SwipeDecoderTests.swift iOS: swipe reads the letters under the path, and the emoji bar scrubs (#2189) 2026-11-21 08:47:45 -05:00
TranscriptCleanupTests.swift iOS dictation: no spaces or stray full stops around Chinese and Japanese; the bar's emoji panel says Back (#2347) 2026-11-22 03:47:53 -05:00
TwoLanguageMergeTests.swift iOS: two-language dictation experiment (#2348) 2026-11-22 04:58:27 -05:00
TwoThumbSelectionTests.swift iOS: two-thumb selection on the space bar (experiment, off by default) (#2265) 2026-11-21 20:44:15 -05:00
TypingLogTests.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
TypingReplayTests.swift iOS keyboard: the typing replay reports all-words accuracy, contractions and taps read as swipes (#2287) 2026-11-21 20:32:00 -05:00