diff options
author | David Aspinall <da@inf.ed.ac.uk> | 2010-08-27 14:47:28 +0000 |
---|---|---|
committer | David Aspinall <da@inf.ed.ac.uk> | 2010-08-27 14:47:28 +0000 |
commit | 3841c6b363b74d2fc214acd92041fa608d2e9913 (patch) | |
tree | 45b1e15ac9ea7b040c3341bb05c43477f9a60665 /lib/span.el | |
parent | 15ccc9c78cf0bc4fb5d6ffa0e76d280d9638e99b (diff) |
Implement the eagerly anticipated Beyond Script Management Feature No.2 (i.e., automatic preview of next command)
Diffstat (limited to 'lib/span.el')
-rw-r--r-- | lib/span.el | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/span.el b/lib/span.el index 32967c78..6b576b87 100644 --- a/lib/span.el +++ b/lib/span.el @@ -215,6 +215,17 @@ Return nil if no such overlay belong to the list." "Set the end point of SPAN to VALUE." (span-set-endpoints span (span-start span) value)) +;; +;; Handy overlay utils +;; + +(defun span-add-self-removing-span (beg end &rest props) + (let ((ol (make-overlay beg end))) + (while props + (overlay-put ol (car props) (cadr props)) + (setq props (cddr props))) + (add-timeout 2 'delete-overlay ol))) + (provide 'span) |