emacs在mac os x中拖拽文件到buffer会在buffer中嵌入显示拖拽文件的内容,解决办法:

.emacs中加入

1
2
3
4
5
6
(define-key global-map [ns-drag-file] 'my-ns-open-files)
(defun my-ns-open-files ()
  "Open files in the list `ns-input-file'."
  (interactive)
  (mapc 'find-file ns-input-file)
  (setq ns-input-file nil))