diff options
author | David Aspinall <da@inf.ed.ac.uk> | 2002-08-16 17:21:33 +0000 |
---|---|---|
committer | David Aspinall <da@inf.ed.ac.uk> | 2002-08-16 17:21:33 +0000 |
commit | 555f39491e50772caacae0b9dbd276846befa361 (patch) | |
tree | 6c396006bf0c1fd91aef3984c37a9a481ab93e99 /isa | |
parent | 5c4cc30fde5df333e46875fec0e17f9091a40b02 (diff) |
Add span menu for thm_deps
Diffstat (limited to 'isa')
-rw-r--r-- | isa/isa.el | 3 | ||||
-rw-r--r-- | isa/isabelle-system.el | 15 |
2 files changed, 18 insertions, 0 deletions
@@ -125,6 +125,9 @@ and script mode." proof-shell-inform-file-retracted-cmd "ProofGeneral.inform_file_retracted \"%s\";" + ;; span menu + proof-script-span-context-menu-extensions 'isabelle-create-span-menu + ;; Parsing error messages. Bit tricky to allow for ;; multitude of possible error formats Isabelle spits out. ;; Ideally we shouldn't bother parsing errors that appear diff --git a/isa/isabelle-system.el b/isa/isabelle-system.el index 0c23d1b4..1262e786 100644 --- a/isa/isabelle-system.el +++ b/isa/isabelle-system.el @@ -433,6 +433,21 @@ the function `pg-remove-specials' can be used instead)." (replace-match "\374" nil t))) +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;; +;; Context-senstive in-span menu additions +;; + +(defun isabelle-create-span-menu (span idiom name) + (if (string-equal idiom "proof") + (let ((thm (span-property span 'name))) + (list (vector + "Visualise dependencies" + `(proof-shell-invisible-command + ,(format (if isa-running-isar + "thm_deps %s;" "thm_deps [%s];") thm)) + (not (string-equal thm proof-unnamed-theorem-name))))))) + (provide 'isabelle-system) ;; End of isabelle-system.el |