diff options
author | 2008-02-04 23:33:31 +0000 | |
---|---|---|
committer | 2008-02-04 23:33:31 +0000 | |
commit | fa1f4d61609e7980466b723652cab284cbc5d242 (patch) | |
tree | c49336a6e586f5c49420bd18529bb768b3ad548e | |
parent | 4bd71ee0cd3d5d102ec5a264a74ff7d0b4abba9a (diff) |
Make display properties rear sticky. This is good for begin..end but not
for singleton controls (which are a nuisance enough already).
-rw-r--r-- | lib/unicode-tokens.el | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/lib/unicode-tokens.el b/lib/unicode-tokens.el index d072e0f5..1074ac23 100644 --- a/lib/unicode-tokens.el +++ b/lib/unicode-tokens.el @@ -516,11 +516,13 @@ after next character (single character control sequence)." "Key map used for Unicode Tokens mode.") (define-minor-mode unicode-tokens-mode - "Minor mode for unicode token input." - nil - " Utoks" ; input method indication already + "Minor mode for unicode token input." nil " Utoks" unicode-tokens-mode-map + (make-variable-buffer-local 'text-property-default-nonsticky) (when unicode-tokens-mode + (setq text-property-default-nonsticky + ;; We want to use display property with stickyness + (delete '(display . t) text-property-default-nonsticky)) (if (fboundp 'set-buffer-multibyte) (set-buffer-multibyte t)) (let ((inhibit-read-only t)) @@ -529,6 +531,7 @@ after next character (single character control sequence)." (format-decode-buffer 'unicode-tokens)) (set-input-method "Unicode tokens")) (unless unicode-tokens-mode + (add-to-list 'text-property-default-nonsticky '(display . t)) ;; leave buffer encoding as is (let ((inhibit-read-only t) (modified (buffer-modified-p))) |