emacs-devel
[Top][All Lists]
Advanced

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

Re: A feature to go to last edit locations


From: Jean Louis
Subject: Re: A feature to go to last edit locations
Date: Mon, 13 Feb 2023 23:56:07 +0300
User-agent: Mutt/2.2.9+54 (af2080d) (2022-11-21)

* Dmitry Gutov <dgutov@yandex.ru> [2023-02-13 22:43]:
> On 13/02/2023 21:24, Jean Louis wrote:
> > But Eli said something important, why go somewhere back randomly, but
> > better going where user marked it to need it.
> 
> Because by the time the user knows they need to go back, they might have
> missed the opportunity to mark the place.

Yes, right.

Drew mentioned "temporary bookmark", and I implemented it in my system
already:

Instead of this:

(defun rcd-db-emacs-point-next ()
  "Go to next Emacs point."
  (interactive)
  (let ((next (rcd-db-emacs-point-to-go "next")))
    next))

I made this:

(defun rcd-db-emacs-point-next ()
  "Go to next Emacs point."
  (interactive)
  (rcd-db-emacs-point-record t)
  (let ((next (rcd-db-emacs-point-to-go "next")))
    next))

and then

(defun rcd-db-emacs-point-record (&optional temporary)
  "Record Emacs point in the database."
  (interactive)
  (let* ((buffer-name (buffer-name))

As if I am jumping now from this temporary mail buffer, even this is
recorded, I can come back from jump, very handy.

It is similar to changing buffers or browsing bookmarks in circle.

When storing it in the database, it is possible to list it:

 30         File: /home/data1/protected/Programming/emacs-lisp/rcd-cf.el
 33         Buffer: RCD Notes Dashboard
 35         Buffer: RCD Notes Dashboard
 47         Buffer: RCD Notes Dashboard
 65         File: 
/home/data1/protected/Programming/Software/emacs/lisp/windmove.el

And then user could just mark some of them, and designate a "narrow
session", a narrowed ring of files, buffers through which one can
float, or move from one to each other, but not to something else.

-- 
Jean

Take action in Free Software Foundation campaigns:
https://www.fsf.org/campaigns

In support of Richard M. Stallman
https://stallmansupport.org/



reply via email to

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