* Movement commands and caps lock
@ 2012-08-12 17:24 Roberto E. Vargas Caballero
2012-08-15 3:27 ` Stefan Monnier
0 siblings, 1 reply; 5+ messages in thread
From: Roberto E. Vargas Caballero @ 2012-08-12 17:24 UTC (permalink / raw)
To: emacs-devel
Hello,
There is a strange behaviour in emacs running in graphical mode. If caps
lock is enabled and I push some movement combination (for example C-a or
C-n), then emacs selects the text, like if the region is active. If I push
C-h k C-b (with caps lock enabled) I get:
C-b (translated from C-S-b) runs the command backward-char
But if I do this same test in text mode I don't get any behaviour related to
the selection and the result of C-h k C-b is:
C-b runs the command backward-char
Without the '(translated from C-S-b)' message that it shows in graphical
mode.
This behaviour does almost impossible any editing with caps lock enabled,
and it is not coherent different behaviours in graphical or text modes.
Tested with Emacs 24.1.50.1 and with --no-init flag.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Movement commands and caps lock
2012-08-12 17:24 Movement commands and caps lock Roberto E. Vargas Caballero
@ 2012-08-15 3:27 ` Stefan Monnier
2012-08-15 6:29 ` Roberto E. Vargas Caballero
0 siblings, 1 reply; 5+ messages in thread
From: Stefan Monnier @ 2012-08-15 3:27 UTC (permalink / raw)
To: k0ga; +Cc: emacs-devel
> But if I do this same test in text mode I don't get any behaviour related to
> the selection and the result of C-h k C-b is:
> C-b runs the command backward-char
> Without the '(translated from C-S-b)' message that it shows in graphical
> mode.
IIUC, by "text mode" you don't mean M-x text-mode RET ubt you mean that
Emacs is running in a something like a Linux console or an xterm, right?
Then the difference is simply that the processing of caps-lock is done
by xterm so Emacs never gets to know that caps-lock is enabled.
> This behaviour does almost impossible any editing with caps lock enabled,
> and it is not coherent different behaviours in graphical or text modes.
IIRC the processing of caps lock is OS dependent, but assuming you're
running with an X11 display, then it might even depend on the exact kind
of "lock" you're using (I seem to remember that the behavior might
depend on things such as whether the key is a shift-lock or caps-lock).
Stefan
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Movement commands and caps lock
2012-08-15 3:27 ` Stefan Monnier
@ 2012-08-15 6:29 ` Roberto E. Vargas Caballero
2012-08-15 14:34 ` Davis Herring
2012-08-15 14:36 ` Andreas Schwab
0 siblings, 2 replies; 5+ messages in thread
From: Roberto E. Vargas Caballero @ 2012-08-15 6:29 UTC (permalink / raw)
To: Stefan Monnier; +Cc: emacs-devel
> IIUC, by "text mode" you don't mean M-x text-mode RET ubt you mean that
> Emacs is running in a something like a Linux console or an xterm, right?
Yes, text mode here means that emacs is not running as an X application.
> IIRC the processing of caps lock is OS dependent, but assuming you're
> running with an X11 display, then it might even depend on the exact kind
> of "lock" you're using (I seem to remember that the behavior might
> depend on things such as whether the key is a shift-lock or caps-lock).
This is something logical, but why the mark behaviour?. Emacs translate
it from C-S-b to C-b, so the expected result should be backward-char, not
set-mark and backward-char.
Roberto.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Movement commands and caps lock
2012-08-15 6:29 ` Roberto E. Vargas Caballero
@ 2012-08-15 14:34 ` Davis Herring
2012-08-15 14:36 ` Andreas Schwab
1 sibling, 0 replies; 5+ messages in thread
From: Davis Herring @ 2012-08-15 14:34 UTC (permalink / raw)
To: k0ga; +Cc: Stefan Monnier, emacs-devel
> This is something logical, but why the mark behaviour?. Emacs translate
> it from C-S-b to C-b, so the expected result should be backward-char, not
> set-mark and backward-char.
Because (to follow CUA editing style) shift+motion nowadays sets the
mark and then moves so as to "drag" the region over the range of point's
motion. You can customize `shift-select-mode'.
Davis
--
This product is sold by volume, not by mass. If it appears too dense or
too sparse, it is because mass-energy conversion has occurred during
shipping.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Movement commands and caps lock
2012-08-15 6:29 ` Roberto E. Vargas Caballero
2012-08-15 14:34 ` Davis Herring
@ 2012-08-15 14:36 ` Andreas Schwab
1 sibling, 0 replies; 5+ messages in thread
From: Andreas Schwab @ 2012-08-15 14:36 UTC (permalink / raw)
To: k0ga; +Cc: Stefan Monnier, emacs-devel
"Roberto E. Vargas Caballero" <k0ga@shike2.com> writes:
> This is something logical, but why the mark behaviour?. Emacs translate
> it from C-S-b to C-b, so the expected result should be backward-char, not
> set-mark and backward-char.
You get the same result if you type Ctrl-Shift-b, see shift-select-mode.
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2012-08-15 14:36 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-12 17:24 Movement commands and caps lock Roberto E. Vargas Caballero
2012-08-15 3:27 ` Stefan Monnier
2012-08-15 6:29 ` Roberto E. Vargas Caballero
2012-08-15 14:34 ` Davis Herring
2012-08-15 14:36 ` Andreas Schwab
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).