1 ;;; lookup-vars.el --- Lookup variable list
2 ;; Copyright (C) 1999 Lookup Development Team <lookup@ring.gr.jp>
4 ;; Author: Keisuke Nishida <kei@psn.net>
5 ;; Version: $Id: lookup-vars.el.in,v 1.2 1999/05/23 17:27:21 knishida Exp $
7 ;; This file is part of Lookup.
9 ;; Lookup is free software; you can redistribute it and/or modify it
10 ;; under the terms of the GNU General Public License as published by
11 ;; the Free Software Foundation; either version 2 of the License, or
12 ;; (at your option) any later version.
14 ;; Lookup is distributed in the hope that it will be useful, but
15 ;; WITHOUT ANY WARRANTY; without even the implied warranty of
16 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 ;; GNU General Public License for more details.
19 ;; You should have received a copy of the GNU General Public License
20 ;; along with Lookup; if not, write to the Free Software Foundation,
21 ;; Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
27 (defconst lookup-version "@VERSION@"
28 "Lookup
\e$B$N%P!<%8%g%sHV9f!#
\e(B")
31 ;:: Customizable variables
35 "Search interface to electronic dictionaries."
38 (defgroup lookup-agents nil
44 (defgroup lookup-setup-variables nil
48 (defcustom lookup-init-file (concat "~" init-file-user "/.lookup")
49 "*Lookup
\e$B$N=i4|2=%U%!%$%kL>!#
\e(B
50 \e$B$3$N%U%!%$%k$O
\e(B lookup.el
\e$B$N%m!<%ID>8e$KFI$_9~$^$l$k!#
\e(B"
52 :group 'lookup-setup-variables)
54 (defcustom lookup-data-directory "@pkgemacsdir@"
55 "*Lookup
\e$B$K4X$9$k%W%m%0%i%`0J30$N%G!<%?$,<}$a$i$l$k%G%#%l%/%H%j!#
\e(B"
57 :group 'lookup-setup-variables)
59 (defcustom lookup-search-agents nil
60 "*
\e$B8!:w%(!<%8%'%s%H$N@_Dj$N%j%9%H!#
\e(B
61 \e$B%j%9%H$N3FMWAG$O<!$N7A<0$r<h$k
\e(B:
63 (CLASS LOCATION [KEY1 VALUE1 [KEY2 VALUE2 [...]]])
65 CLASS
\e$B$K$O!"%(!<%8%'%s%H$N<oN`$r%7%s%\%k$G;XDj$9$k!#
\e(B
66 LOCATION
\e$B$K$O!"%(!<%8%'%s%H$N=j:_$rJ8;zNs$G;XDj$9$k!#
\e(B
67 KEY
\e$B5Z$S
\e(B VALUE
\e$B$O>JN,2DG=$G!"%(!<%8%'%s%H$KBP$9$k%*%W%7%g%s$r;XDj$9$k!#
\e(B
69 \e$BNc
\e(B: (setq lookup-search-agents
70 '((ndtp \"dserver\" :port 2010)
71 (ndeb \"/cdrom\" :enable (\"EIWA\")))))"
72 :type '(repeat (sexp :tag "agent")) ; type
\e$B$O$A$g$C$H$d$d$3$7$9$.!&!&
\e(B
73 :group 'lookup-setup-variables)
75 (defcustom lookup-search-modules nil
76 "*
\e$B8!:w%b%8%e!<%k$N@_Dj$N%j%9%H!#
\e(B"
77 :type '(repeat (cons :tag "Module" (string :tag "name")
78 (repeat :tag "Dictionary" (string :tag "ID"))))
79 :group 'lookup-setup-variables)
81 (defcustom lookup-default-agent-options nil
82 "*
\e$B8!:w%(!<%8%'%s%H$K%G%U%)%k%H$GM?$($k%*%W%7%g%s$N%j%9%H!#
\e(B
83 \e$B3F%*%W%7%g%s$O!"%?%0$H$J$k%7%s%\%k$H!"CM$H$J$kG$0U$N%*%V%8%'%/%H$H$N
\e(B
84 cons
\e$B$K$h$C$FI=$o$9!#
\e(B"
85 :type '(repeat (cons :tag "option" (symbol :tag "tag") (sexp :tag "value")))
86 :group 'lookup-setup-variables)
88 (defcustom lookup-agent-options-alist nil
89 "*
\e$B8!:w%(!<%8%'%s%H$N%*%W%7%g%s$r@_Dj$9$kO"A[%j%9%H!#
\e(B
90 \e$B3FMWAG$N
\e(B car
\e$B$K$O%(!<%8%'%s%H
\e(BID(\"CLASS+LOCATION\")
\e$B$r;XDj$7!"
\e(B
91 cdr
\e$B$K$O%*%W%7%g%s$N%j%9%H$r;XDj$9$k!#
\e(B"
92 :type '(repeat (cons :tag "Agent"
94 (repeat :tag "options" (cons :tag "option"
96 (sexp :tag "value")))))
97 :group 'lookup-setup-variables)
99 (defcustom lookup-default-dictionary-options nil
100 "*
\e$B<-=q$K%G%U%)%k%H$GM?$($k%*%W%7%g%s$N%j%9%H!#
\e(B
101 \e$B3F%*%W%7%g%s$O!"%?%0$H$J$k%7%s%\%k$H!"CM$H$J$kG$0U$N%*%V%8%'%/%H$H$N
\e(B
102 cons
\e$B$K$h$C$FI=$o$9!#
\e(B"
103 :type '(repeat (cons :tag "option" (symbol :tag "tag") (sexp :tag "value")))
104 :group 'lookup-setup-variables)
106 (defcustom lookup-dictionary-options-alist nil
107 "*
\e$B<-=q$N%*%W%7%g%s$r@_Dj$9$kO"A[%j%9%H!#
\e(B
108 \e$B3FMWAG$N
\e(B car
\e$B$K$O<-=q
\e(BID(\"CLASS+LOCATION:NAME\")
\e$B$r;XDj$7!"
\e(B
109 cdr
\e$B$K$O%*%W%7%g%s$N%j%9%H$r;XDj$9$k!#
\e(B"
110 :type '(repeat (cons :tag "Dictionary"
112 (repeat :tag "options" (cons :tag "option"
114 (sexp :tag "value")))))
115 :group 'lookup-setup-variables)
119 (defgroup lookup-general-options nil
120 "General customizable variables."
123 (defcustom lookup-default-method 'exact
124 "*\\[lookup-pattern]
\e$B$G<B9T$5$l$kI8=`$N8!:wJ}<0!#
\e(B
125 \e$BJQ?t
\e(B `lookup-word-search-methods'
\e$B$N$$$:$l$+$NCM$r;XDj2DG=!#
\e(B"
127 :group 'lookup-general-options)
129 (defcustom lookup-frame-alist
130 '((title . "Lookup") (menu-bar-lines . 0) (width . 48) (height . 32)
131 (lookup-fill-column . 45))
132 "*Lookup
\e$B@lMQ%U%l!<%`$N%Q%i%a!<%?$N%j%9%H!#
\e(B
133 \e$B@_Dj$9$Y$-CM$K$D$$$F$O!"
\e(B`default-frame-alist'
\e$B$r;2>H!#
\e(B"
134 :type '(repeat (cons :tag "Parameter"
136 (sexp :tag "value")))
137 :group 'lookup-general-options)
139 (defcustom lookup-fill-column .9
140 "*
\e$B%(%s%H%jFbMF$r
\e(B fill
\e$B$9$k$H$-$N7e?t!#
\e(B
141 \e$B>.?t$r;XDj$7$?>l9g$O!"%&%#%s%I%&$NI}$KBP$9$k3d9g$H$7$FMQ$$$i$l$k!#
\e(B"
143 :group 'lookup-general-options)
145 (defcustom lookup-window-height 4
146 "*Entry
\e$B%P%C%U%!Ey$N%&%#%s%I%&$N9b$5!#
\e(B
147 \e$B>.?t$r;XDj$7$?>l9g$O!"
\e(BLookup
\e$BA4BN$N%&%#%s%I%&$N9b$5$KBP$9$k3d9g$H$7$F
\e(B
148 \e$BMQ$$$i$l$k!#
\e(B"
150 :group 'lookup-general-options)
152 (make-variable-frame-local 'lookup-fill-column)
153 (make-variable-frame-local 'lookup-window-height)
155 (defcustom lookup-save-configuration t
156 "*Non-nil
\e$B$r;XDj$9$k$H!"
\e(BLookup
\e$B$rH4$1$?$H$-$K%&%#%s%I%&>uBV$r2sI|$9$k!#
\e(B"
158 :group 'lookup-general-options)
160 (defcustom lookup-use-bitmap (featurep 'bitmap)
161 "*Non-nil
\e$B$r;XDj$9$k$H!"
\e(Bbitmap-mule
\e$B%Q%C%1!<%8$rMxMQ$7$?30;zI=<($r9T$J$&!#
\e(B"
163 :group 'lookup-general-options)
165 (defcustom lookup-use-kakasi nil
166 "*Non-nil
\e$B$r;XDj$9$k$H!"$$$/$D$+$N6ILL$G
\e(B KAKASI
\e$B$,MxMQ$5$l$k!#
\e(B
167 \e$B$3$l$O8=:_!"6qBNE*$K$OF|K\8l$N%G%U%)%k%H$N8!:w8l$N@Z$j=P$7$KMQ$$$F$$$k!#
\e(B"
169 :group 'lookup-general-options)
171 (defcustom lookup-enable-gaiji t
172 "*Non-nil
\e$B$r;XDj$9$k$H!"30;zI=<($,M-8z$H$J$k!#
\e(B"
174 :group 'lookup-general-options)
176 (defcustom lookup-max-hits 50
177 "*
\e$B8!:w;~$KI=<($9$k%(%s%H%j$N:GBg?t!#
\e(B
178 0
\e$B$r;XDj$9$k$H!"8+$D$+$C$?A4$F$N%(%s%H%j$rI=<($9$k!#
\e(B"
180 :group 'lookup-general-options)
182 (defcustom lookup-max-text 10000
183 "*
\e$B8!:w;~$KI=<($9$k%(%s%H%jK\J8$N:GBgD9!#
\e(B
184 0
\e$B$r;XDj$9$k$H!"A4J8$rI=<($9$k!#
\e(B"
186 :group 'lookup-general-options)
188 (defcustom lookup-cite-header nil
189 "*
\e$B%(%s%H%jK\J8$r0zMQ$9$k$H$-$N%X%C%@!#
\e(B
190 \e$B%3%^%s%I
\e(B `lookup-entry-cite-content'
\e$B5Z$S
\e(B `lookup-content-cite-region'
191 \e$B$K$h$jFbMF$r<h$j9~$`$H$-!"$=$N@hF,$K;XDj$7$?J8;zNs$,IU$12C$($i$l$k!#
\e(B
192 \e$BJ8;zNs$,
\e(B \"%T\"
\e$B$r4^$`>l9g!"<-=q$N%?%$%H%k$KCV$-49$($i$l$k!#
\e(B
193 \e$B<-=q%*%W%7%g%s
\e(B `cite-header'
\e$B$,;XDj$5$l$F$$$k>l9g!"$=$A$i$,M%@h$5$l$k!#
\e(B"
195 :group 'lookup-general-options)
197 (defcustom lookup-cite-prefix nil
198 "*
\e$B%(%s%H%jK\J8$r0zMQ$9$k$H$-$N%W%l%U%#%/%9!#
\e(B
199 \e$B%3%^%s%I
\e(B `lookup-entry-cite-content'
\e$B5Z$S
\e(B `lookup-content-cite-region'
200 \e$B$K$h$jFbMF$r<h$j9~$`$H$-!"3F9T$N@hF,$K;XDj$7$?J8;zNs$,IU$12C$($i$l$k!#
\e(B
201 \e$B<-=q%*%W%7%g%s
\e(B `cite-preifx'
\e$B$,;XDj$5$l$F$$$k>l9g!"$=$A$i$,M%@h$5$l$k!#
\e(B"
203 :group 'lookup-general-options)
205 (defcustom lookup-gaiji-alternate "_"
206 "*
\e$B30;z$NBeBXJ8;zNs$H$7$FMQ$$$i$l$k%G%U%)%k%H$NJ8;zNs!#
\e(B"
208 :group 'lookup-general-options)
210 (defcustom lookup-process-coding-system
211 (when (featurep 'evi-mule)
212 (if (memq system-type '(ms-dos windows-nt OS/2 emx))
213 (evi-coding-system 'sjis)
214 (evi-coding-system 'euc-jp)))
215 "*
\e$B30It%W%m%;%9$H$N%G%U%)%k%H$NJ8;z%3!<%I!#
\e(B"
217 :group 'lookup-general-options)
219 (defcustom lookup-kakasi-coding-system lookup-process-coding-system
220 "*KAKASI
\e$B$N8F$S=P$7$KMQ$$$kJ8;z%3!<%I!#
\e(B"
222 :group 'lookup-general-options)
226 (defgroup lookup-faces nil
230 (defface lookup-heading-1-face
231 '((t (:bold t :foreground "SlateBlue")))
232 "Level 1 heading face."
233 :group 'lookup-faces)
235 (defface lookup-heading-2-face
236 '((t (:bold t :foreground "Red")))
237 "Level 2 heading face."
238 :group 'lookup-faces)
240 (defface lookup-heading-3-face
241 '((t (:bold t :foreground "Orange")))
242 "Level 3 heading face."
243 :group 'lookup-faces)
245 (defface lookup-heading-4-face
247 "Level 4 heading face."
248 :group 'lookup-faces)
250 (defface lookup-heading-5-face
252 "Level 5 heading face."
253 :group 'lookup-faces)
255 (defface lookup-heading-low-face
256 '((t (:foreground "Grey")))
257 "Low level heading face."
258 :group 'lookup-faces)
260 (defface lookup-reference-face
261 '((t (:underline t :foreground "Blue")))
262 "Face used to highlight reference."
263 :group 'lookup-faces)
265 (defface lookup-refered-face
266 '((t (:underline t :foreground "DarkViolet")))
267 "Face used to highlight refered reference."
268 :group 'lookup-faces)
274 (defvar lookup-search-method nil
275 "
\e$B8!:wJ}<0$r;XDj$9$k$H!"F~NO$r%Q!<%9$;$:$=$l$r$=$N$^$^MQ$$$k!#
\e(B")
277 (defvar lookup-enable-format t
278 "Non-nil
\e$B$r;XDj$9$k$H!"%F%-%9%H$r@07A$7$F=PNO$9$k!#
\e(B")
280 (defvar lookup-force-update nil
281 "Non-nil
\e$B$r;XDj$9$k$H!"%-%c%C%7%e$rMQ$$$:6/@)E*$K:F8!:w$r9T$J$&!#
\e(B")
283 (defvar lookup-open-function 'lookup-other-window
284 "Lookup
\e$B$N%&%#%s%I%&$rI=<($9$k$?$a$NI8=`$N4X?t!#
\e(B
285 \e$B<!$N;0$D$N$$$:$l$+$r;XDj2DG=!#
\e(B
287 `lookup-full-screen' -
\e$B8!:w7k2L$r2hLLA4BN$GI=<($9$k
\e(B
288 `lookup-other-window' -
\e$B8!:w7k2L$rJL$N%&%#%s%I%&$GI=<($9$k
\e(B
289 `lookup-other-frame' -
\e$B8!:w7k2L$rJL$N%U%l!<%`$GI=<($9$k
\e(B")
295 (defvar lookup-load-hook nil
296 "*Lookup
\e$B$N%m!<%I40N;D>8e$K<B9T$5$l$k
\e(B hook
\e$B!#
\e(B
297 `lookup-init-file'
\e$B$NFI$_9~$_D>8e$K<B9T$5$l$k!#
\e(B")
303 ;; Lookup
\e$B$r%G%P%C%0$KE,$7$?7A$G<B9T$9$k$K$O!"JQ?t
\e(B `lookup-debug-mode'
\e$B$r
\e(B
304 ;; non-nil
\e$B$K@_Dj$9$k!#$3$N>l9g!"<!$N5!G=$,F/$/!#
\e(B
306 ;; *
\e$B%W%m%;%9$N<B9T2aDx$,%P%C%U%!$KJ]B8$5$l$k!#Nc$($P
\e(B ndtp
\e$B$N>l9g!"A4$F$N
\e(B
307 ;;
\e$B$d$j$H$j$,%P%C%U%!
\e(B " *ndtp*"
\e$B$K5-O?$5$l$k!#
\e(B
309 ;; *
\e$B3F<o%G!<%?9=B$$NB0@-%j%9%H$NI=<($,M^@)$5$l$k!#$3$l$K$h$j!"JQ?t$NCM$N
\e(B
310 ;;
\e$B=PNO$,M^$($i$l!">pJs$,8+$d$9$/$J$k!#
\e(B`lookup-new-plist'
\e$B$r;2>H!#$3$l$r
\e(B
311 ;;
\e$BM-8z$H$9$k$K$O
\e(B `lookup-debug-mode'
\e$B$r
\e(B ~/.emacs
\e$B$G@_Dj$7$J$1$l$P$J$i$J$$!#
\e(B
313 (defvar lookup-debug-mode nil)
316 ;:: Internal variables
319 (defvar lookup-agent-list nil)
320 (defvar lookup-agent-alist nil)
321 (defvar lookup-module-list nil)
322 (defvar lookup-module-alist nil)
323 (defvar lookup-dictionary-alist nil)
325 (defvar lookup-default-module nil)
326 (defvar lookup-current-session nil)
327 (defvar lookup-last-session nil)
329 (defvar lookup-buffer-list nil)
330 (defvar lookup-search-pattern nil)
331 (defvar lookup-search-found nil)
332 (defvar lookup-dynamic-display nil)
333 (defvar lookup-proceeding-message nil)
334 (defvar lookup-window-configuration nil)
335 (defvar lookup-byte-compile nil)
337 (defvar lookup-gaiji-compose-function nil)
338 (defvar lookup-gaiji-paste-function nil)
340 (defun lookup-init-gaiji-functions ()
341 (cond ((featurep 'xemacs)
342 (setq lookup-gaiji-compose-function 'lookup-glyph-compose
343 lookup-gaiji-paste-function 'lookup-glyph-paste))
345 (setq lookup-gaiji-compose-function 'lookup-bitmap-compose
346 lookup-gaiji-paste-function 'lookup-bitmap-paste))
348 (setq lookup-gaiji-compose-function nil
349 lookup-gaiji-paste-function 'lookup-bitmap-paste))))
351 (provide 'lookup-vars)
353 ;;; lookup-vars.el ends here