[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Advice on studying Emacs Lisp files

From: Drew Adams
Subject: RE: Advice on studying Emacs Lisp files
Date: Mon, 26 Jan 2015 16:39:21 -0800 (PST)

> >> 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':
> 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

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

reply via email to

[Prev in Thread] Current Thread [Next in Thread]