Mercurial > hg > xemacs-beta
annotate lisp/mule/canna-leim.el @ 5408:9fc91aa3a927
Converted tooltalk to GPLv3 according to GPLv3 source survey analysis.
author | Mats Lidell <matsl@xemacs.org> |
---|---|
date | Tue, 19 Oct 2010 23:34:53 +0200 |
parents | 91b3aa59f49b |
children | b9167d522a9a |
rev | line source |
---|---|
502 | 1 ;;; canna-leim.el --- Canna-related code for LEIM -*- coding: iso-2022-7bit; -*- |
333 | 2 ;; Copyright (C) 1997 Stephen Turnbull <turnbull@sk.tsukuba.ac.jp> |
3 ;; Copyright (C) 1997 Free Software Foundation, Inc. | |
4 ;; | |
5 ;; Shamelessly ripped off from | |
6 ;; | |
7 ;; skk-leim.el --- SKK related code for LEIM | |
8 ;; Copyright (C) 1997 | |
9 ;; Murata Shuuichirou <mrt@mickey.ai.kyutech.ac.jp> | |
10 ;; | |
11 ;; Author: Stephen Turnbull <turnbull@sk.tsukuba.ac.jp> | |
12 ;; Version: canna-leim.el,v 1.2 1997/10/27 10:08:49 steve Exp | |
13 ;; Keywords: japanese, input method, LEIM | |
14 ;; Last Modified: 1997/10/27 10:08:49 | |
15 | |
5404
91b3aa59f49b
Convert lisp/ to GPLv3.
Mike Sperber <sperber@deinprogramm.de>
parents:
3824
diff
changeset
|
16 ;; XEmacs is free software: you can redistribute it and/or modify it |
91b3aa59f49b
Convert lisp/ to GPLv3.
Mike Sperber <sperber@deinprogramm.de>
parents:
3824
diff
changeset
|
17 ;; under the terms of the GNU General Public License as published by the |
91b3aa59f49b
Convert lisp/ to GPLv3.
Mike Sperber <sperber@deinprogramm.de>
parents:
3824
diff
changeset
|
18 ;; Free Software Foundation, either version 3 of the License, or (at your |
91b3aa59f49b
Convert lisp/ to GPLv3.
Mike Sperber <sperber@deinprogramm.de>
parents:
3824
diff
changeset
|
19 ;; option) any later version. |
333 | 20 |
5404
91b3aa59f49b
Convert lisp/ to GPLv3.
Mike Sperber <sperber@deinprogramm.de>
parents:
3824
diff
changeset
|
21 ;; XEmacs is distributed in the hope that it will be useful, but WITHOUT |
91b3aa59f49b
Convert lisp/ to GPLv3.
Mike Sperber <sperber@deinprogramm.de>
parents:
3824
diff
changeset
|
22 ;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
91b3aa59f49b
Convert lisp/ to GPLv3.
Mike Sperber <sperber@deinprogramm.de>
parents:
3824
diff
changeset
|
23 ;; FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
91b3aa59f49b
Convert lisp/ to GPLv3.
Mike Sperber <sperber@deinprogramm.de>
parents:
3824
diff
changeset
|
24 ;; for more details. |
333 | 25 |
26 ;; You should have received a copy of the GNU General Public License | |
5404
91b3aa59f49b
Convert lisp/ to GPLv3.
Mike Sperber <sperber@deinprogramm.de>
parents:
3824
diff
changeset
|
27 ;; along with XEmacs. If not, see <http://www.gnu.org/licenses/>. |
333 | 28 |
29 ;;; TODO | |
30 ;; | |
31 ;; Add pointers to Canna documentation in LEIM format | |
32 | |
778 | 33 (globally-declare-boundp 'canna:*japanese-mode*) |
34 (globally-declare-fboundp '(canna canna-toggle-japanese-mode)) | |
35 | |
3824 | 36 ;; use (locate-file "canna_api" module-load-path module-extensions) |
2973 | 37 ;; to locate the module without loading it. |
38 ;; then we could autoload canna-activate and dump and/or autoload: | |
3824 | 39 ;; (and (locate-file "canna_api" module-load-path module-extensions) |
2973 | 40 ;; (locate-library "canna") |
41 ;; (register-input-method 'japanese-canna "Japanese" 'canna-activate nil | |
42 ;; "Canna - a kana to kanji conversion program")) | |
43 | |
333 | 44 (defun canna-activate (&optional name) |
2973 | 45 ;; XEmacs 21.5.10 and later have 3-argument require. |
3824 | 46 (unless (require 'CANNA "canna_api" 'no-error) |
2973 | 47 (error 'file-error |
48 "No Canna API support!? See M-x describe-installation & C-h v module-load-path.")) | |
49 (unless (require 'canna nil 'no-error) | |
50 (error 'file-error | |
51 "Canna LISP support not found. Is the mule-base package missing?")) | |
333 | 52 (setq inactivate-current-input-method-function 'canna-inactivate) |
53 (unless (featurep 'leim-canna-initialized) | |
54 (canna) | |
55 (provide 'leim-canna-initialized)) | |
56 (canna-toggle-japanese-mode)) | |
57 | |
58 (defun canna-inactivate () | |
778 | 59 (cond (canna:*japanese-mode* (canna-toggle-japanese-mode)))) |
333 | 60 |
61 (register-input-method | |
62 'japanese-canna "Japanese" | |
63 'canna-activate nil | |
64 "Canna - a kana to kanji conversion program" ) | |
65 | |
66 (provide 'canna-leim) | |
67 | |
68 ;;; canna-leim.el ends here |