aboutsummaryrefslogtreecommitdiffstats
path: root/lisp
diff options
context:
space:
mode:
authorJuri Linkov2004-04-27 06:43:42 +0000
committerJuri Linkov2004-04-27 06:43:42 +0000
commit6afd5d68ae9dcea3ef6361174cb5af8b724441b0 (patch)
treeaed20f5dec9248805038ed4fce6991e88505778e /lisp
parentda4ae7d3d80a2b1b8bb0b8baf1ecb488f2ef52ca (diff)
downloademacs-6afd5d68ae9dcea3ef6361174cb5af8b724441b0.tar.gz
emacs-6afd5d68ae9dcea3ef6361174cb5af8b724441b0.zip
(show-paren-highlight-openparen): New var.
(show-paren-function): Turn on openparen highlighting when matching forward if show-paren-highlight-openparen is non-nil.
Diffstat (limited to 'lisp')
-rw-r--r--lisp/paren.el5
1 files changed, 4 insertions, 1 deletions
diff --git a/lisp/paren.el b/lisp/paren.el
index ab3efe10ba5..6c5f9dece99 100644
--- a/lisp/paren.el
+++ b/lisp/paren.el
@@ -91,6 +91,9 @@ otherwise)."
91 :group 'faces 91 :group 'faces
92 :group 'paren-showing) 92 :group 'paren-showing)
93 93
94(defvar show-paren-highlight-openparen t
95 "*Non-nil turns on openparen highlighting when matching forward.")
96
94(defvar show-paren-idle-timer nil) 97(defvar show-paren-idle-timer nil)
95 98
96;;;###autoload 99;;;###autoload
@@ -195,7 +198,7 @@ in `show-paren-style' after `show-paren-delay' seconds of Emacs idle time."
195 ;; If matching forward, and the openparen is unbalanced, 198 ;; If matching forward, and the openparen is unbalanced,
196 ;; highlight the paren at point to indicate misbalance. 199 ;; highlight the paren at point to indicate misbalance.
197 ;; Otherwise, turn off any such highlighting. 200 ;; Otherwise, turn off any such highlighting.
198 (if (and (= dir 1) (integerp pos)) 201 (if (and (not show-paren-highlight-openparen) (= dir 1) (integerp pos))
199 (when (and show-paren-overlay-1 202 (when (and show-paren-overlay-1
200 (overlay-buffer show-paren-overlay-1)) 203 (overlay-buffer show-paren-overlay-1))
201 (delete-overlay show-paren-overlay-1)) 204 (delete-overlay show-paren-overlay-1))