Questions tagged [shift-selection]
10 questions
5
votes
3 answers
How to select (and highlight) non-consecutive blocks?
The title says it all.
I'm looking for a C- or M- built-in way to select non-consecutive lines and blocks of text, like usual consecutive lines with Shift or C-SPC.
I.e. I need a switch that turn selecting off and back on, but previous selections…

iantonuk
- 151
- 1
- 4
4
votes
2 answers
Custom C-arrow cursor movement
I was not satisfied with the behavior of standard C-arrow and C-S-arrow, so I wrote this functions to replace standard ones.
(setq separators-regexp "[\-'\"();:,.\\/?!@#%&*+=]")
(defun forward-to-separator()
"Move to the next separator like in…
user13047
3
votes
3 answers
Which commands/functions/processes are run on keyboard input S-?
Emacs help shown using C-h k S- states only:
(translated from S-) runs the command right-char (found
in global-map), which is an interactive byte-compiled Lisp function in
‘bindings.el’.
It is bound to .
It doesn't also…

Claudio
- 410
- 2
- 11
3
votes
2 answers
How to move the cursor to the beginning/end of a shift-selected region by a left/right motion?
In most modern editors, after canceling a selection by a left/right motion, the cursor will be moved to the beginning/end of the previously-selected region correspondingly. Similarly, if we cancel a selection by a up/down motion, the cursor will be…

AhLeung
- 1,083
- 5
- 14
1
vote
2 answers
windmove doesn't recognize S- and S- on Macbook Terminal
GNU Emacs 27.2 in Mac OS terminal (11.4 Big Sur).
Started with
(windmove-default-keybindings)
and found that S- and S- behaved just as and , as if the shift is not detected, whereas S- and S- behaved as…

PartialOrder
- 135
- 5
1
vote
1 answer
shift selection not working for rebound M-{ backward-paragraph
I slightly simplified the keys for backward-paragraph and forward-paragraph:
(global-unset-key (kbd "M-{")) ;; originally backward-paragraph
(global-unset-key (kbd "M-}")) ;; originally forward-paragraph
(global-set-key (kbd "M-[")…

xdavidliu
- 143
- 8
1
vote
1 answer
Make region transient in elisp function
I'm trying to write a function that exits isearch leaving the current match selected "transiently", so that the mark is deactivated by any unshifted movement command.
I've tried to modify this function,
(defun isearch-exit-mark-match ()
"Exit…

Arch Stanton
- 1,525
- 9
- 22
1
vote
1 answer
Make C-S-up handle shift selection under Org-Mode
When shift-select-mode is on (Emacs' default), C-S-up in text mode selects the previous paragraph.
This does not work under Org-Mode, where C-S-up gets translated into C-up, which is mapped to org-backward-paragraph and just moves up, but does not…

scaramouche
- 1,772
- 10
- 24
1
vote
1 answer
Region does not get deselected on move commands using `push-mark` from Elisp
By using shift-select-mode, I can select some region via holding down Shift + arrow keys. When I then stop pushing Shift and press other keys the region get deselected. But this is not the case when using push-mark function from Elisp code - the…

sandric
- 1,221
- 9
- 19
0
votes
1 answer
How can I fix shift-select-mode with own syntax-table
So I have modified syntax table for moving with C-.
(defvar my-wacky-syntax-table
(let ((table (make-syntax-table)))
(modify-syntax-entry ?\( "w" table)
(modify-syntax-entry ?\) "w" table)
table))
(defun…

Pfedj
- 308
- 2
- 11