From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.bugs Subject: bug#13276: 24.2.50; apropos-variable Date: Sat, 5 Jan 2013 09:52:23 -0800 Message-ID: <875D2690F3D44FF4B693C744AB397051@us.oracle.com> References: <87ehi1wfhj.fsf@bzg.ath.cx> <87pq1kc4eo.fsf@bzg.ath.cx> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1357408376 14648 80.91.229.3 (5 Jan 2013 17:52:56 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 5 Jan 2013 17:52:56 +0000 (UTC) Cc: 13276@debbugs.gnu.org, rms@gnu.org To: "'Bastien'" , "'Stefan Monnier'" Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Jan 05 18:53:12 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1TrXvk-0000ct-AM for geb-bug-gnu-emacs@m.gmane.org; Sat, 05 Jan 2013 18:53:12 +0100 Original-Received: from localhost ([::1]:36038 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TrXvU-0006oJ-Ub for geb-bug-gnu-emacs@m.gmane.org; Sat, 05 Jan 2013 12:52:56 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:54445) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TrXvR-0006mD-HI for bug-gnu-emacs@gnu.org; Sat, 05 Jan 2013 12:52:55 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TrXvN-0005h9-Cq for bug-gnu-emacs@gnu.org; Sat, 05 Jan 2013 12:52:53 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:34911) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TrXvN-0005h5-Aj for bug-gnu-emacs@gnu.org; Sat, 05 Jan 2013 12:52:49 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1TrXva-0007RZ-CB for bug-gnu-emacs@gnu.org; Sat, 05 Jan 2013 12:53:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: "Drew Adams" Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 05 Jan 2013 17:53:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13276 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: notabug Original-Received: via spool by 13276-submit@debbugs.gnu.org id=B13276.135740837228599 (code B ref 13276); Sat, 05 Jan 2013 17:53:02 +0000 Original-Received: (at 13276) by debbugs.gnu.org; 5 Jan 2013 17:52:52 +0000 Original-Received: from localhost ([127.0.0.1]:45162 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TrXvP-0007RE-Si for submit@debbugs.gnu.org; Sat, 05 Jan 2013 12:52:52 -0500 Original-Received: from aserp1040.oracle.com ([141.146.126.69]:37649) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TrXvM-0007R9-5J for 13276@debbugs.gnu.org; Sat, 05 Jan 2013 12:52:49 -0500 Original-Received: from acsinet22.oracle.com (acsinet22.oracle.com [141.146.126.238]) by aserp1040.oracle.com (Sentrion-MTA-4.2.2/Sentrion-MTA-4.2.2) with ESMTP id r05HqVGG013003 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Sat, 5 Jan 2013 17:52:32 GMT Original-Received: from acsmt357.oracle.com (acsmt357.oracle.com [141.146.40.157]) by acsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r05HqUZq022293 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 5 Jan 2013 17:52:31 GMT Original-Received: from abhmt116.oracle.com (abhmt116.oracle.com [141.146.116.68]) by acsmt357.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id r05HqTHQ016561; Sat, 5 Jan 2013 11:52:30 -0600 Original-Received: from dradamslap1 (/71.202.147.44) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Sat, 05 Jan 2013 09:52:29 -0800 X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <87pq1kc4eo.fsf@bzg.ath.cx> Thread-Index: Ac3rLzIXZp2AVYWSQIKI3aTCgGhA1AAMoWng X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-Source-IP: acsinet22.oracle.com [141.146.126.238] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:69415 Archived-At: > >> I suggest renaming `apropos-variable' to `apropos-option' and to > >> use `apropos-variable' for > > That sounds right. > The attached patch does this. Glad to see this finally happening. > It renames `apropos-variable' to `apropos-option' and define a new > `apropos-variable' command. C-u M-x apropos-variable RET shows only > user options, and C-u M-x apropos-option RET shows all variables. > > The patch also introduces a new button for user options so that > users can immediately see which variables are options in the apropos > buffer. IOW, essentially the code I pointed to last month (as well as years ago): http://www.emacswiki.org/emacs/download/apropos-fn%2bvar.el FWIW, this doc line is not too good: With \\[universal-argument] prefix, or if `apropos-do-all' is non-nil, also show -normal variables." +variables, not just user options." User options _are_ variables. The line should say something like "also show variables that are not user options." Question (not particularly related to this patch): Why do we treat the faces differently for, say, `apropos-symbol' and `apropos-variable'? apropos.el defines faces for these buttons: apropos-function-button apropos-variable-button apropos-option-button apropos-misc-button But it defines faces for these things - not for their buttons: apropos-symbol apropos-keybinding apropos-property Why don't we handle the following the same way we handle `apropos-symbol' (or vice versa): apropos-function apropos-variable apropos-option apropos-misc E.g., when defining their button types, just include both `button' and the thing's face for property `face'? E.g., (defface apropos-option '((t (:inherit font-lock-variable-name-face))) "Face used for option names in Apropos buffers." :group 'apropos) (define-button-type 'apropos-option 'apropos-label "Option" 'apropos-short-label "o" 'face '(apropos-option button) ; <====================== 'help-echo "mouse-2, RET: Display more help on this user option (variable)" 'follow-link t 'action (lambda (button) (describe-variable (button-get button 'apropos-symbol)))) Just wondering. Why do we treat these differently? In all cases the faces are used only for buttons. Is there some advantage to using one or the other treatment? Thx.