Input method editor for the Japanese language
- The KKC of the ime is implemented in the separated file named kkc-engine installed at:
- fcitx:
/usr/lib/senn/fcitx/kkc-engine
. - ibus:
/usr/lib/senn/ibus/kkc-engine
.
- fcitx:
- When the ime is turned on, it starts kkc-engine and communcates with it using a pipe.
- kkc-engine can be replaced with any executable file as long as it satisfies the protocol described below to communication with the ime.
kkc-engine receives a request of a line from the standard input and sends a response of a line to the standard output. A line of the requests and responses is JSON encoded.
Each json form of requests is as follows:
{ "op": "<request op>", "args": "<request args>" }
The json form of a response depends on the request.
A Convert request is used to converts a sequence that the user inputs to a word sequence.
Request
op
: "CONVERT"args
:pron
:- A string of the sequence (typically hiragana)
Response
- array of objects: // An array of objects that describes a word sequence
pron
: // A substring of the input sequence for the wordcandidates
: array of objects:form
: // A string of kana and kanji for the word
A LIST_CANDIDATES request is used to list candidates for a pron.
Request
op
: "LIST_CANDIDATES"args
:pron
:
Response
- array of objects: // An array of objects that describes candidates
form
: // A string of kana and kanji