Questions tagged [mark-ring]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
1 vote
2 answers

Looking for a "point ring"

Is there something like a point ring in Emacs? I would like to store the current point in there using a command similar to point-to-register. But when I store another point, I want the previous one ...
Witek's user avatar
  • 333
0 votes
1 answer

Jump to global mark ring after jumping to register

In buffer B, I press C-x r SPC r to store the position of point. I switch to buffer A and do some work. I then press C-x r j r to return to the position I saved in buffer B. How do I get back to the ...
SabreWolfy's user avatar
  • 1,358
1 vote
1 answer

How do I clear all marks from the current buffer mark ring?

Newbie here, but oddly I couldn't find an answer to this by Googling. How do I clear all marks from the current buffer? I did find how to view the mark ring, but not how to clear all marks from ...
Peter Dowling's user avatar
3 votes
1 answer

calling xref-find-definitions within lisp code

I want to call xref-find-definitions from within my own lisp code and I'm struggling. (xref-find-definitions IDENTIFIER) Find the definition of the identifier at point. It wants a parameter ...
Haydon Berrow's user avatar
7 votes
3 answers

How do I view the mark ring?

Is there a command to view the entries in the mark ring, similar to listing buffers with C-x C-b or viewing the kill ring with the function browse-kill-ring or viewing the jump list (in info mode) ...
extremeaxe5's user avatar
1 vote
0 answers

Implement vim's Ctrl-O and Ctrl-I in emacs

I find this to be a great feature from vim, and I miss it. I've looked around, and it seems that one can add the current position to some mark ring, and then come back. But that's explicit. I need to ...
Ivan Perez's user avatar
0 votes
1 answer

Why is the mark ring called a 'ring' and not a 'stack'?

From the description of the mark ring on the Emacs website (link) it seems to me that it is basically just a stack with a maximum size set to be 16. So I am curious why this data-structure is called a ...
smilingbuddha's user avatar
0 votes
1 answer

How can I return back to point position after jumping by `<down-mouse-1>`?

How can I return back to point position after jumping by <down-mouse-1>? Example: moving in the buffer for a while with C-pbfn, then use mouse for navigation, and press C-u C-<space> ...
Netsu's user avatar
  • 545
1 vote
1 answer

Traversing the mark rings when combining global and local jumps in Emacs

I am wondering why it is so difficult to go back when you mix local and global jumps in Emacs. Maybe I am missing something. For example, if I am in buffer 1 and jump to position 100 (for example ...
Håkon Hægland's user avatar
4 votes
1 answer

What are the differences mark-ring and global-mark-ring?

I have just explore how to use mark rings in emacs. There are two kind of mark type mark-ring and global-mark-ring. What are the differences between them and is there any option to push all marks ...
itirazimvar's user avatar
0 votes
1 answer

How to automatically set marks on all of the edited lines?

I would like to automatically set marks on all of the edited lines so that I can go back to any of my previous edited lines using helm-mark-ring.
AhLeung's user avatar
  • 1,063
2 votes
1 answer

How to make helm-mark-ring/helm-imenu follow current candidate

When I use helm-mark-ring or helm-imenu, I would like to jump to the current candidate automatically in the other buffer while keeping the helm session (i.e., similar to helm-swoop). I tried the ...
AhLeung's user avatar
  • 1,063
2 votes
1 answer

Back/forward navigation that works like IntelliJ/Eclipse

I've been trying to find a navigation package that allows backwards/forwards navigation across and within buffers. I have found a lot of solutions out there but none of them seem to solve the whole ...
leeor's user avatar
  • 141
9 votes
1 answer

How to set mark in elisp and have shift selection?

The normal behavior of Emacs when transient-mark-mode is active is that when you make a shift-selection, then if the next command is a non-shift movement, the mark is deactivated. For example, after ...
mikl's user avatar
  • 413
4 votes
2 answers

Activating the region without altering the mark ring

Setting the mark and moving point activates the region, which appears highlighted (assuming transient-mark-mode is enabled). Once the mark is set it's location is sent to the mark ring, thus changing ...
undostres's user avatar
  • 1,773
2 votes
1 answer

pop-mark not working as expected

I have some sample code like this: (defun some-function () (interactive) (push-mark) (goto-char (point-min)) ; do some stuff (pop-mark)) Now I'm expecting pop-mark to get me back to the ...
Sibi's user avatar
  • 3,583
2 votes
2 answers

How to jump to a mark using Elisp

Suppose I store the current mark into a variable using mark or (mark-marker). Then I move point elsewhere and insert some text. Which function should I use to jump to the saved mark?
Tu Do's user avatar
  • 6,742
48 votes
12 answers

How to switch back and forth between two locations in a buffer

Sometimes I find myself frequently alternating between two functions that I am editing in conjunction with each other. In these situations, it is tedious and painful to keep on doing a C-s <...
Vedaad Shakib's user avatar
41 votes
6 answers

Effectively using the mark ring

I have used the mark to select regions of a buffer. For example, I know the sequence C-<space> C-s foo can be used to select all text between the current point and the point after a search for ...
Patrick Steele's user avatar