[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Hiding *Note:: "tags" in info files
From: |
Kim F. Storm |
Subject: |
Hiding *Note:: "tags" in info files |
Date: |
Tue, 29 Oct 2002 12:03:19 +0000 (GMT) |
When I browse info files in emacs, I find all those visible
*Note ... :: "tags" pretty annoying, given that the references
are already displayed in the info-xref face.
The following patch hides those superfluous decorations.
The result isn't perfect, since the wording around some of the nodes
become a bit sparse, e.g. (upper case indicates highlighting)
*Note GETTING A PRINTED MANUAL::, if you would like a paper copy of
the Emacs manual.
(which isn't perfect English either) becomes
GETTING A PRINTED MANUAL, if you would like a paper copy of
the Emacs manual.
But personally I don't think that is worse than the *Note stuff.
WDYT?
Index: info.el
===================================================================
RCS file: /cvs/emacs/lisp/info.el,v
retrieving revision 1.318
diff -c -r1.318 info.el
*** info.el 8 Oct 2002 04:57:27 -0000 1.318
--- info.el 29 Oct 2002 11:51:26 -0000
***************
*** 2712,2724 ****
(add-text-properties (match-beginning 2) (1+ (match-end 2))
'(invisible t intangible t))))
(goto-char (point-min))
! (while (re-search-forward "\\*Note[ \n\t]+\\([^:]*\\):" nil t)
(if (= (char-after (1- (match-beginning 0))) ?\") ; hack
nil
(add-text-properties (match-beginning 1) (match-end 1)
'(font-lock-face info-xref
mouse-face highlight
! help-echo "mouse-2: go to this node"))))
(goto-char (point-min))
(if (and (search-forward "\n* Menu:" nil t)
(not (string-match "\\<Index\\>" Info-current-node))
--- 2712,2729 ----
(add-text-properties (match-beginning 2) (1+ (match-end 2))
'(invisible t intangible t))))
(goto-char (point-min))
! (while (re-search-forward "\\(\\*Note[ \n\t]+\\)\\([^:]*\\)\\(:+\\)"
nil t)
(if (= (char-after (1- (match-beginning 0))) ?\") ; hack
nil
(add-text-properties (match-beginning 1) (match-end 1)
+ '(invisible t))
+ (add-text-properties (match-beginning 2) (match-end 2)
'(font-lock-face info-xref
mouse-face highlight
! help-echo "mouse-2: go to this node"))
! (add-text-properties (match-beginning 3) (match-end 3)
! '(invisible t))))
!
(goto-char (point-min))
(if (and (search-forward "\n* Menu:" nil t)
(not (string-match "\\<Index\\>" Info-current-node))
--
Kim F. Storm <address@hidden> http://www.cua.dk
- Hiding *Note:: "tags" in info files,
Kim F. Storm <=
- Re: Hiding *Note:: "tags" in info files, Francesco Potorti`, 2002/10/29
- Re: Hiding *Note:: "tags" in info files, Eli Zaretskii, 2002/10/29
- Re: Hiding *Note:: "tags" in info files, Richard Stallman, 2002/10/30
- Re: Hiding *Note:: "tags" in info files, Kim F. Storm, 2002/10/30
- Re: Hiding *Note:: "tags" in info files, Eli Zaretskii, 2002/10/31
- Re: Hiding *Note:: "tags" in info files, Richard Stallman, 2002/10/31
- Re: Hiding *Note:: "tags" in info files, Kim F. Storm, 2002/10/31
- Re: Hiding *Note:: "tags" in info files, Karl Eichwalder, 2002/10/31