# HG changeset patch # User Kim F. Storm # Date 1036190892 0 # Node ID 40e2242be50f9c55f495e4a0eadeae3d11dab35e # Parent 7897f914f4140159510124f342142063b93c7898 (Info-hide-note-references): nil value now does no reformatting at all. New choice 'tag reformats tag but shows the section reference. (Info-fontify-node): Use it. diff -r 7897f914f414 -r 40e2242be50f lisp/info.el --- a/lisp/info.el Fri Nov 01 22:47:37 2002 +0000 +++ b/lisp/info.el Fri Nov 01 22:48:12 2002 +0000 @@ -146,8 +146,13 @@ :group 'info) (defcustom Info-hide-note-references t - "*If non-nil, hide the section reference in *note and * menu items." - :type 'boolean + "*If non-nil, hide the tag and section reference in *note and * menu items. +Also replaces the \"*note\" text with \"see\". +If value is a number, the reference section is still shown." + :version "21.4" + :type '(choice (const :tag "Replace tag and hide reference" t) + (const :tag "Replace only tag" tag) + (const :tag "No reformatting" nil)) :group 'info) (defcustom Info-mode-hook '(turn-on-font-lock) @@ -2725,7 +2730,7 @@ (while (re-search-forward "\\(\\*Note[ \n\t]+\\)\\([^:]*\\)\\(:[^.,:]*[,:]?\\)" nil t) (unless (= (char-after (1- (match-beginning 0))) ?\") ; hack (let ((next (point)) - (hide-tag font-lock-mode) + (hide-tag Info-hide-note-references) other-tag) (when hide-tag ;; *Note is often used where *note should have been @@ -2749,7 +2754,7 @@ '(font-lock-face info-xref mouse-face highlight help-echo "mouse-2: go to this node")) - (if Info-hide-note-references + (if (eq Info-hide-note-references t) (add-text-properties (match-beginning 3) (match-end 3) '(invisible t intangible t)))))) @@ -2769,7 +2774,7 @@ '(font-lock-face info-xref mouse-face highlight help-echo "mouse-2: go to this node")) - (if Info-hide-note-references + (if (eq Info-hide-note-references t) (add-text-properties (match-beginning 2) (match-end 2) (list 'display (make-string (max 2 (- 22 (- (match-end 1) (match-beginning 1)))) ? )