unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Make apostrophes invisible in Help buffers
@ 2005-12-18 12:10 Nick Roberts
  2005-12-19  4:38 ` Richard M. Stallman
  2005-12-19 19:58 ` Drew Adams
  0 siblings, 2 replies; 7+ messages in thread
From: Nick Roberts @ 2005-12-18 12:10 UTC (permalink / raw)



The patch below works just for symbols and is just for demonstration purposes.
It would also be nice to use the same face as Info for links.  After the
release, info-xref-visited face could also be used help topics previously
visited.

Nick


*** help-mode.el	15 Nov 2005 15:48:05 +1300	1.40
--- help-mode.el	19 Dec 2005 01:02:46 +1300	
***************
*** 381,387 ****
                  (while (re-search-forward help-xref-symbol-regexp nil t)
                    (let* ((data (match-string 8))
                           (sym (intern-soft data)))
!                     (if sym
                          (cond
                           ((match-string 3)  ; `variable' &c
                            (and (or (boundp sym) ; `variable' doesn't ensure
--- 381,387 ----
                  (while (re-search-forward help-xref-symbol-regexp nil t)
                    (let* ((data (match-string 8))
                           (sym (intern-soft data)))
!                     (when sym
                          (cond
                           ((match-string 3)  ; `variable' &c
                            (and (or (boundp sym) ; `variable' doesn't ensure
***************
*** 426,432 ****
   			      (cyclic-variable-indirection nil))))
  			  (help-xref-button 8 'help-variable sym))
  			 ((fboundp sym)
! 			  (help-xref-button 8 'help-function sym)))))))
                ;; An obvious case of a key substitution:
                (save-excursion
                  (while (re-search-forward
--- 426,436 ----
   			      (cyclic-variable-indirection nil))))
  			  (help-xref-button 8 'help-variable sym))
  			 ((fboundp sym)
! 			  (help-xref-button 8 'help-function sym)))
! 			(let ((start (match-beginning 8))
! 			      (end (match-end 8)))
! 			(put-text-property start (1- start) 'invisible t)
! 			(put-text-property end (1+ end) 'invisible t))))))
                ;; An obvious case of a key substitution:
                (save-excursion
                  (while (re-search-forward

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Make apostrophes invisible in Help buffers
  2005-12-18 12:10 Make apostrophes invisible in Help buffers Nick Roberts
@ 2005-12-19  4:38 ` Richard M. Stallman
  2005-12-19  5:11   ` Nick Roberts
  2005-12-19 19:58 ` Drew Adams
  1 sibling, 1 reply; 7+ messages in thread
From: Richard M. Stallman @ 2005-12-19  4:38 UTC (permalink / raw)
  Cc: emacs-devel

    The patch below works just for symbols and is just for demonstration purposes.

Thanks, but I don't think that is a change for the better.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Make apostrophes invisible in Help buffers
  2005-12-19  4:38 ` Richard M. Stallman
@ 2005-12-19  5:11   ` Nick Roberts
  2005-12-19 23:46     ` Richard M. Stallman
  0 siblings, 1 reply; 7+ messages in thread
From: Nick Roberts @ 2005-12-19  5:11 UTC (permalink / raw)
  Cc: emacs-devel

 >     The patch below works just for symbols and is just for demonstration
 >     purposes.
 > 
 > Thanks, but I don't think that is a change for the better.

The apostrophes are put in the doc string so that links can be parsed in the
Help buffer, not for the end user.  Links are evident by using the appropriate
face and removing the apostrophes makes their appearance consistent with info.

I also have other changes which I think improve linking in the Help buffer.  I
will submit again after the release.

Nick

^ permalink raw reply	[flat|nested] 7+ messages in thread

* RE: Make apostrophes invisible in Help buffers
  2005-12-18 12:10 Make apostrophes invisible in Help buffers Nick Roberts
  2005-12-19  4:38 ` Richard M. Stallman
@ 2005-12-19 19:58 ` Drew Adams
  1 sibling, 0 replies; 7+ messages in thread
From: Drew Adams @ 2005-12-19 19:58 UTC (permalink / raw)


_Why_ make apostrophes invisible in Help buffers?    

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Make apostrophes invisible in Help buffers
  2005-12-19  5:11   ` Nick Roberts
@ 2005-12-19 23:46     ` Richard M. Stallman
  2005-12-20  0:32       ` Nick Roberts
  0 siblings, 1 reply; 7+ messages in thread
From: Richard M. Stallman @ 2005-12-19 23:46 UTC (permalink / raw)
  Cc: emacs-devel

    The apostrophes are put in the doc string so that links can be parsed in the
    Help buffer, not for the end user.

The apostrophes follow a general GNU convention for indicating symbol
names in text.  We have followed that convention for 20 years.
So I am not going to say yes to this change.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Make apostrophes invisible in Help buffers
  2005-12-19 23:46     ` Richard M. Stallman
@ 2005-12-20  0:32       ` Nick Roberts
  2005-12-20 16:33         ` Richard M. Stallman
  0 siblings, 1 reply; 7+ messages in thread
From: Nick Roberts @ 2005-12-20  0:32 UTC (permalink / raw)
  Cc: emacs-devel

 >     The apostrophes are put in the doc string so that links can be parsed
 >     in the Help buffer, not for the end user.
 > 
 > The apostrophes follow a general GNU convention for indicating symbol
 > names in text.  We have followed that convention for 20 years.
 > So I am not going to say yes to this change.

Its a convention that was made when monochrome text-only terminals like
VT100s were the norm.  My guess is that with the underline, mouse-face
highlighting and help echo, the user will guess that he's looking at a
symbol name... but its your choice.

Nick

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Make apostrophes invisible in Help buffers
  2005-12-20  0:32       ` Nick Roberts
@ 2005-12-20 16:33         ` Richard M. Stallman
  0 siblings, 0 replies; 7+ messages in thread
From: Richard M. Stallman @ 2005-12-20 16:33 UTC (permalink / raw)
  Cc: emacs-devel

We use this convention in lots of places, not just in Emacs doc strings.

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2005-12-20 16:33 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-12-18 12:10 Make apostrophes invisible in Help buffers Nick Roberts
2005-12-19  4:38 ` Richard M. Stallman
2005-12-19  5:11   ` Nick Roberts
2005-12-19 23:46     ` Richard M. Stallman
2005-12-20  0:32       ` Nick Roberts
2005-12-20 16:33         ` Richard M. Stallman
2005-12-19 19:58 ` Drew Adams

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).