;ELC ;;; compiled by jwz@thalidomide on Tue Mar 29 02:01:22 1994 ;;; from file /th/jwz/emacs19/lisp/packages/webster.el ;;; emacs version 19.10 Lucid (beta10). ;;; bytecomp version 2.22; 22-dec-93. ;;; optimization is on. ;;; this file uses opcodes which do not exist in Emacs 18. (if (and (boundp 'emacs-version) (or (and (boundp 'epoch::version) epoch::version) (string-lessp emacs-version "19"))) (error "This file was compiled for Emacs 19.")) (defvar webster-host "agate.berkeley.edu" "\ The host to use as a webster server.") (defvar webster-port "2627" "\ The port to connect to. Either 103 or 2627") (defvar webster-process nil "\ The current webster process") (defvar webster-process-name "webster" "\ The current webster process") (defvar webster-buffer nil "\ The current webster process") (defvar webster-running nil "\ Used to determine when connection is established") (fset 'webster-initial-filter #[(proc string) "p qdb !=! \"!!! \"\"q)" [this-buffer webster-buffer process-status webster-process run t webster-running message "Webster died" string-match "No such host" string kill-buffer process-buffer proc error "No such host." "]" set-process-filter webster-filter] 3]) (defvar webster-reformat t "\ *Set this to t if you want the webster output to be prettied up, and for the \\[webster] prompt to do completion across the set of words known to be in the dictionary (words you've looked up, or which appeared in definitions as crossreferences.)") (byte-code "M\"M" [webster-filter #[(proc string) "p q !=! \"!!#b! \"c \"c \" \" ZOP\"db)db` c`$)!!` ! &'(!!''!db'!S!&!**" [nil endp this-buffer webster-buffer process-status webster-process run message "Webster died" string-match "Connection closed" string "Closing webster connection..." kill-process proc replace-regexp "Process webster killed" "" 1 "Closing webster connection...Done." "SPELLING 0" "...Word not found in webster\n" "SPELLING 1" "...Spelled correctly\n" "" "" end-def-message webster-filter 0 "\n\n" t now delete-char-in-region " " " " process-mark get-buffer-window selected-window window webster-window webster-reformat select-window recenter window-height] 7] make-vector 511 0 webster-completion-table webster-intern #[(string) "\n\"\nÉO\nÕOPl\n\"" [string-match "\\." string 0 nil intern webster-completion-table] 4]] 3) (defvar webster-fontify (string-match "Lucid" emacs-version) "\ *Set to t to use the Lucid GNU Emacs font-change mechanism.") (byte-code "!!!!\"!!!\"!!!\"!!!\"!!!\"M" [fboundp make-face find-face webster face-differs-from-default-p copy-face default webster-bold bold webster-italic italic webster-bold-italic bold-italic webster-small webster-fontify #[(start end face &optional highlight) " \np# \" #)" [make-extent start end e set-extent-face face highlight set-extent-property t] 4]] 3) (fset 'webster-reformat #[(end) "?? b#!!ɔɕ$)!!y`#`}b#! pbm!Ԕԕ|!`ԕ#ԕb!ԕSbc)!`ԕS{!`ԕS$ԕSb!*y%! hU㪁cwNJy`)`#`!ɔɕ{'Ԕԕ|c'GZj'NJy`)`#)`!ɔɕ{ϔϕ{,',횬'Ԕԕ|c'GZj',NJy`)`#*`!ɔɕ{ϔϕ{{2,'2󚬃,,횬'Ԕԕ|c'GZj',2NJy`)`#+`!`ԕb!i9Vbcj!``#`! cju`hU! c`ʁ@!`ԕ|c cʁA!```\\#ԕbBc``CwʁD!ʁE!`ԕ{F`ԕ$GHF\"FԉOFԕOPFdF!)Iwi9V`bc jwIw`*eb!!udbc~)" [webster-reformat end nil case-fold-search re-search-backward "^[A-Z]+" t webster-fontify previous-line 1 looking-at "^DEFINE \\([^ \n]+\\)" webster-bold "^DEFINITION [0-9]" "^SPELLING" 2 indent p search-forward "\n\n" 0 "\n" delete-char -1 just-one-space " *\n" "^[0-9]+ " webster-bold-italic "[^\n0-9]+ [0-9]" "[a-z]+\\( [a-z]+\\)*[ \n]" webster-intern " *[0-9]+\\. " 5 delete-horizontal-space 10 " " "\n " "0-9. " " *\\([0-9]+\\): *" n 6 " : " 9 " *\\([0-9]+\\)\\([a-z]+\\): *" m "a" " " 12 " *\\([0-9]+\\)\\([a-z]+\\)\\([0-9]+\\): *" 3 o "1" "(" ") : " 17 " *\\\\" "\\" fill-column 18 webster-italic " *\\[" 93 " *:" "\n " " *SYN *" "syn " "see " " ,:;-" "\\([A-Z][-A-Z]+[A-Z]\\)\\( [A-Z][-A-Z]*[A-Z]\\)*" "[a-z][-a-z]*\\(\\.[a-z][-a-z]*\\)+" s string-match "\\." "^ \\"] 5 "\ Clean up the output of the webster server, and gather words for the completion table."]) (fset 'delete-char-in-region #[(start end char1 char2) "b H #!`Zf Um!g" [start char2 0 search-forward char1 end t delete-char -1 1] 4]) (fset 'webster #[(arg) " \"" [arg "" current-word webster-send-request "DEFINE"] 3 "\ Look up a word in the Webster's dictionary. Open a network login connection to a webster host if necessary. Communication with host is recorded in a buffer *webster*." (byte-code " Q ɉ$ !*C" ["Look up word in webster (" current-word "): " t completion-ignore-case prompt webster-reformat completing-read webster-completion-table nil read-string] 5)]) (fset 'webster-endings #[(arg) " \"" [arg "" current-word webster-send-request "ENDINGS"] 3 "\ Look up endings for a word in the Webster's dictionary. Open a network login connection to a webster host if necessary. Communication with host is recorded in a buffer *webster*." (byte-code " Q!C" [read-string "Find endings for word in webster (" current-word "): "] 4)]) (fset 'webster-spell #[(arg) " \"" [arg "" current-word webster-send-request "SPELL"] 3 "\ Look spelling for a word in the Webster's dictionary. Open a network login connection to a webster host if necessary. Communication with host is recorded in a buffer *webster*." (byte-code " Q!C" [read-string "Try to spell word in webster (" current-word "): "] 4)]) (fset 'webster-send-request #[(kind word) "! ư  != Q!!\"\"pq q)!  \" \" w\" R\")" [require shell "open " webster-host " " webster-port "\n" webster-command webster-buffer webster-process process-status run message "Attempting to connect to server " "..." fboundp make-shell make-comint webster-process-name "telnet" this-buffer webster-mode get-process set-process-filter webster-initial-filter process-send-string nil webster-running accept-process-output display-buffer kind word] 6]) (fset 'webster-quit #[nil "\n\" !\n\" " [message "Closing connection to %s..." webster-host kill-process webster-process "Closing connection to %s...done" bury-buffer] 3 "\ Close connection and quit webster-mode. Buffer is not deleted." nil]) (byte-code "!‡" [boundp webster-mode-map nil] 2) (fset 'webster-mode #[nil " !!" [kill-all-local-variables webster-mode major-mode "Webster" mode-name use-local-map webster-mode-map run-hooks webster-mode-hook] 2 "\ Major mode for interacting with on-line Webster's dictionary. \\{webster-mode-map} Use webster-mode-hook for customization." nil]) (byte-code " #####\"#" [webster-mode-map make-sparse-keymap define-key "?" describe-mode "d" webster "e" webster-endings "q" webster-quit "s" webster-spell string-match "Lucid" emacs-version button2 webster-xref-word] 4) (fset 'webster-xref-word #[(event) "\n!!\n! #  q!!{)  ! \" ҉O ҕOP h \"db !+" [window-buffer event-window event buffer extent-at event-point highlight extent nil text extent-start-position extent-end-position x-selection-owner-p x-get-selection error "click on a highlighted word to define" string-match "\\." 0 message "looking up %s..." webster] 4 "\ Define the highlighted word under the mouse. Words which are known to have definitions are highlighted when the mouse moves over them. You may define any word by selecting it with the left mouse button and then clicking middle." "e"])