From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.help Subject: RE: Advice on studying Emacs Lisp files Date: Mon, 26 Jan 2015 16:39:21 -0800 (PST) Message-ID: <9e95e862-171e-4565-93c1-02f0a28b18b5@default> References: <87fvbdhvpv.fsf@wmi.amu.edu.pl> <87d26hhuk3.fsf@wmi.amu.edu.pl> <87lhl1h3gm.fsf@wmi.amu.edu.pl> <3ae6cdef-c0a6-4064-83f5-f14f23fe0ad9@default> <87vbjxgkrn.fsf@wmi.amu.edu.pl> <87lhksgzn6.fsf@wmi.amu.edu.pl> <9703e115-1c34-4466-97fc-a9b1d0a7c6ae@default> <87ppa1du6q.fsf@wmi.amu.edu.pl> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1422319189 32127 80.91.229.3 (27 Jan 2015 00:39:49 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 27 Jan 2015 00:39:49 +0000 (UTC) Cc: Help Gnu Emacs mailing list To: Marcin Borkowski Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Jan 27 01:39:49 2015 Return-path: Envelope-to: geh-help-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 1YFuC4-0002Yx-5p for geh-help-gnu-emacs@m.gmane.org; Tue, 27 Jan 2015 01:39:48 +0100 Original-Received: from localhost ([::1]:44733 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YFuC3-0003Mh-KK for geh-help-gnu-emacs@m.gmane.org; Mon, 26 Jan 2015 19:39:47 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:52170) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YFuBl-0003MW-C0 for help-gnu-emacs@gnu.org; Mon, 26 Jan 2015 19:39:31 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YFuBh-0001aC-AB for help-gnu-emacs@gnu.org; Mon, 26 Jan 2015 19:39:29 -0500 Original-Received: from userp1040.oracle.com ([156.151.31.81]:35811) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YFuBh-0001Yt-3f for help-gnu-emacs@gnu.org; Mon, 26 Jan 2015 19:39:25 -0500 Original-Received: from ucsinet21.oracle.com (ucsinet21.oracle.com [156.151.31.93]) by userp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id t0R0dNNN022968 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 27 Jan 2015 00:39:24 GMT Original-Received: from aserz7022.oracle.com (aserz7022.oracle.com [141.146.126.231]) by ucsinet21.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id t0R0dLEu001361 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Tue, 27 Jan 2015 00:39:23 GMT Original-Received: from abhmp0013.oracle.com (abhmp0013.oracle.com [141.146.116.19]) by aserz7022.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id t0R0dLJF009064; Tue, 27 Jan 2015 00:39:21 GMT In-Reply-To: <87ppa1du6q.fsf@wmi.amu.edu.pl> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.8.2 (807160) [OL 12.0.6691.5000 (x86)] X-Source-IP: ucsinet21.oracle.com [156.151.31.93] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 156.151.31.81 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:102299 Archived-At: > >> I want the bookmarks to be highlighted as soon as I visit the file... > >> I do not intend to use bookmarks very heavily (i.e., not too many of > >> them), and I'd like them to be highlighted by default, without any > >> explicit action. > > > > See `bmkp-(un)light-bookmarks' and `bmkp-(un)light-this-buffer'. > > > > Use them from Lisp or interactively. `bmkp-(un)light-bookmarks': >=20 > So do I get it correctly that the best bet (assuming that I want the > bookmarks to be highlighted by default) is to call bmkp-light-bookmarks > in some hook firing after loading? After loading what? That function lights up a set of bookmarks. You could pass it your `bookmark-alist' as arg and it would then light up *all* of your bookmarks. But such all-bookmarks behavior is not provided interactively, because it is not in fact useful. `bmkp-light-bookmarks' just highlights. It does not open any buffers, and if a bookmark's buffer is not displayed then (for better or worse) its highlighting is simply applied to the current buffer. `bmkp-light-bookmarks' is meant for bookmark locations that are already displayed. The interactive use cases defined for it are really those that make sense (whether you invoke it interactively or not). Highlighting a bookmark makes little sense if the bookmarked location is not visible. And if it is visible then its buffer is displayed somewhere. Go to the buffer and then highlight bookmarks there. If you turn on `bmkp-auto-light-when-jump' then getting there by jumping takes care of highlighting the location. I don't know what your best bet is. I'd say just customize `bmkp-auto-light-when-jump' and `bmkp-auto-light-when-set' to the value `all-in-buffer'. Then setting or jumping to a bookmark will light all of the bookmarks in its buffer. Or put `bmkp-light-this-buffer' on a hook such as a mode hook or `find-file-hook'. I'd say start by playing with bookmarks a bit: setting them, jumping to them, cycling among them, etc. Play with autonamed bookmarks, which are particularly useful with highlighting. Once you find out how you will actually be using bookmarks, you will, I think, discover how you want them to make use of highlighting.