doc: screen coordinate reference (screen vs display vs app-local px)

The coordinate-space confusion (screen px 1080x2400 for input tap/
screencap, display px 900x2000 for reading PNGs, app-local px offset by
the 128px status bar, pt at density 2.625) cost real debugging time.
Wrote it down in doc/README.md as the permanent reference:

- the four spaces + conversions (display x1.2 = screen; screen Y-128 =
  app-local; /2.625 = pt)
- the practical tap rule: read (x,y) off the PNG, x1.2, input tap --
  screenshot px ARE screen px, no 128 offset for tap-what-you-see
- fixed geometry (status/nav bars, Gboard rows, editor region in pt),
  with re-measure guidance
- tap-test pitfalls (first-tap-swallowed, first input text can fail,
  wrong-place text = cursor/selection suspect not tap math, don't
  memorize drifting content positions)

All keyboard row values re-measured from a fresh screenshot and verified
live: tapping the Q key at (62, 1712) and backspace at (990, 2020) both
landed first try (file content confirmed). This also exposed that the
old notes had mixed display-px row values with screen-px key values in
the same list -- exactly the confusion this section eliminates.

Also fixed the stale Phase 6 'letterboxed window' note in
development_plan.md (window is full-screen; only the 128px status-bar
offset is real; content positions drift; the OpenFileChan logcat line
was removed) and pointed emu.sh's tap help at the x1.2 rule.
This commit is contained in:
gmp
2026-08-16 22:19:40 -04:00
parent b1a1719f17
commit ab60bb7f16
3 changed files with 66 additions and 13 deletions
+7 -3
View File
@@ -8,9 +8,13 @@
# scripts/emu.sh app start|stop|restart
# scripts/emu.sh shot [FILE] # screenshot (default /tmp/pad_shot_<ts>.png)
# scripts/emu.sh log [LINES] # last N lines of app logcat (default 20)
# scripts/emu.sh tap X Y # tap (note: the first tap right after
# # launch/open is sometimes swallowed —
# # re-tap if nothing happens)
# scripts/emu.sh tap X Y # tap at SCREEN px (1080x2400 space).
# # Tap-what-you-see rule: read (x,y) off
# # the PNG you are viewing and multiply
# # both by 1.2 (vision displays
# # screenshots at 900x2000). Note: the
# # first tap right after launch/open is
# # sometimes swallowed — re-tap.
# scripts/emu.sh type TEXT # type into the focused field (spaces ok)
# scripts/emu.sh cmd <top|bottom|frac F|dp N> # one-shot editor debug command
# scripts/emu.sh perf on|off # enable/disable the in-app profiler