3

I have installed the multiple-cursors package but, I cannot manage to work properly. Only one cursor can be modified, the rest of the cursors do nothing.

I have configured my .emacs file for the multi-cursors package as is shown below:

(require 'multiple-cursors)
(global-set-key (kbd "C-c m c") 'mc/edit-lines)
(global-set-key (kbd "C->") 'mc/mark-next-like-this)
(global-set-key (kbd "C-<") 'mc/mark-previous-like-this)
(global-set-key (kbd "C-c C-<") 'mc/mark-all-like-this)

Can anybody help with this? Thanks.

Marco
  • 33
  • 4
  • I guess some other package is interfering. Try commenting out everything in your config file except for the lines quoted above, and see if multiple-cursors works. If so, uncomment one bit after the other until you find the one that causes the problem. – legoscia Sep 23 '19 at 09:06
  • Maybe this helps: https://emacs.stackexchange.com/a/51834/19819 – Hubisan Sep 25 '19 at 08:56

1 Answers1

7

My crystal ball tells me that once upon a time the original poster was presented with an interactive question asking him/her whether to perform the same command for all cursors; and, the O.P. answered the question with a "no". Whereupon the Multiple Cursors package added an entry to the mc/lists-file, which has a default location of: (locate-user-emacs-file ".mc-lists.el") -- see https://github.com/magnars/multiple-cursors.el/blob/master/multiple-cursors-core.el#L627

The O.P. should open up the above-mentioned file and see if his/her prior choice should be manually removed. The file contains something like this:

;; This file is automatically generated by the multiple-cursors extension.
;; It keeps track of your preferences for running commands with multiple cursors.

(setq mc/cmds-to-run-for-all
      '(
      my-custom-function-one
      org-self-insert-command
      ))

(setq mc/cmds-to-run-once
      '(
      mime-preview-scroll-down-entity
      my-custom-function-two
      ))


(provide '.multiple_cursors)
lawlist
  • 12,283
  • 2
  • 31
  • 129