初稿: 2018-08-09 Thu 14:14
最終更新日: 2018-12-14 Fri 20:44
ホーム | 文書トップ | 目次

org-get-local-variables
バッファローカルの変数リストを取得する

 1: (defun org-get-local-variables ()
 2:   "Return a list of all local variables in an Org mode buffer."
 3:   (delq nil
 4:         (mapcar
 5:          (lambda (x)
 6:            (let* ((binding (if (symbolp x) (list x) (list (car x) (cdr x))))
 7:                   (name (car binding)))
 8:              (and (not (get name 'org-state))
 9:                   (not (memq name org-unique-local-variables))
10:                   (string-match-p
11:                    "\\`\\(org-\\|orgtbl-\\|outline-\\|comment-\\|paragraph-\\|\
12: auto-fill\\|normal-auto-fill\\|fill-paragraph\\|indent-\\)"
13:                    (symbol-name name))
14:                   binding)))
15:          (with-temp-buffer
16:            (org-mode)
17:            (buffer-local-variables)))))

日付: 2018-08-09 Thu 14:14

著者: conao

Created: 2018-12-14 Fri 21:04

Validate