From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: bojohan+news@dd.chalmers.se (Johan =?utf-8?Q?Bockg=C3=A5rd?=) Newsgroups: gmane.emacs.devel Subject: Highlight advice (was: Multiple major modes) Date: Tue, 04 Sep 2007 11:03:30 +0200 Message-ID: References: <466E7A93.3050705@gmail.com> <466E81AA.3030202@gnu.org> <466E9822.2050508@gmail.com> <466EAB9D.9020408@gnu.org> <466EEA71.2070700@gmail.com> <200706122014.l5CKEKV1021902@projectile.siege-engine.com> <200706190209.l5J29Csr010302@projectile.siege-engine.com> <200706251404.l5PE4dgc011720@projectile.siege-engine.com> <18059.52286.486779.619378@gargle.gargle.HOWL> <87fy42vzob.fsf@uwakimon.sk.tsukuba.ac.jp> <468F9F75.6070706@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: sea.gmane.org 1188896795 29574 80.91.229.12 (4 Sep 2007 09:06:35 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 4 Sep 2007 09:06:35 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Sep 04 11:06:34 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1ISUKd-0002oe-Sp for ged-emacs-devel@m.gmane.org; Tue, 04 Sep 2007 11:04:24 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1ISUKc-0003Jb-3f for ged-emacs-devel@m.gmane.org; Tue, 04 Sep 2007 05:04:22 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1ISUKF-00032f-7o for emacs-devel@gnu.org; Tue, 04 Sep 2007 05:03:59 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1ISUKA-0002y7-Nb for emacs-devel@gnu.org; Tue, 04 Sep 2007 05:03:57 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1ISUKA-0002xo-Cb for emacs-devel@gnu.org; Tue, 04 Sep 2007 05:03:54 -0400 Original-Received: from main.gmane.org ([80.91.229.2] helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1ISUK9-0002oB-G2 for emacs-devel@gnu.org; Tue, 04 Sep 2007 05:03:53 -0400 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1ISUJx-00058D-JA for emacs-devel@gnu.org; Tue, 04 Sep 2007 11:03:41 +0200 Original-Received: from gamma02.me.chalmers.se ([129.16.50.72]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 04 Sep 2007 11:03:41 +0200 Original-Received: from bojohan+news by gamma02.me.chalmers.se with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 04 Sep 2007 11:03:41 +0200 X-Injected-Via-Gmane: http://gmane.org/ Mail-Followup-To: emacs-devel@gnu.org Original-Lines: 41 Original-X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: gamma02.me.chalmers.se Mail-Copies-To: never User-Agent: Gnus/5.110007 (No Gnus v0.7) Emacs/22.1.50 (gnu/linux) Cancel-Lock: sha1:GIi63cbaw1EVA9Z4ZXWyu+dH4xI= X-Detected-Kernel: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:77731 Archived-At: Richard Stallman writes: > > I often do that, but I don't read carefully thru the buffer thaht > > `describe-function' displays. If it said something about advice, I > > wouldn't even notice, unless I read carefully thru the buffer to look > > for such. And I am in too much of a hurry to make a practice > > of always reading that text carefully. > > Did someone already say "highlight the advice info" in the help buffer? > > I have doubts that it will help that much, but it can't hurt. Would > someone please implement it? 2007-09-04 Johan Bockgård * emacs-lisp/advice.el (ad-make-advised-docstring): Highlight note in doc string. Index: lisp/emacs-lisp/advice.el =================================================================== RCS file: /cvsroot/emacs/emacs/lisp/emacs-lisp/advice.el,v retrieving revision 1.54 diff -u -r1.54 advice.el --- lisp/emacs-lisp/advice.el 28 Jul 2007 19:57:22 -0000 1.54 +++ lisp/emacs-lisp/advice.el 4 Sep 2007 08:44:59 -0000 @@ -2996,7 +2996,9 @@ (setq usage (if (null usage) t (setq origdoc (cdr usage)) (car usage))) (if origdoc (setq paragraphs (list origdoc))) (unless (eq style 'plain) - (push (concat "This " origtype " is advised.") paragraphs)) + (push (propertize (concat "This " origtype " is advised.") + 'face 'font-lock-warning-face) + paragraphs)) (ad-dolist (class ad-advice-classes) (ad-dolist (advice (ad-get-enabled-advices function class)) (setq advice-docstring -- Johan Bockgård