/[emacs]/emacs/lisp/info.el
ViewVC logotype

Diff of /emacs/lisp/info.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.403 by rms, Wed Oct 13 02:09:57 2004 UTC revision 1.404 by ttn, Mon Oct 18 07:29:52 2004 UTC
# Line 3445  Preserve text properties." Line 3445  Preserve text properties."
3445             (fontify-visited-p ; visited nodes need to be re-fontified             (fontify-visited-p ; visited nodes need to be re-fontified
3446              (and Info-fontify-visited-nodes              (and Info-fontify-visited-nodes
3447                   ;; Don't take time to refontify visited nodes in huge nodes                   ;; Don't take time to refontify visited nodes in huge nodes
3448                   (< (- (point-max) (point-min)) Info-fontify-maximum-menu-size))))                   (< (- (point-max) (point-min)) Info-fontify-maximum-menu-size)))
3449               rbeg rend)
3450    
3451        ;; Fontify header line        ;; Fontify header line
3452        (goto-char (point-min))        (goto-char (point-min))
# Line 3570  Preserve text properties." Line 3571  Preserve text properties."
3571                               "mouse-2: go to this node")                               "mouse-2: go to this node")
3572                  'mouse-face 'highlight)))                  'mouse-face 'highlight)))
3573              (when (or not-fontified-p fontify-visited-p)              (when (or not-fontified-p fontify-visited-p)
3574                (add-text-properties                (setq rbeg (match-beginning 2)
3575                 (match-beginning 2) (match-end 2)                      rend (match-end 2))
3576                 (list                (put-text-property
3577                  'font-lock-face                 rbeg rend
3578                  ;; Display visited nodes in a different face                 'font-lock-face
3579                  (if (and Info-fontify-visited-nodes                 ;; Display visited nodes in a different face
3580                           (save-match-data                 (if (and Info-fontify-visited-nodes
3581                             (let* ((node (replace-regexp-in-string                          (save-match-data
3582                                           "^[ \t]+" ""                            (let* ((node (replace-regexp-in-string
3583                                           (replace-regexp-in-string                                          "^[ \t]+" ""
3584                                            "[ \t\n]+" " "                                          (replace-regexp-in-string
3585                                            (or (match-string 5)                                           "[ \t\n]+" " "
3586                                                (and (not (equal (match-string 4) ""))                                           (or (match-string 5)
3587                                                     (match-string 4))                                               (and (not (equal (match-string 4) ""))
3588                                                (match-string 2)))))                                                    (match-string 4))
3589                                    (file (file-name-nondirectory                                               (match-string 2)))))
3590                                           Info-current-file))                                   (file (file-name-nondirectory
3591                                    (hl Info-history-list)                                          Info-current-file))
3592                                    res)                                   (hl Info-history-list)
3593                               (if (string-match "(\\([^)]+\\))\\([^)]*\\)" node)                                   res)
3594                                   (setq file (file-name-nondirectory                              (if (string-match "(\\([^)]+\\))\\([^)]*\\)" node)
3595                                               (match-string 1 node))                                  (setq file (file-name-nondirectory
3596                                         node (if (equal (match-string 2 node) "")                                              (match-string 1 node))
3597                                                  "Top"                                        node (if (equal (match-string 2 node) "")
3598                                                (match-string 2 node))))                                                 "Top"
3599                               (while hl                                               (match-string 2 node))))
3600                                 (if (and (string-equal node (nth 1 (car hl)))                              (while hl
3601                                          (string-equal file                                (if (and (string-equal node (nth 1 (car hl)))
3602                                                        (file-name-nondirectory                                         (string-equal file
3603                                                         (nth 0 (car hl)))))                                                       (file-name-nondirectory
3604                                     (setq res (car hl) hl nil)                                                        (nth 0 (car hl)))))
3605                                   (setq hl (cdr hl))))                                    (setq res (car hl) hl nil)
3606                               res))) 'info-xref-visited 'info-xref))))                                  (setq hl (cdr hl))))
3607                                res))) 'info-xref-visited 'info-xref))
3608                  ;; For multiline ref, unfontify newline and surrounding whitespace
3609                  (save-excursion
3610                    (goto-char rbeg)
3611                    (save-match-data
3612                      (while (re-search-forward "\\s-*\n\\s-*" rend t nil)
3613                        (remove-text-properties (match-beginning 0)
3614                                                (match-end 0)
3615                                                '(font-lock-face t))))))
3616              (when not-fontified-p              (when not-fontified-p
3617                (when (memq Info-hide-note-references '(t hide))                (when (memq Info-hide-note-references '(t hide))
3618                  (add-text-properties (match-beginning 3) (match-end 3)                  (add-text-properties (match-beginning 3) (match-end 3)

Legend:
Removed from v.1.403  
changed lines
  Added in v.1.404

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26