Skip to content

Input Method Editor Scanning

Eric Wan edited this page May 7, 2013 · 7 revisions

In addition to Tecla's HUD control for general navigation of GUI on Android devices, the user requires a method to input text and/or inject keyboard events. A Tecla switch-activated keyboard, thus, needs to be implemented in this project. Similar to the existing Tecla Access app, a scan-based keyboard will be implemented and made accessible from the HUD control.

Features

The following features have been implemented on the current design of the keyboard:

  • single-switch scanning
  • automatic scanning for single-switch access
  • word prediction scanning

The following features will be built on the current keyboard design:

  • multiple-switch access
  • automatic scanning for multiple switches
  • switch configuration capability

Keyboard Classes

All Tecla keyboard-related classes were written in the com.android.tecla.keyboard package.

IMEAdapter

This class exposes methods for scan and selection of keys. It enables IME scanning with Latin IME.

Scanning will be triggered programmatically within the framework either by a switch event, timer or by a convenience function or macro designed for a specific purpose. Regardless of the source, the scanning code needs to expose the following (public) methods for control of the scan:

  1. scanNext()
  2. scanPrevious()
  3. selectHighlighted(): Goes into 2nd-level scanning (i.e., key or word) or emulates a key event depending on the state of the scan.
  4. stepOut(): Cancels 2nd-level scanning (i.e., key or word) and resets highlight to the current 1st-level (i.e., keyboard row or word prediction)
  5. scanUp(): Moves highlight to the element immediately above the one currently highlighted (key or word)
  6. scanDown(): Moves highlight to the element immediately below the one currently highlighted (key or word)

These four method should be sufficient for access and control of the scanning with any number of switches.

TeclaIME

This class is an input method service extended from Latin IME. Methods are written in this class to gain access to word prediction and keyboard

AutomaticScan

Automatic scanning is implemented here.

WordPredictionAdapter

This class exposes methods for scan and selection of predicted words. It enables word prediction scanning using the existing word prediction classes (i.e. SuggestionsView and MoreSuggestionsView).

TeclaAccessibilityService

This class is used as a highlighting aid for navigation of views.

TeclaApp

This is the main application class, written to control the loading sequence of the components.

TeclaHUDOverlay

This class controls the scanning and selection of navigation.

Clone this wiki locally