1RKBGNBUN(3) Library Functions Manual RKBGNBUN(3)
2
3
4
6 RkBgnBun / RkwBgnBun - convert the reading of a specified length to
7 kanji
8
10 #include <canna/RK.h>
11 int RkBgnBun(cxnum, yomi, maxyomi, mode)
12 int cxnum;
13 unsigned char *yomi;
14 int maxyomi;
15 int mode;
16 int RkwBgnBun(cxnum, yomi, maxyomi, mode)
17 int cxnum;
18 wchar_t *yomi;
19 int maxyomi;
20 int mode;
21
23 RkBgnBun converts the reading yomi with a length of maxyomi bytes to
24 kanji. The reading kana must be adjusted on character boundaries in
25 the EUC code. The context enters the conversion mode, with both the
26 current clause and the current clause set to 0.
27
28 RkwBgnBun is the similar function to RkBgnBun, but it takes wchar_t
29 argument as yomi. maxyomi represents the length of yomi by characters
30 instead of bytes.
31
32 mode represents the code conversion candidate to be added to each
33 clause. It is expressed in a bit field width, which can be set to one
34 of the following with RK_XFERBITS:
35
36 RK_XFER Hiragana
37
38 RK_HFER Single-width character
39
40 RK_KFER Katakana
41
42 RK_ZFER Double-width character
43
44 If the number of candidates available for the current clause is N, can‐
45 didates are added through code conversion by reading the candidates in
46 sequence, from candidate N to candidate N + 1, and so on, starting with
47 the lowest-order bit field. Candidate addition ends when the corre‐
48 sponding bit field equals 0.
49
50 mode Candidate
51 RK_XFER (KANJI) (HIRAGANA)
52 (RK_XFER << RK_XFERBITS) | RK_KFER(KANJI) (KATAKANA) (HIRAGANA)
53 (RK_KFER << RK_XFERBITS) | RK_XFER(KANJI) (HIRAGANA) (KATAKANA)
54
55 The context enters the conversion mode, from RkBgnBun to RkEndBun(3).
56 Conversion modes cannot be nested.
57
59 This function returns the number of clauses derived from conversion, or
60 returns -1 if the conversion fails.
61
63 RkEndBun[24m(3)
64
65
66
67 RKBGNBUN(3)