Function: quail-map-from-table-1
quail-map-from-table-1 is a byte-compiled function defined in
quail.el.gz.
Signature
(quail-map-from-table-1 STATE-ALIST STATE-INFO)
Source Code
;; Defined in /usr/src/emacs/lisp/international/quail.el.gz
;; STATE-INFO has the form (STATE TRANSITION ...). Set key sequence
;; mapping rules in the element of STATE-ALIST that corresponds to
;; STATE according to TRANSITION ...
(defun quail-map-from-table-1 (state-alist state-info)
(let* ((state (car state-info))
(map (assq state state-alist))
(transitions (cdr state-info))
elt)
(while transitions
(setq elt (car transitions) transitions (cdr transitions))
(let (rules dst-state key trans)
;; ELT has the form (RULES-SYMBOL . STATE-x) or RULES-SYMBOL.
;; STATE-x is one of car parts of STATE-ALIST's elements.
(if (consp elt)
(setq rules (symbol-value (car elt))
;; Set (STATE-x) as branches for all keys in RULES.
;; It is replaced with actual branches for STATE-x
;; later in `quail-map-from-table-2'.
dst-state (list (cdr elt)))
(setq rules (symbol-value elt)))
(while rules
(setq key (car (car rules)) trans (cdr (car rules))
rules (cdr rules))
(if (stringp trans)
(if (= (length trans) 1)
(setq trans (aref trans 0))
(setq trans (string-to-vector trans))))
(set-nested-alist key trans map nil dst-state))))))