Skip to content

Add functions to restore custom buffer bookmark properties#56

Open
shipmints wants to merge 3 commits into
florommel:mainfrom
shipmints:shipmints-bufferlo-bookmark-buffer-handler-functions
Open

Add functions to restore custom buffer bookmark properties#56
shipmints wants to merge 3 commits into
florommel:mainfrom
shipmints:shipmints-bufferlo-bookmark-buffer-handler-functions

Conversation

@shipmints
Copy link
Copy Markdown
Collaborator

  • New defcustoms 'bufferlo-bookmark-buffer-locals',
    'bufferlo-bookmark-buffer-handler-functions'.
  • New defuns 'bufferlo-bookmark-map-function-buffer-locals',
    'bufferlo-bookmark-buffer-handler-buffer-locals',
    'bufferlo-bookmark-map-function-text-scale-mode-amount',
    'bufferlo-bookmark-buffer-handler-text-scale-mode-amount'.
  • Update documentation.

This is better than our custom code.
- New defcustoms 'bufferlo-bookmark-buffer-locals',
'bufferlo-bookmark-buffer-handler-functions'.
- New defuns 'bufferlo-bookmark-map-function-buffer-locals',
'bufferlo-bookmark-buffer-handler-buffer-locals',
'bufferlo-bookmark-map-function-text-scale-mode-amount',
'bufferlo-bookmark-buffer-handler-text-scale-mode-amount'.
- Update documentation.
@shipmints shipmints force-pushed the shipmints-bufferlo-bookmark-buffer-handler-functions branch from 5e517fc to 7b34bd7 Compare November 1, 2025 14:32
@shipmints
Copy link
Copy Markdown
Collaborator Author

I suppose the configuration of these two features could be simplified like we handle ibuffer integration. The hooks need to be installed in pairs so we could automate this. Nobody will want to have only half the hooks installed, right?

@shipmints
Copy link
Copy Markdown
Collaborator Author

Done.

@shipmints
Copy link
Copy Markdown
Collaborator Author

Flo, should I merge this or do you have anything outstanding?

Copy link
Copy Markdown
Owner

@florommel florommel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a nit, bufferlo-bookmark-buffer-locals and bufferlo-bookmark-text-scale-mode-amount seem to be flipped in the README's code examples.

Comment thread README.org

#+begin_src emacs-lisp
;; To persist text-scale-mode-amount
(setq bufferlo-bookmark-buffer-locals t)
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be bufferlo-bookmark-text-scale-mode-amount, right?

Comment thread README.org

#+begin_src emacs-lisp
;; To persist buffer-local variables
(setq bufferlo-bookmark-text-scale-mode-amount t)
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and this should be bufferlo-bookmark-buffer-locals

@florommel
Copy link
Copy Markdown
Owner

I also think that we don't need e2cf46e anymore.
Have a look at this branch: florommel-bufferlo-bookmark-buffer-handler-functions
I rebased it, removed e2cf46e and fixed the meantioned README nit. The bookmark handler feature hooks work fine for me (very cool, now I can save my but also have a quick look, then we can merge it.

PS: Great stuff, I just discovered the power of this.. now I can persist my symbol overlays with:

(setq bufferlo-bookmark-buffer-local-variables '(symbol-overlay-keywords-alist))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants