If you can choose among markers in all buffers then you need to be able to choose one, and that means identifying the buffer and the marker in it that you want. That is, I believe, the answer to your question of why it is so difficult to navigate among all such markers.
If you use Icicles then you can use command icicle-goto-any-marker
, bound by default to C-0 C-SPC
, to do what you want. It provides, as completion candidates, the markers in all buffers.
More precisely, if option icicle-show-multi-completion-flag
is non-nil
, which it is by default, then a completion candidate is a multi-completion with two parts:
- The name of the marker's buffer
- Text from the beginning of the marker's line
icicle-goto-any-marker
is an interactive compiled Lisp function in
icicles-cmd2.el
.
(icicle-goto-any-marker)
Like icicle-goto-marker
, but lets you visit markers in all buffers.
If user option icicle-show-multi-completion-flag
is non-nil
, then
each completion candidate is has two parts, the first of which is the
name of the marker's buffer, and the second of which is the text from
the marker's line.
By default, candidates are sorted in buffer order and then marker
order, that is, buffer positions. Use C-M-,
or C-,
to change the
sort order. Remember too that you can use C-A
to toggle
case-sensitivity (e.g., for buffer names).
See also command icicle-goto-global-marker
.
The default order of the completion candidates is buffer followed by marker position. That means that you can easily navigate among them (e.g. cycle) in marker-position order. But you can use C-,
to change the sort order to, for example, the order of last use as input. (You can also define whatever other sort order you find most convenient.)
That says that the command is like command icicle-goto-marker
(which is bound by default to C-SPC
with a negative prefix arg). It's doc string tells you about cycling among completion candidates, i.e., moving among the marked positions in order.
icicle-goto-marker
is an interactive compiled Lisp function in
icicles-cmd2.el
.
(icicle-goto-marker)
Go to a marker in this buffer, choosing it by the line that includes it.
If crosshairs.el
is loaded, then the target position is highlighted.
By default, candidates are sorted in marker order, that is, with
respect to their buffer positions. Use C-M-,
or C-,
to change the
sort order.
During completion you can use these keys:
C-RET
- Goto marker named by current completion candidate
C-down
- Goto marker named by next completion candidate
C-up
- Goto marker named by previous completion candidate
C-next
- Goto marker named by next apropos-completion candidate
C-prior
- Goto marker named by previous apropos-completion candidate
C-end
- Goto marker named by next prefix-completion candidate
C-home
- Goto marker named by previous prefix-completion candidate
S-delete
- Delete marker named by current completion candidate
When candidate action and cycling are combined (e.g. C-next
), option
icicle-act-before-cycle-flag
determines which occurs first.
With prefix C-M-
instead of C-
, the same keys (C-M-mouse-2
,
C-M-f1
, C-M-down
, and so on) provide help about candidates.
Use mouse-2
, RET
, or S-RET
to choose a candidate as the final
destination, or C-g
to quit. This is an Icicles command - see
command icicle-mode
.
See also commands icicle-goto-any-marker
and
icicle-goto-global-marker
.