SciMath Keyboard

README

A custom iOS and iPadOS keyboard extension providing a full QWERTY layout plus three additional symbol layers: numbers and punctuation, extended operators, and scientific/mathematical characters.

© 2026 J. W. Bruce Shaw — SciMathKeyboard@gmail.comscimathkeyboard.com

Targets

TargetRole
ScientificKKeyboard extension (UIInputViewController subclass)
ScientificContaining app (ContentView.swift, SwiftUI)

Layers

LayerAccessContents
ABCDefaultQWERTY letters; diacriticals on long-press
123123 buttonNumbers, common punctuation; superscripts/subscripts on long-press digits
#+=#+= buttonBrackets, operators, currency
scisci button° ± × ÷ ≈ ≠ ≤ ≥ √ ∞   ∑ † ∫ ∂ ∇ Δ ℏ Å µ Ω   π ⊙ ∴ ∀ · ∝ ∈ ′ ⊥

Layer cycle: 123 → #+= → sci → 123. ABC button returns from any layer.

Key Features

Architecture Notes

iOS 26 Gesture Regression

Apple introduced a regression in iOS 26.x (May 2026) affecting UIPanGestureRecognizer in keyboard extensions — .began no longer fires on stationary contact, breaking balloon detection. Filed as FB19394663 / FB19405284, acknowledged by Apple.

Workaround: ImmediatePanGestureRecognizer subclass overrides touchesBegan to force state = .began on first contact. Fork began at v0.400. The workaround uses supported API and remains valid after Apple fixes the underlying bug.

class ImmediatePanGestureRecognizer: UIPanGestureRecognizer {
    override func touchesBegan(_ touches: Set<UITouch>,
                                with event: UIEvent) {
        super.touchesBegan(touches, with: event)
        state = .began
    }
}

Known Limitations

A Note on iOS Keyboard Geometry

Apple updated stock keyboard key appearance in iOS 18, rounding key shapes more aggressively and reducing effective tap target area. If users report missing keys more than expected, this is a known platform change — muscle memory calibrated to pre-iOS 18 geometry is a factor.

Privacy

SciMath does not request Full Access. It never logs keystrokes, never makes network requests, and contains no analytics or telemetry of any kind. Nothing typed ever leaves the device. The only local storage is the key flash preference. See privacy.html for the full policy.