Skip to content

An old-fashioned keypad based input method (T9) for Vietnamese, support accents

Notifications You must be signed in to change notification settings

KentVu/vietnamese-t9-ime

Repository files navigation

vietnamese-t9-ime

Join the chat at https://gitter.im/KentVu/vietnamese-t9-ime Android CI Build Status Download

An old-fashioned keypad based input method (T9) for Vietnamese, support accents

The T9 input method

(From Wikipedia )

T9's objective is to make it easier to type text messages. It allows words to be entered by a single keypress for each letter, as opposed to the multi-tap approach used in conventional mobile phone text entry, in which several letters are associated with each key, and selecting one letter often requires multiple keypresses.

Specifications (Stories):

Definitions:

  • Program states: These are the program states:
    1. Inputting
    2. Confirmed
  • Candidates: ...
  • numSeq(keySeq): number sequence: the sequence of input keys' digit/char(?). (What should we call the Star/Sharp key?)
  • combination character:

Specs:

  1. User should interact mainly with the keypad (other means of interacting is optionally supported). (Keypad-centric accessibility: make use all the key on the keypad, prevent actions outside of the keypad (dialpad)).
  2. Uppercase should only occur at first letter of words.
  3. User should be able to select from a set of displayed candidates.
  4. When inputting, the possible candidates should be displayed.
  5. When confirm button is pressed, the selected candidate should be outputted.
    1. If no candidate is being selected then the first candidate will be used.
    2. If no candidates found, return the entered numSeq.
    3. The numSeq should be one of the candidates.
  6. If dawg has been built, use that dawg to minimize app start time.
  7. For Vietnamese:
    1. The output should NOT contain combining character, it should contains only rigid unicode character.

Basic Design:

The UI will follow the MVP design pattern:

  • Make the Activity implement the View interface
  • Presenter: Receive UI event, wiring action with the UI(View)
  • Model? - Everything else?

Design philosophy:

This project honor 7 virtues of good object by yegor256.

Things to consider

Why I chose dawg for implementation of trie?

Because it's the only implementation that support persisting (serializing), and fast!

TODO

  • Decompose accented character.
  • Implement number-to-word based on wordlist (saved in database).
  • Implement select candidate key.
  • Support suggestion
  • Flexibility via settings (accents right after character/accent at end of word)
  • Support add new word to dictionary
  • Flick input mode (for registering new word)
  • Frecency algorithm?

References-Acknowledgement

About

An old-fashioned keypad based input method (T9) for Vietnamese, support accents

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published