get-buffer
(name)
make-buffer
(name &rest args)
<SUFFIX>
to NAME
in case of name collision before trying <number>
.revert-buffer
on the new
buffer.get-buffer-create
(name &rest args)
make-buffer
.on-delete-buffer
(buffer)
Neomacs keep track of the current position being edited using a focus marker.
focus
(&optional (buffer (current-buffer)))
Customize how buffer focus is rendered:
render-focus-aux
(buffer pos)
Neomacs tracks selection with a selection marker. The range between the selection marker and focus marker is considered selected when selection-active
is t
. Certain commands (for example, some clipboard commands) that normally act on focused element will act on the selected range instead if selection is active.
selection-marker
(object)
selection-active
(object)
C-x b
): switch-to-buffer
(buffer &optional (victim (focused-buffer)))
bury-buffer
(&optional (buffer (current-buffer)))
C-x k
): delete-buffer
(buffer)
s-k
): delete-this-buffer
()
There is also a dedicated list mode for managing buffers:
list-buffers
()
load-url
(buffer url)
on-buffer-loaded
is triggered
when URL finishes loading. We use this instead of Electron's
did-finish-load
event because the latter doesn't carry url
information, and getting url with webContents.getURL()
isn't
reliable because it may get the URL of a later issued unfinished load
operation.load-status
(object)
on-buffer-dom-ready
(buffer)
on-buffer-loaded
(buffer url err)
on-buffer-did-start-navigation
(buffer details)