GNU bug report logs -
#18952
24.4; delete weirdness in cua mode
Previous Next
Reported by: Andy Grover <andy <at> groveronline.com>
Date: Wed, 5 Nov 2014 07:13:02 UTC
Severity: normal
Found in version 24.4
Fixed in version 24.5
Done: Stefan Monnier <monnier <at> iro.umontreal.ca>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 18952 in the body.
You can then email your comments to 18952 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#18952
; Package
emacs
.
(Wed, 05 Nov 2014 07:13:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Andy Grover <andy <at> groveronline.com>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Wed, 05 Nov 2014 07:13:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
to reproduce:
1) hold down up or down-arrow while editing init.el then release
2) hit backspace
expected behavior: one character deleted
existing behavior: seemingly-random huge amount of stuff in the buffer
deleted
Thanks -- Andy
In GNU Emacs 24.4.1 (x86_64-redhat-linux-gnu, GTK+ Version 3.14.3)
of 2014-10-27 on buildhw-05.phx2.fedoraproject.org
Windowing system distributor `Fedora Project', version 11.0.11601000
Configured using:
`configure --build=x86_64-redhat-linux-gnu
--host=x86_64-redhat-linux-gnu --program-prefix=
--disable-dependency-tracking --prefix=/usr --exec-prefix=/usr
--bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc
--datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64
--libexecdir=/usr/libexec --localstatedir=/var
--sharedstatedir=/var/lib --mandir=/usr/share/man
--infodir=/usr/share/info --with-dbus --with-gif --with-jpeg --with-png
--with-rsvg --with-tiff --with-xft --with-xpm --with-x-toolkit=gtk3
--with-gpm=no build_alias=x86_64-redhat-linux-gnu
host_alias=x86_64-redhat-linux-gnu 'CFLAGS=-DMAIL_USE_LOCKF -O2 -g
-pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2
-fexceptions -fstack-protector-strong --param=ssp-buffer-size=4
-grecord-gcc-switches -m64 -mtune=generic' 'LDFLAGS=-Wl,-z,relro ''
Important settings:
value of $LANG: en_US.utf8
value of $XMODIFIERS: @im=ibus
locale-coding-system: utf-8-unix
Major mode: Emacs-Lisp
Minor modes in effect:
superword-mode: t
delete-selection-mode: t
show-paren-mode: t
desktop-save-mode: t
cua-mode: t
tooltip-mode: t
electric-indent-mode: t
mouse-wheel-mode: t
tool-bar-mode: t
global-prettify-symbols-mode: t
prettify-symbols-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
blink-cursor-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
size-indication-mode: t
column-number-mode: t
line-number-mode: t
Recent input:
C-s <up> <prior> <prior> <prior> <prior> <prior> <prior>
<next> <next> <down> <down> <down> <down> <down> <down>
<down> <down> <S-down> <S-down> <S-down> <S-down> <S-down>
<S-down> <S-down> <S-down> <S-down> <S-down> <S-down>
<S-down> C-c <timeout> <up> <up> <up> <up> <up> <right>
<up> <up> <right> <right> <right> <right> <right> <right>
<right> <right> <right> <right> <right> <right> <right>
<backspace> C-z <backspace> C-z <up> <up> <up> <up>
<up> <up> <down> <down> <down> <down> <down> <down>
<down> <down> <backspace> C-z C-SPC <up> <up> <right>
<right> <right> <right> <right> <backspace> C-z C-SPC
<backspace> C-z <up> <down> <down> <down> <down> <down>
<down> <down> <down> <down> <down> <down> <down> <down>
<down> <down> <down> <down> <down> <down> <down> <down>
<down> <down> <down> <down> <up> <up> <up> <up> <up>
<up> <up> <up> <up> <up> <up> <up> <down> <down> <down>
<down> <down> <down> <down> <down> <down> <down> <down>
<down> <down> <down> <down> <down> <down> <up> <up>
<up> <up> <up> <up> <up> <up> <up> <up> <up> <up> <up>
<up> <up> <backspace> C-z <down> <down> <down> <down>
<down> <down> <down> <down> <down> <down> <down> <down>
<down> <down> <down> <down> <down> <down> <up> <up>
<up> <up> <up> <up> <up> <up> <up> <up> <up> <down-mouse-4>
<mouse-4> <double-down-mouse-4> <double-mouse-4> <triple-down-mouse-4>
<triple-mouse-4> <triple-down-mouse-4> <triple-mouse-4>
<triple-down-mouse-4> <triple-mouse-4> <triple-down-mouse-4>
<triple-mouse-4> <triple-down-mouse-4> <triple-mouse-4>
<down-mouse-4> <mouse-4> <double-down-mouse-4> <double-mouse-4>
<triple-down-mouse-4> <triple-mouse-4> <triple-down-mouse-4>
<triple-mouse-4> <triple-down-mouse-4> <triple-mouse-4>
<triple-down-mouse-4> <triple-mouse-4> <triple-down-mouse-4>
<triple-mouse-4> <triple-down-mouse-4> <triple-mouse-4>
<triple-down-mouse-4> <triple-mouse-4> <triple-down-mouse-4>
<triple-mouse-4> <triple-down-mouse-4> <triple-mouse-4>
<down-mouse-5> <mouse-5> <double-down-mouse-5> <double-mouse-5>
<triple-down-mouse-5> <triple-mouse-5> <triple-down-mouse-5>
<triple-mouse-5> <triple-down-mouse-5> <triple-mouse-5>
<triple-down-mouse-5> <triple-mouse-5> <triple-down-mouse-5>
<triple-mouse-5> <down-mouse-5> <mouse-5> <double-down-mouse-5>
<double-mouse-5> <triple-down-mouse-5> <triple-mouse-5>
<triple-down-mouse-5> <triple-mouse-5> <triple-down-mouse-5>
<triple-mouse-5> <down-mouse-4> <mouse-4> <double-down-mouse-4>
<double-mouse-4> <triple-down-mouse-4> <triple-mouse-4>
<triple-down-mouse-4> <triple-mouse-4> <triple-down-mouse-4>
<triple-mouse-4> <triple-down-mouse-4> <triple-mouse-4>
<triple-down-mouse-4> <triple-mouse-4> <triple-down-mouse-4>
<triple-mouse-4> <triple-down-mouse-4> <triple-mouse-4>
<triple-down-mouse-4> <triple-mouse-4> <triple-down-mouse-4>
<triple-mouse-4> <triple-down-mouse-4> <triple-mouse-4>
<triple-down-mouse-4> <triple-mouse-4> <triple-down-mouse-4>
<triple-mouse-4> <triple-down-mouse-4> <triple-mouse-4>
<triple-down-mouse-4> <triple-mouse-4> <triple-down-mouse-4>
<triple-mouse-4> <help-echo> <help-echo> <help-echo>
<help-echo> <help-echo> <menu-bar> <help-menu> <emacs-known-problems>
M-w <help-echo> <help-echo> <help-echo> <help-echo>
<help-echo> <help-echo> <help-echo> <menu-bar> <help-menu>
<send-emacs-bug-report>
Recent messages:
cua-scroll-down: Beginning of buffer
Mark set
Undo! [3 times]
Mark cleared
Undo!
Mark cleared
Undo! [2 times]
byte-code: Beginning of buffer [20 times]
Note: file is write protected
View mode: type C-h for help, h for commands, q to quit.
Load-path shadows:
/home/agrover/.emacs.d/elpa/flymake-0.4.16/flymake hides
/usr/share/emacs/24.4/lisp/progmodes/flymake
Features:
(shadow sort gnus-util mail-extr emacsbug message format-spec rfc822 mml
mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev
gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util
help-fns mail-prsvr mail-utils goto-addr thingatpt noutline outline
easy-mmode view python json comint ring ansi-color vc-git flycheck
find-func help-mode rx pcase subr-x dash cc-styles cc-align cc-engine
cc-vars cc-defs midnight ido swbuff superword subword flymake-autoloads
info easymenu pkg-info-autoloads epl-autoloads rust-mode-autoloads
cm-mode-autoloads package epg-config saveplace delsel paren desktop
frameset cl-loaddefs cl-lib cua-base cus-start cus-load time-date
tooltip electric uniquify ediff-hook vc-hooks lisp-float-type mwheel
x-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list
newcomment lisp-mode prog-mode register page menu-bar rfn-eshadow timer
select scroll-bar mouse jit-lock font-lock syntax facemenu font-core
frame cham georgian utf-8-lang misc-lang vietnamese tibetan thai
tai-viet lao korean japanese hebrew greek romanian slovak czech european
ethiopic indian cyrillic chinese case-table epa-hook jka-cmpr-hook help
simple abbrev minibuffer nadvice loaddefs button faces cus-face macroexp
files text-properties overlay sha1 md5 base64 format env code-pages mule
custom widget hashtable-print-readable backquote make-network-process
dbusbind gfilenotify dynamic-setting system-font-setting
font-render-setting move-toolbar gtk x-toolkit x multi-tty emacs)
Memory information:
((conses 16 146580 5509)
(symbols 48 25089 0)
(miscs 40 60 154)
(strings 32 31826 5250)
(string-bytes 1 941333)
(vectors 16 16342)
(vector-slots 8 451999 3474)
(floats 8 99 375)
(intervals 56 802 4)
(buffers 960 14)
(heap 1024 49667 1054))
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#18952
; Package
emacs
.
(Wed, 05 Nov 2014 16:04:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 18952 <at> debbugs.gnu.org (full text, mbox):
> Date: Tue, 04 Nov 2014 23:11:41 -0800
> From: Andy Grover <andy <at> groveronline.com>
>
>
> to reproduce:
> 1) hold down up or down-arrow while editing init.el then release
> 2) hit backspace
>
> expected behavior: one character deleted
>
> existing behavior: seemingly-random huge amount of stuff in the buffer
> deleted
Are you sure you didn't type S-<down> several times? This:
> Recent input:
> C-s <up> <prior> <prior> <prior> <prior> <prior> <prior>
> <next> <next> <down> <down> <down> <down> <down> <down>
> <down> <down> <S-down> <S-down> <S-down> <S-down> <S-down>
> <S-down> <S-down> <S-down> <S-down> <S-down> <S-down>
> <S-down> C-c <timeout> <up> <up> <up> <up> <up> <right>
> <up> <up> <right> <right> <right> <right> <right> <right>
> <right> <right> <right> <right> <right> <right> <right>
> <backspace> C-z <backspace> C-z <up> <up> <up> <up>
says you did.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#18952
; Package
emacs
.
(Wed, 05 Nov 2014 19:03:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 18952 <at> debbugs.gnu.org (full text, mbox):
On 11/05/2014 08:03 AM, Eli Zaretskii wrote:
>> Date: Tue, 04 Nov 2014 23:11:41 -0800
>> From: Andy Grover <andy <at> groveronline.com>
>>
>>
>> to reproduce:
>> 1) hold down up or down-arrow while editing init.el then release
>> 2) hit backspace
>>
>> expected behavior: one character deleted
>>
>> existing behavior: seemingly-random huge amount of stuff in the buffer
>> deleted
>
> Are you sure you didn't type S-<down> several times? This:
>
>> Recent input:
>> C-s <up> <prior> <prior> <prior> <prior> <prior> <prior>
>> <next> <next> <down> <down> <down> <down> <down> <down>
>> <down> <down> <S-down> <S-down> <S-down> <S-down> <S-down>
>> <S-down> <S-down> <S-down> <S-down> <S-down> <S-down>
>> <S-down> C-c <timeout> <up> <up> <up> <up> <up> <right>
>> <up> <up> <right> <right> <right> <right> <right> <right>
>> <right> <right> <right> <right> <right> <right> <right>
>> <backspace> C-z <backspace> C-z <up> <up> <up> <up>
>
> says you did.
>
Yes exactly, define a region with shift-down, then arrow down (region
disappears) then hitting backspace deletes to start of region, instead
of a single character.
Setting transient-mark-mode makes the problem go away. But isn't
cua-mode supposed to work without transient-mark-mode?
-- Andy
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#18952
; Package
emacs
.
(Wed, 05 Nov 2014 20:17:01 GMT)
Full text and
rfc822 format available.
Message #14 received at 18952 <at> debbugs.gnu.org (full text, mbox):
> Setting transient-mark-mode makes the problem go away. But isn't
> cua-mode supposed to work without transient-mark-mode?
Yes, it works. But clearly, some of the interactions haven't been
tested yet.
You could have mentioned earlier that you disabled transient-mark-mode.
Stefan
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#18952
; Package
emacs
.
(Wed, 05 Nov 2014 20:30:03 GMT)
Full text and
rfc822 format available.
Message #17 received at 18952 <at> debbugs.gnu.org (full text, mbox):
On 11/05/2014 12:16 PM, Stefan Monnier wrote:
>> Setting transient-mark-mode makes the problem go away. But isn't
>> cua-mode supposed to work without transient-mark-mode?
>
> Yes, it works. But clearly, some of the interactions haven't been
> tested yet.
>
> You could have mentioned earlier that you disabled transient-mark-mode.
Sorry, just a noob Emacser here :-) But I didn't disable
transient-mark-mode, setting cua-mode via the dropdown menu appears to
disable it.
HTH -- Andy
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#18952
; Package
emacs
.
(Wed, 05 Nov 2014 22:46:01 GMT)
Full text and
rfc822 format available.
Message #20 received at 18952 <at> debbugs.gnu.org (full text, mbox):
> Sorry, just a noob Emacser here :-) But I didn't disable
> transient-mark-mode, setting cua-mode via the dropdown menu appears to
> disable it.
Ah, that's a more serious bug, then, thanks.
Stefan
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#18952
; Package
emacs
.
(Thu, 06 Nov 2014 03:07:02 GMT)
Full text and
rfc822 format available.
Message #23 received at 18952 <at> debbugs.gnu.org (full text, mbox):
> Sorry, just a noob Emacser here :-) But I didn't disable
> transient-mark-mode, setting cua-mode via the dropdown menu appears to
> disable it.
It doesn't for me. Could you provide a *precise* recipe?
I tried:
emacs -Q
Options => Use CUA keys (Cut/Paste with C-x/C-c/C-v)
S-right S-right right right backspace
and the backspace only deleted one char. And M-: transient-mark-mode RET
tells me it's still enabled.
Stefan
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#18952
; Package
emacs
.
(Thu, 06 Nov 2014 06:42:01 GMT)
Full text and
rfc822 format available.
Message #26 received at 18952 <at> debbugs.gnu.org (full text, mbox):
On 11/05/2014 07:06 PM, Stefan Monnier wrote:
>> Sorry, just a noob Emacser here :-) But I didn't disable
>> transient-mark-mode, setting cua-mode via the dropdown menu appears to
>> disable it.
>
> It doesn't for me. Could you provide a *precise* recipe?
>
> I tried:
>
> emacs -Q
> Options => Use CUA keys (Cut/Paste with C-x/C-c/C-v)
> S-right S-right right right backspace
>
> and the backspace only deleted one char. And M-: transient-mark-mode RET
> tells me it's still enabled.
>
Ah! ok, I also have cua-highlight-region-shift-only t in my Customize
section, so I hit this without trying? But here's a way to repro,
starting from emacs -Q:
emacs -Q
Set Options => Use CUA keys (Cut/Paste with C-x/C-c/C-v)
Unset Options => Use CUA keys (Cut/Paste with C-x/C-c/C-v)
M-x set-variable cua-highlight-region-shift-only t
Set Options => Use CUA keys (Cut/Paste with C-x/C-c/C-v)
<open a file>
S-down S-down down down backspace
or alternatively, use a .emacs containing just:
(custom-set-variables
'(cua-highlight-region-shift-only t)
'(cua-mode t nil (cua-base)))
HTH -- Andy
Reply sent
to
Stefan Monnier <monnier <at> iro.umontreal.ca>
:
You have taken responsibility.
(Fri, 07 Nov 2014 19:57:03 GMT)
Full text and
rfc822 format available.
Notification sent
to
Andy Grover <andy <at> groveronline.com>
:
bug acknowledged by developer.
(Fri, 07 Nov 2014 19:57:03 GMT)
Full text and
rfc822 format available.
Message #31 received at 18952-done <at> debbugs.gnu.org (full text, mbox):
Version:24.5
> Ah! ok, I also have cua-highlight-region-shift-only t in my Customize
> section, so I hit this without trying? But here's a way to repro,
> starting from emacs -Q:
Ah, I see it now. I installed the patch below, which seems to fix it.
Thanks,
Stefan
=== modified file 'lisp/emulation/cua-base.el'
--- lisp/emulation/cua-base.el 2014-10-31 15:31:27 +0000
+++ lisp/emulation/cua-base.el 2014-11-07 19:51:19 +0000
@@ -1199,7 +1199,7 @@
(defun cua--select-keymaps ()
;; Setup conditions for selecting the proper keymaps in cua--keymap-alist.
(setq cua--ena-region-keymap
- (and mark-active (not deactivate-mark)))
+ (and (region-active-p) (not deactivate-mark)))
(setq cua--ena-prefix-override-keymap
(and cua--ena-region-keymap
cua-enable-cua-keys
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sat, 06 Dec 2014 12:24:03 GMT)
Full text and
rfc822 format available.
This bug report was last modified 10 years and 282 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.