In emacs, after an operation such as comment-region, the selected region is automatically deselected.
Is there any way of disabling this behaviour?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If the region is deselected, that sounds like you must be using
transient-mark-mode. Intransient-mark-mode, when you execute a command that operates on the region, the region is deselected (in particular, the mark remains, but it is inactive). You can reselect the region (reactivate the mark) usingC-x C-x(exchange-point-and-mark).If you want to disable the deselection entirely, you can turn off
transient-mark-mode. This means that you won’t get any highlighting of the current region, though if you would like to set the mark and highlight the region, you can turn on transient mark mode briefly usingC-<SPC> C-<SPC>orC-u C-x C-x.