24

CUA mode is very close to the workflow I am used to outside Emacs, so I am tempted to activate it.

But I have learned that Emacs may have useful gems hidden in its ways, and CUA mode seems something that was attached later on.

I know the benefits of CUA Mode.

But I do not know what I give up by activating it.

Reading the Emacs Info is not very revealing about the pros and cons of Emacs core approach vs CUA mode.

The EmacsWiki section on CUA mode is also not too helpful in that regard.

What are the features that a skilled Emacs user would miss by activating CUA mode?

Jonathan Leech-Pepin
  • 4,307
  • 1
  • 19
  • 32
gsl
  • 1,742
  • 17
  • 34

1 Answers1

21

Here's my opinion, as I don't think there's an absolute answer.

In short, what you “lose” is the added complexity to the key use. Following is more detailed explanation.

Emacs C-x is prefix key for general commands, and C-c is prefix key of current major mode's commands.

CUA mode uses C-x for cut and C-c for copy. In order to avoid conflict, cua uses some tricks. Specifically, when there's text selection (that is, region active), then these keys acts as cut and copy.

But, sometimes emacs commands work differently depending on whether there's a text selection. For example, comment-dwim will act on a text selection if there's one, else just current line. (when you have transient-mark-mode on.) This is a very nice feature introduced since emacs 23 (in year 2009). It means, for many commands, you don't have to first make a selection.

When cua mode is on, and you want to call emacs command with key C-x or C-c, here's quote from the doc:

If you really need to perform a command which starts with one of
the prefix keys even when the region is active, you have three
options:
- press the prefix key twice very quickly (within 0.2 seconds),
- press the prefix key and the following key within 0.2 seconds, or
- use the SHIFT key with the prefix key, i.e. C-S-x or C-S-c.

So, essentially you have complexities.

I used cua mode for several years around 2006 to 2011. Now I don't, because I basically remapped ALL emacs one thousand keys except the arrow keys.

Xah Lee
  • 1,756
  • 12
  • 11