From: Andreas Schwab Date: Thu, 19 Jun 2003 20:56:49 +0000 (+0000) Subject: (Info-fontify-node): Improve calculation of other-tag. X-Git-Tag: ttn-vms-21-2-B4~9602 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=fb020fe894db0dfa6d6d2b180a1cf8b489bfccba;p=emacs.git (Info-fontify-node): Improve calculation of other-tag. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1464a5ff799..8434d40bbe1 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2003-06-19 Andreas Schwab + + * info.el (Info-fontify-node): Improve calculation of other-tag. + 2003-06-19 Stefan Monnier * progmodes/cc-mode.el (c-mode): Reverting last change. diff --git a/lisp/info.el b/lisp/info.el index 54e6f6d1f02..ce013c7c844 100644 --- a/lisp/info.el +++ b/lisp/info.el @@ -2872,13 +2872,19 @@ the variable `Info-file-list-for-emacs'." (goto-char start) (skip-syntax-backward " ") (setq other-tag - (cond - ((<= (point) (point-min)) - "See ") - ((memq (char-before) '(nil ?\. ?! )) - "See ") - ((memq (char-before) '( ?\( ?\[ ?\{ ?\, ?\; ?\: )) - "see "))) + (cond ((memq (char-before) '(nil ?\. ?! ??)) + "See ") + ((memq (char-before) '(?\, ?\; ?\: ?-)) + "see ") + ((memq (char-before) '(?\( ?\[ ?\{)) + ;; Check whether the paren is preceded by + ;; an end of sentence + (skip-syntax-backward " (") + (if (memq (char-before) '(nil ?\. ?! ??)) + "See " + "see ")) + ((save-match-data (looking-at "\n\n")) + "See "))) (goto-char next)) (if hide-tag (add-text-properties (match-beginning 1) (match-end 1)