#이맥스리프스: #편집 $kill-region $delete-region
#이맥스리프스: #편집 $kill-region $delete-region
2024-09-15 Note emacslisp killregion notesTODO 해결 코드
닷파일 참고
킬리전에 해묵은 문제를 해결하다.
(kill-region BEG END &optional REGION)
Documentation
Kill ("cut") text between point and mark.
This deletes the text from the buffer and saves it in the kill ring.
The command C-y can retrieve it from there.
(If you want to save the region without killing it, use M-w.)
If you want to append the killed region to the last killed text,
use C-M-w before C-w.
Any command that calls this function is a "kill command".
If the previous command was also a kill command,
the text killed this time appends to the text killed last time
to make one entry in the kill ring.
The killed text is filtered by filter-buffer-substring before it is
saved in the kill ring, so the actual saved text might be different
from what was killed.
If the buffer is read-only, Emacs will beep and refrain from deleting
the text, but put the text in the kill ring anyway. This means that
you can use the killing commands to copy text from a read-only buffer.
둠 이맥스를 보자면, 뭐지 맥에만?!
(when (featurep :system 'macos)
;; Fix MacOS shift+tab
(define-key key-translation-map [S-iso-lefttab] [backtab])
(map! "s-`" #'other-frame ; fix frame-switching
;; fix OS window/frame navigation/manipulation keys
"s-w" #'delete-window
"s-W" #'delete-frame
"s-n" #'+default/new-buffer
"s-N" #'make-frame
;; doom/backward-kill-to-bol-and-indet
;; doom/delete-backward-word
:gi [s-backspace] #'doom/backward-kill-to-bol-and-indent
:gi [s-left] #'doom/backward-to-bol-or-indent
:gi [s-right] #'doom/forward-to-last-non-comment-or-eol
:gi [M-backspace] #'backward-kill-word
:gi [M-left] #'backward-word
:gi [M-right] #'forward-word
))
- spacemacs/backward-kill-word-or-region - global-map M-<backspace>
- delete-region
Related-Notes
References
마지막 수정일자