Function: artist-go-retrieve-from-symbol-sub

artist-go-retrieve-from-symbol-sub is a byte-compiled function defined in artist.el.gz.

Signature

(artist-go-retrieve-from-symbol-sub TABLE SYMBOL RETRIEVE-FN)

Documentation

Search the TABLE for a graphics operation SYMBOL.

Calls RETRIEVE-FN to retrieve information from that symbol's info-variant-part.

Source Code

;; Defined in /usr/src/emacs/lisp/textmodes/artist.el.gz
(defun artist-go-retrieve-from-symbol-sub (table symbol retrieve-fn)
  "Search the TABLE for a graphics operation SYMBOL.
Calls RETRIEVE-FN to retrieve information from that symbol's
info-variant-part."
  (catch 'found
    (mapc
     (lambda (element)
       (let ((element-tag (artist-mt-get-tag element)))
	 (cond ((eq element-tag 'graphics-operation)
		(let* ((info-part     (artist-mt-get-info-part element))
		       (unshifted     (artist-go-get-unshifted info-part))
		       (shifted       (artist-go-get-shifted info-part))
		       (unshifted-sym (artist-go-get-symbol unshifted))
		       (shifted-sym   (artist-go-get-symbol shifted))
		       (variant-part  (cond
				       ((eq unshifted-sym symbol) unshifted)
				       ((eq shifted-sym symbol) shifted)
				       (t nil))))
		  (if variant-part	; if found do:
		      (throw 'found (funcall retrieve-fn variant-part)))))

	       ((eq element-tag 'menu)
		(let* ((info-part     (artist-mt-get-info-part element))
		       (items         (artist-mn-get-items info-part))
		       (answer        (artist-go-retrieve-from-symbol-sub
				       items symbol retrieve-fn)))
		  (if answer (throw 'found answer)))))))

     table)
    nil))