Improve user experience with Chinese IME (IBus)

This change implements the FieldWorks side of some changes in
Palaso that:
- fix the behavior for arrow, page up/down, home, end, backspace and
  enter keys (FWNX-1326)
- fix backspace so that it deletes last typed character in
  preedit window instead of closing preedit window (FWNX-1324)

Change-Id: Ia69487ecef6df8725a6f8100e9cb13cbda897df4