3

I'm trying to get used to multiple-cursors. It's super useful but the way it interacts with many emacs builtin functions seems weird - perhaps I just don't quite understand how it works.

Eg. my current goal was editing a bunch of constants to add a k in front, easily done, but then the next character is currently lowercase and I want it to be upcase. upcase-word won't work because I want it to retain the camelcase chars in the word - so I can select a region with C-[:space:] C-f and now have a disjoint region covering all the characters to uppercase. But then upcase-region does nothing :(

Can someone explain what I'm missing?

2
  • 2
    Are you running upcase-region using M-x? If not, try using C-x C-u instead. Multiple cursors doesn't seem to work well with manually invoked commands. For me it works using the shortcut. Commented Mar 16, 2018 at 19:34
  • As an alternative, perhaps you can just use a simple keyboard macro. Get to the next "constant" (however you define that), by searching or whatever, then insert k in front. (Repeat the macro with a large prefix arg.) Commented Mar 16, 2018 at 20:15

1 Answer 1

3

You may have accidentally answered "no" to the question "Do upcase-region for all cursors? (y or n)" at some point in the past, which caused it to be added to C-hv mc/cmds-to-run-once whereas you actually want it to be in C-hv mc/cmds-to-run-for-all.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.