Mercurial > hg > xemacs-beta
comparison src/mule-canna.c @ 98:0d2f883870bc r20-1b1
Import from CVS: tag r20-1b1
author | cvs |
---|---|
date | Mon, 13 Aug 2007 09:13:56 +0200 |
parents | 1ce6082ce73f |
children | 8619ce7e4c50 |
comparison
equal
deleted
inserted
replaced
97:498bf5da1c90 | 98:0d2f883870bc |
---|---|
26 It would be ***soooo*** much nicer if someone could translate | 26 It would be ***soooo*** much nicer if someone could translate |
27 them ... */ | 27 them ... */ |
28 | 28 |
29 /* | 29 /* |
30 | 30 |
31 Authors: Akira Kon (kon@d1.bs2.mt.nec.co.jp) | 31 Authors: Akira Kon (we need a current email address) |
32 Ichiro Hirakura (hirakura@uxp.bs2.mt.nec.co.jp) | 32 Ichiro Hirakura (hirakura@uxp.bs2.mt.nec.co.jp) |
33 | 33 |
34 Functions defined in this file are | 34 Functions defined in this file are |
35 | 35 |
36 (canna-key-proc key) | 36 (canna-key-proc key) |
210 (ch)) | 210 (ch)) |
211 { | 211 { |
212 jrKanjiStatus ks; | 212 jrKanjiStatus ks; |
213 int len; | 213 int len; |
214 | 214 |
215 CHECK_CHAR (ch); | 215 CHECK_CHAR_COERCE_INT (ch); |
216 len = jrKanjiString (0, XCHAR (ch), buf, KEYTOSTRSIZE, &ks); | 216 len = jrKanjiString (0, XCHAR (ch), buf, KEYTOSTRSIZE, &ks); |
217 return storeResults (buf, len, &ks); | 217 return storeResults (buf, len, &ks); |
218 } | 218 } |
219 | 219 |
220 static Lisp_Object | 220 static Lisp_Object |
321 kugiri = NILP (num) ? 0 : 1; | 321 kugiri = NILP (num) ? 0 : 1; |
322 | 322 |
323 jrKanjiControl (0, KC_SETBUNSETSUKUGIRI, (char *) kugiri); | 323 jrKanjiControl (0, KC_SETBUNSETSUKUGIRI, (char *) kugiri); |
324 } | 324 } |
325 | 325 |
326 /* For whatever reason, calling Fding directly from libCanna loses */ | |
327 static void call_Fding() | |
328 { | |
329 extern Lisp_Object Fding(); | |
330 | |
331 (void)Fding(Qnil, Qnil, Qnil); | |
332 } | |
333 | |
326 DEFUN ("canna-initialize", Fcanna_initialize, 0, 3, 0, /* | 334 DEFUN ("canna-initialize", Fcanna_initialize, 0, 3, 0, /* |
327 Initialize ``canna'', which is a kana-to-kanji converter for GNU Emacs. | 335 Initialize ``canna'', which is a kana-to-kanji converter for GNU Emacs. |
328 The first arg specifies if inserting space character between BUNSETSU when | 336 The first arg specifies if inserting space character between BUNSETSU when |
329 candidates are displayed. | 337 candidates are displayed. |
330 The second arg specifies server. | 338 The second arg specifies server. |
409 /* イニシャライズで失敗した場合。 */ | 417 /* イニシャライズで失敗した場合。 */ |
410 return Fcons (Qnil, val); | 418 return Fcons (Qnil, val); |
411 } | 419 } |
412 else | 420 else |
413 { | 421 { |
414 extern (*jrBeepFunc)(); | 422 extern void (*jrBeepFunc)(); |
415 Lisp_Object Fding (), CANNA_mode_keys (); | 423 Lisp_Object CANNA_mode_keys (); |
416 | 424 |
417 jrBeepFunc = Fding; | 425 jrBeepFunc = call_Fding; |
418 | 426 |
419 #ifdef KC_SETAPPNAME | 427 #ifdef KC_SETAPPNAME |
420 #ifndef CANNA_MULE | 428 #ifndef CANNA_MULE |
421 wcKanjiControl (0, KC_SETAPPNAME, "nemacs"); | 429 wcKanjiControl (0, KC_SETAPPNAME, "nemacs"); |
422 #else /* CANNA_MULE */ | 430 #else /* CANNA_MULE */ |
821 DEFUN ("canna-henkan-kakutei", Fcanna_henkan_kakutei, 2, 2, 0, /* | 829 DEFUN ("canna-henkan-kakutei", Fcanna_henkan_kakutei, 2, 2, 0, /* |
822 候補選択。 | 830 候補選択。 |
823 */ | 831 */ |
824 (bun, kouho)) | 832 (bun, kouho)) |
825 { | 833 { |
834 int nbun, nkouho; | |
835 | |
826 if (confirmContext () == 0) | 836 if (confirmContext () == 0) |
827 { | 837 { |
828 return Qnil; | 838 return Qnil; |
829 } | 839 } |
830 RkGoTo (IRCP_context, bun); | 840 nbun = XINT(bun); |
831 RkXfer (IRCP_context, kouho); | 841 RkGoTo (IRCP_context, nbun); |
842 | |
843 nkouho = XINT(kouho); | |
844 RkXfer (IRCP_context, nkouho); | |
832 return Qt; | 845 return Qt; |
833 } | 846 } |
834 | 847 |
835 DEFUN ("canna-henkan-end", Fcanna_henkan_end, 0, 0, 0, /* | 848 DEFUN ("canna-henkan-end", Fcanna_henkan_end, 0, 0, 0, /* |
836 変換終了。 | 849 変換終了。 |