4
커서를 버퍼 주위로 움직일 때 버퍼의 여러 부분을 강조 표시하는 마이너 모드를 작성했습니다. 나는 이와 같은 운동 기능을 조언함으로써 이것을한다.Emacs 커서 이동 어드 바이스
...
(defadvice next-line (after showcss/advise-main)
"Advice around cursor movement"
(highlight-some-stuff))
(defadvice previous-line (after showcss/advise-main)
"Advice around cursor movement"
(highlight-some-stuff))
(defadvice right-char (after showcss/advise-main)
"Advice around cursor movement"
(highlight-some-stuff))
(defadvice left-char (after showcss/advise-main)
"Advice around cursor movement"
(highlight-some-stuff))
(defadvice forward-word (after showcss/advise-main)
"Advice around cursor movement"
(highlight-some-stuff))
(defadvice backward-word (after showcss/advise-main)
"Advice around cursor movement"
(highlight-some-stuff))
...
하지만이 방법은 잘못된 것 같습니다. 나는 커서 움직임에 대한 후크를 찾았지만 하나 인 것처럼 보이지 않는다.
운동 기능을 조언하는 대신 사용할 수있는 훅이 없거나이를 해결하는 더 좋은 방법이 있습니까?