From 1893a8546e90dfda0e1f4e2d5bb5b2dbf8e90873 Mon Sep 17 00:00:00 2001 From: hjunes Date: Fri, 6 Jun 2003 22:28:40 +0000 Subject: [PATCH] count one slur type in LilyPond-show-paren-function --- ChangeLog | 5 +++++ lilypond-indent.el | 6 +++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index c0603741bd..58d37afdeb 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2003-06-07 Heikki Junes + + * lilypond-indent.el: match only one type of slurs in + LilyPond-show-paren-function. + 2003-06-05 Jan Nieuwenhuizen * debian/GNUmakefile (EXTRA_DIST_FILES): diff --git a/lilypond-indent.el b/lilypond-indent.el index a133ab9ef8..f98a8d9480 100644 --- a/lilypond-indent.el +++ b/lilypond-indent.el @@ -337,6 +337,9 @@ slur-paren-p defaults to nil. (setq paren-regexp (concat (car paren-regexp) "\\|" (cdr paren-regexp)))) (setq paren-regexp (concat (mapconcat 'car (mapcar 'cdr regexp-alist) "\\|") "\\|" (mapconcat 'cdr (mapcar 'cdr regexp-alist) "\\|"))))) + (if (and (eq dir 1) + (memq (char-after oldpos) '(?[ ?{))) + (forward-char 1)) (while (and (if (/= dir 1) (> level 0) (< level 0)) @@ -430,7 +433,8 @@ builtin 'blink-matching-open' is not used. In syntax table, see (narrow-to-region (max (point-min) (- (point) blink-matching-paren-distance)) (min (point-max) (+ (point) blink-matching-paren-distance)))) - (if (memq bracket-type '(?> ?} ?< ?{)) + (if (and (equal this-command 'LilyPond-electric-close-paren) + (memq bracket-type '(?> ?} ?< ?{))) ;; < { need to be mutually balanced and nested, so search backwards for both of these bracket types (LilyPond-scan-containing-sexp nil nil dir) ;; whereas ( ) slurs within music don't, so only need to search for ( ) -- 2.39.5