Input method in FreeBSD virtual terminal (Week7)

Date: 07/19-07/25

Progress

At the beginning of this week I did some experiments with vt_processkey() and terminal_input_char(), such as a function that recieves a key and echos back.

After figuring out the usage of the two functions, I hijacked vt_processkey() function and use right CTRL key to toggle the rime mode. If the rime mode is enabled, the key will be passed into the custom function called vt_rime_process_char() to send the key to the rime server.

Now, the most important problem is how to communicate with the rime server. I list some requirements for implementation:

Requirements

  1. The kernel need to send character to the Rime server in user space when receiving keyboard events.
  2. The Rime server replies CJK characters. Additionally, word candidates and preedit string.
  3. The kernel output the characters to where the cursor is and display candidates and preedit string.

Another issue is the default VT font does not contain Chinese characters, so I am unable to insert/display CJK characters on the screen. Fortunately, my mentor LiWenHsu told me there is a usable font that supports CJK chars in fontstuff repo.

Todos

SummerOfCode2021Projects/InputMethodInFreeBSDVirtualTerminal/Week7 (last edited 2021-07-31T07:11:14+0000 by FanChung)