Emacs: pulsar version 1.1.0
Pulsar is a small package that temporarily highlights the current line, either on demand or automatically after invoking a function that is present in a user-defined list. Watch the demo
- Package name (GNU ELPA):
pulsar
- Official manual: https://protesilaos.com/emacs/pulsar
- Change log: https://protesilaos.com/emacs/pulsar-changelog
- Git repositories:
- Backronym: Pulsar Unquestionably Luminates, Strictly Absent the Radiation.
Below are the release notes.
Version 1.1.0 on 2024-08-29
This version includes quality-of-life refinements to an already stable package.
Function aliases are recognised automatically
Pulsar will produce a highlight on the current line after one of the
functions in pulsar-pulse-functions
is used. This now works for
aliases of those functions as well, even if they are not explicitly
referenced in pulsar-pulse-functions
. Whereas before, only the
explicitly named functions would produce the pulse effect.
Thanks to shipmints for the contribution, which was originally done in in pull request 12 and then refined over a series of commits: https://github.com/protesilaos/pulsar/pull/12. The author has assigned copyright to the Free Software Foundation.
Users who want to opt out of this behaviour, can set the user option
pulsar-resolve-pulse-function-aliases
to a nil value.
The next-multiframe-window
will produce a pulse by default
This command is added to the pulsar-pulse-functions
. It is
consistent with what we do with the other-window
command.
Thanks to Maxim Dunaevsky for the contribution. This was done in pull request 6: https://github.com/protesilaos/pulsar/pull/6. The change is small, meaning that Maxim does not need to assign copyright to the Free Software Foundation.
More common commands will pulse the current line
I added the following to pulsar-pulse-functions
:
evil-goto-first-line
evil-goto-line
evil-scroll-down
evil-scroll-line-to-bottom
evil-scroll-line-to-center
evil-scroll-line-to-top
evil-scroll-up
goto-line
handle-switch-frame
logos-backward-page-dwim
logos-forward-page-dwim
narrow-to-defun
narrow-to-page
narrow-to-region
widen
If you are using setq
, setopt
, the :custom
keyword of
use-package
, or related, make sure to update the value accordingly.
You do not need to do anything if you are doing it with add-to-list
.
Pulse a region with pulsar-pulse-region
The command pulsar-pulse-region
pulses the active region. Thanks to
Bahman Movaqar for the contribution. This was done on the
now-deprecated mailing list:
https://lists.sr.ht/~protesilaos/pulsar/169317951630.22395.14797122445974295748-0@git.sr.ht
The change is below the ~15 line limit and thus Bahman is not require to assign copyright to the Free Software Foundation.
I still want to make this work with rectangular regions, which are not contiguous (in terms of character positions reading from left to right), but it is tricky. Maybe I will do it for the next version.
Remember that the command pulsar-highlight-dwim
will apply a
temporary highlight to the active region or the current line. The
highlight is removed as soon as another key is pressed.