unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#7260: 24.0.50; DEL screwed up
@ 2010-10-21 12:53             ` Richard Stallman
  2010-10-22 16:44               ` David Kastrup
  2012-02-19  6:09               ` Chong Yidong
  0 siblings, 2 replies; 29+ messages in thread
From: Richard Stallman @ 2010-10-21 12:53 UTC (permalink / raw)
  To: 7260

Today I typed DEL after yanking some text and typing C-x C-x to go to
the beginning of it.  DEL surprised me by deleting the region.
This change causes a lot of trouble.



In GNU Emacs 24.0.50.1 (mips64el-unknown-linux-gnu, GTK+ Version 2.12.12)
 of 2010-10-10 on theobromine2
configured using `configure  'CFLAGS=-g''

Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: en_US.UTF-8
  value of $XMODIFIERS: nil
  locale-coding-system: utf-8-unix
  default enable-multibyte-characters: t

Major mode: RMAIL

Minor modes in effect:
  diff-auto-refine-mode: t
  shell-dirtrack-mode: t
  gpm-mouse-mode: t
  display-battery-mode: t
  tooltip-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t
  abbrev-mode: t

Recent input:
SPC ESC DEL l a v a r SPC l o s SPC f i d e o s SPC 
c o n SPC a g u a SPC f r i a . C-c C-c C-u C-n C-u 
C-n C-n C-n C-n C-n ESC x m i m e RET C-u C-v C-u C-v 
ESC v C-v C-u C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p 
C-p C-p C-p C-p C-p C-p C-p C-n C-n C-e C-b C-@ ESC 
b ESC b ESC b ESC b ESC w m C-y C-n P o r SPC q u e 
' DEL DEL C-\ e ' SPC d i m i t e s ? ESC b ESC b ESC 
b ? / C-n C-n C-n C-x o C-v C-u C-n C-u C-n C-n C-n 
C-p C-p C-p C-e ESC b ESC b ESC b ESC b ESC b ESC b 
ESC b ESC b C-@ C-n C-n C-x o ESC , RET M e SPC i n 
q u i e t o SPC DEL DEL a DEL o SPC d e SPC t u SPC 
s a l i d a . SPC SPC C-a C-o C o n SPC t u SPC s a 
l i d a , SPC ESC l ESC q C-e ESC DEL ESC DEL ESC DEL 
p o r SPC E c u a d o r . RET ? / P o r SPC q u e ' 
SPC s a l i s t e ? C-c C-c . o f s f - l a TAB RET 
d d d d d ESC x e m a c s ESC DEL r e p o r t SPC e 
m a c s SPC b u g RET

Recent messages:
Auto-saving...
Sending...
Wrote /home/rms/outgoing/out-3
Sending...done
Mark set [4 times]
Auto-saving...done
Sending...
Wrote /home/rms/outgoing/out-4
Sending...done
Added to /home/rms/xmail/fsf-la.xmail

Load-path shadows:
None found.

Features:
(rmailkwd warnings rmailsum goto-addr thingatpt noutline outline
apropos two-column kmacro iso-transl etags debug pp vc-bzr sha1
hex-util find-func help-fns compare-w ispell shadow emacsbug dired-aux
diff-mode easy-mmode vc vc-dispatcher parse-time vc-cvs sgml-mode
mule-util cal-move cal-menu calendar cal-loaddefs grep compile
ansi-color shell tabify man assoc mh-e mh-compat mailabbrev mh-acros
cl mh-buffers mh-loaddefs gnus gnus-ems nnheader gnus-util mm-util
mail-prsvr wid-edit novice quail help-mode view rmailout dabbrev
newcomment mailalias sendmail multi-isearch dired t-mouse finder-inf
package rmailedit rmail mail-utils battery paren cus-start cus-load
mailcrypt rfc822 comint regexp-opt ring easymenu mailcrypt-init
tooltip ediff-hook vc-hooks lisp-float-type mwheel x-win x-dnd
tool-bar dnd fontset image fringe lisp-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 loaddefs button minibuffer faces
cus-face files text-properties overlay md5 base64 format env
code-pages mule custom widget hashtable-print-readable backquote
make-network-process dbusbind dynamic-setting system-font-setting
font-render-setting move-toolbar gtk x-toolkit x multi-tty emacs)


-- 
Richard Stallman
President, Free Software Foundation
51 Franklin St
Boston MA 02110
USA
www.fsf.org, www.gnu.org





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found] <mailman.4.1287666765.3734.bug-gnu-emacs@gnu.org>
@ 2010-10-21 17:21 ` Lars Magne Ingebrigtsen
  2010-10-21 18:19   ` Lennart Borgman
                     ` (4 more replies)
  0 siblings, 5 replies; 29+ messages in thread
From: Lars Magne Ingebrigtsen @ 2010-10-21 17:21 UTC (permalink / raw)
  To: rms; +Cc: 7260

Richard Stallman <rms@gnu.org> writes:

> Today I typed DEL after yanking some text and typing C-x C-x to go to
> the beginning of it.  DEL surprised me by deleting the region.

I think most people now agree that `C-x C-x' shouldn't activate the
region when transient-mark-mode is switched on, but nobody has actually
altered that function to stop doing this.

If nobody objects, I'll make that change later tonight.

-- 
(domestic pets only, the antidote for overdose, milk.)
  larsi@gnus.org * Lars Magne Ingebrigtsen





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
  2010-10-21 17:21 ` bug#7260: 24.0.50; DEL screwed up Lars Magne Ingebrigtsen
@ 2010-10-21 18:19   ` Lennart Borgman
  2010-10-21 18:26     ` Lars Magne Ingebrigtsen
  2010-10-21 18:45   ` Drew Adams
                     ` (3 subsequent siblings)
  4 siblings, 1 reply; 29+ messages in thread
From: Lennart Borgman @ 2010-10-21 18:19 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: rms, 7260

On Thu, Oct 21, 2010 at 7:21 PM, Lars Magne Ingebrigtsen <lmi@gnus.org> wrote:
> Richard Stallman <rms@gnu.org> writes:
>
>> Today I typed DEL after yanking some text and typing C-x C-x to go to
>> the beginning of it.  DEL surprised me by deleting the region.
>
> I think most people now agree that `C-x C-x' shouldn't activate the
> region when transient-mark-mode is switched on, but nobody has actually
> altered that function to stop doing this.

I did not follow, but how should then the region be activated if
transient-mark-mode is on?





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
  2010-10-21 18:19   ` Lennart Borgman
@ 2010-10-21 18:26     ` Lars Magne Ingebrigtsen
  0 siblings, 0 replies; 29+ messages in thread
From: Lars Magne Ingebrigtsen @ 2010-10-21 18:26 UTC (permalink / raw)
  To: Lennart Borgman; +Cc: rms, 7260

Lennart Borgman <lennart.borgman@gmail.com> writes:

> I did not follow, but how should then the region be activated if
> transient-mark-mode is on?

`C-u C-x C-x' was the general idea from the discussion, I think.

-- 
(domestic pets only, the antidote for overdose, milk.)
  larsi@gnus.org * Lars Magne Ingebrigtsen





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
  2010-10-21 17:21 ` bug#7260: 24.0.50; DEL screwed up Lars Magne Ingebrigtsen
  2010-10-21 18:19   ` Lennart Borgman
@ 2010-10-21 18:45   ` Drew Adams
  2010-10-21 19:39   ` Chong Yidong
                     ` (2 subsequent siblings)
  4 siblings, 0 replies; 29+ messages in thread
From: Drew Adams @ 2010-10-21 18:45 UTC (permalink / raw)
  To: 'Lars Magne Ingebrigtsen', rms; +Cc: 7260, 'Emacs-Devel devel'

> Richard Stallman <rms@gnu.org> writes:
> 
> > Today I typed DEL after yanking some text and typing C-x 
> > C-x to go to the beginning of it.  DEL surprised me by
> > deleting the region.
> 
> I think most people now agree that `C-x C-x' shouldn't activate the
> region when transient-mark-mode is switched on, but nobody 
> has actually altered that function to stop doing this.
> 
> If nobody objects, I'll make that change later tonight.

Huh??????

_Nothing_ has been decided in this regard.

Refer to the giant thread "C-d deleting region considered harmful".  See in
particular the sub/derived threads "Should C-x C-x activate the region?" and
"C-x C-x".
http://lists.gnu.org/archive/html/emacs-devel/2010-09/msg00965.html
http://lists.gnu.org/archive/html/emacs-devel/2010-09/msg01011.html

There was _lots_ of discussion about this, but no conclusion about just what
should be done.

The last mail I see on this topic was Richard's of 2010/09/22.
He argued that a poll should be taken.
The last line of the thread is Richard's:
"If we just speculate about this, we might be very wrong."
http://lists.gnu.org/archive/html/emacs-devel/2010-09/msg01110.html

Please do _not_ just "make that change later tonight".

(You certainly should not make changes like that based only on someone filing a
bug to report an annoyance.)

(FWIW, I was the first in the thread to suggest that we might consider changing
`C-x C-x' so that it does not activate the region.  So I am not against such a
change, in principle.  But just "making that change later tonight" is truly not
kosher/halal.)






^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
  2010-10-21 17:21 ` bug#7260: 24.0.50; DEL screwed up Lars Magne Ingebrigtsen
  2010-10-21 18:19   ` Lennart Borgman
  2010-10-21 18:45   ` Drew Adams
@ 2010-10-21 19:39   ` Chong Yidong
       [not found]   ` <mailman.8.1287690197.32629.bug-gnu-emacs@gnu.org>
       [not found]   ` <A491447AE2F940C4A8A962F87022827B@us.oracle.com>
  4 siblings, 0 replies; 29+ messages in thread
From: Chong Yidong @ 2010-10-21 19:39 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: rms, 7260

Lars Magne Ingebrigtsen <lmi@gnus.org> writes:

> Richard Stallman <rms@gnu.org> writes:
>
>> Today I typed DEL after yanking some text and typing C-x C-x to go to
>> the beginning of it.  DEL surprised me by deleting the region.
>
> I think most people now agree that `C-x C-x' shouldn't activate the
> region when transient-mark-mode is switched on, but nobody has actually
> altered that function to stop doing this.
>
> If nobody objects, I'll make that change later tonight.

Bad idea.  If C-x C-x does not enable the mark, it becomes impossible to
exchange point and mark while activating the region.

If you want to return to the mark without reactivating it, do C-u C-SPC.





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]   ` <mailman.8.1287690197.32629.bug-gnu-emacs@gnu.org>
@ 2010-10-21 20:01     ` Lars Magne Ingebrigtsen
  2010-10-21 20:16       ` Chong Yidong
  0 siblings, 1 reply; 29+ messages in thread
From: Lars Magne Ingebrigtsen @ 2010-10-21 20:01 UTC (permalink / raw)
  To: Chong Yidong; +Cc: rms, 7260

Chong Yidong <cyd@stupidchicken.com> writes:

> Bad idea.  If C-x C-x does not enable the mark, it becomes impossible to
> exchange point and mark while activating the region.

I don't follow you.  `C-u C-x C-x' would do that, wouldn't it?

-- 
(domestic pets only, the antidote for overdose, milk.)
  larsi@gnus.org * Lars Magne Ingebrigtsen





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
  2010-10-21 20:01     ` Lars Magne Ingebrigtsen
@ 2010-10-21 20:16       ` Chong Yidong
  2010-10-21 20:30         ` Lars Magne Ingebrigtsen
  0 siblings, 1 reply; 29+ messages in thread
From: Chong Yidong @ 2010-10-21 20:16 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: rms, 7260

Lars Magne Ingebrigtsen <lmi@gnus.org> writes:

> Chong Yidong <cyd@stupidchicken.com> writes:
>
>> Bad idea.  If C-x C-x does not enable the mark, it becomes impossible to
>> exchange point and mark while activating the region.
>
> I don't follow you.  `C-u C-x C-x' would do that, wouldn't it?

Ah yes, now I recall: the idea was to flip the meaning of ARG in
exchange-point-and-mark, yes?  This is not a bad idea in principle.  But
the effects may be strange.  It would mean that, when the mark is
active, you need to do C-u C-x C-x to exchange point and mark without
deactivating the mark, which is inconvenient.  So this may need
tweaking.

For this change, please post your proposed change as a patch to
emacs-devel, for others to comment, instead of checking it in directly.





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
  2010-10-21 20:16       ` Chong Yidong
@ 2010-10-21 20:30         ` Lars Magne Ingebrigtsen
  0 siblings, 0 replies; 29+ messages in thread
From: Lars Magne Ingebrigtsen @ 2010-10-21 20:30 UTC (permalink / raw)
  To: Chong Yidong; +Cc: 7260, rms, emacs-devel

Chong Yidong <cyd@stupidchicken.com> writes:

> Ah yes, now I recall: the idea was to flip the meaning of ARG in
> exchange-point-and-mark, yes?

Yup.

> This is not a bad idea in principle.  But the effects may be strange.
> It would mean that, when the mark is active, you need to do C-u C-x
> C-x to exchange point and mark without deactivating the mark, which is
> inconvenient.  So this may need tweaking.

Ah, yes, true.  

> For this change, please post your proposed change as a patch to
> emacs-devel, for others to comment, instead of checking it in directly.

Sure.

I've spelled out all the cases instead of using the
(xor arg (not (region-active-p))) logic for clarity.

It seems to do the trick in all the use cases (transient with active
mark, without active mark, with and without prefix, and non-transient
with and without prefix).  Unless there was some combination I forgot to
check. 

=== modified file 'lisp/simple.el'
*** lisp/simple.el	2010-10-19 15:43:27 +0000
--- lisp/simple.el	2010-10-21 20:27:22 +0000
***************
*** 3966,3993 ****
    'exchange-dot-and-mark 'exchange-point-and-mark "23.3")
  (defun exchange-point-and-mark (&optional arg)
    "Put the mark where point is now, and point where the mark is now.
- This command works even when the mark is not active,
- and it reactivates the mark.
  
! If Transient Mark mode is on, a prefix ARG deactivates the mark
! if it is active, and otherwise avoids reactivating it.  If
! Transient Mark mode is off, a prefix ARG enables Transient Mark
! mode temporarily."
    (interactive "P")
    (let ((omark (mark t))
  	(temp-highlight (eq (car-safe transient-mark-mode) 'only)))
      (if (null omark)
          (error "No mark set in this buffer"))
      (deactivate-mark)
!     (set-mark (point))
      (goto-char omark)
      (if set-mark-default-inactive (deactivate-mark))
      (cond (temp-highlight
  	   (setq transient-mark-mode (cons 'only transient-mark-mode)))
! 	  ((or (and arg (region-active-p)) ; (xor arg (not (region-active-p)))
! 	       (not (or arg (region-active-p))))
! 	   (deactivate-mark))
! 	  (t (activate-mark)))
      nil))
  
  (defcustom shift-select-mode t
--- 3966,3999 ----
    'exchange-dot-and-mark 'exchange-point-and-mark "23.3")
  (defun exchange-point-and-mark (&optional arg)
    "Put the mark where point is now, and point where the mark is now.
  
! If Transient Mark mode is on, a prefix ARG activates the mark if
! it is inactive.  If Transient Mark mode is off, a prefix ARG
! enables Transient Mark mode temporarily."
    (interactive "P")
    (let ((omark (mark t))
+ 	(active (region-active-p))
  	(temp-highlight (eq (car-safe transient-mark-mode) 'only)))
      (if (null omark)
          (error "No mark set in this buffer"))
      (deactivate-mark)
!     (push-mark (point))
      (goto-char omark)
      (if set-mark-default-inactive (deactivate-mark))
      (cond (temp-highlight
  	   (setq transient-mark-mode (cons 'only transient-mark-mode)))
! 	  ;; Transient mode and active region -- activate.
! 	  ((and active
! 		(not arg))
! 	   (activate-mark))
! 	  ;; Transient mode and no prefix -- leave deactivated.
! 	  ((and (not active)
! 		(not arg))
! 	   )
! 	  ;; Non-transient mode, but prefix -- activate.
! 	  ((and (not transient-mark-mode)
! 		arg)
! 	   (activate-mark)))
      nil))
  
  (defcustom shift-select-mode t


-- 
(domestic pets only, the antidote for overdose, milk.)
  larsi@gnus.org * Lars Magne Ingebrigtsen





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]   ` <A491447AE2F940C4A8A962F87022827B@us.oracle.com>
@ 2010-10-22 12:22     ` Richard Stallman
       [not found]     ` <E1P9Gdq-0001N1-Pt@fencepost.gnu.org>
  1 sibling, 0 replies; 29+ messages in thread
From: Richard Stallman @ 2010-10-22 12:22 UTC (permalink / raw)
  To: Drew Adams; +Cc: 7260, lmi, emacs-devel

    > I think most people now agree that `C-x C-x' shouldn't activate the
    > region when transient-mark-mode is switched on, but nobody 
    > has actually altered that function to stop doing this.

C-x C-x is the main way to activate an existing region in Transient
Mark mode.  To make that require C-u will be a different pain in the
neck.

The change for C-d and DEL to delete all regions was too radically
incompatible to make made without polling the users first.  The right
thing to do is take that change out, then address the issue the right
way: by polling the users.

-- 
Richard Stallman
President, Free Software Foundation
51 Franklin St
Boston MA 02110
USA
www.fsf.org, www.gnu.org





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]     ` <E1P9Gdq-0001N1-Pt@fencepost.gnu.org>
@ 2010-10-22 13:52       ` Lars Magne Ingebrigtsen
       [not found]       ` <m3wrpae3ne.fsf@quimbies.gnus.org>
  1 sibling, 0 replies; 29+ messages in thread
From: Lars Magne Ingebrigtsen @ 2010-10-22 13:52 UTC (permalink / raw)
  To: rms; +Cc: emacs-devel, 7260

Richard Stallman <rms@gnu.org> writes:

> C-x C-x is the main way to activate an existing region in Transient
> Mark mode.  To make that require C-u will be a different pain in the
> neck.

I wasn't present when the discussion to make `C-x C-x' do these things
took place, but it seems like the current behaviour conflates to rather
different actions -- exchange-point-and-mark, and activate-region.  How
about just decoupling them altogether, and let `C-x C-x' revert to
(only) doing what it's always done, and add `C-x C-a' for
`activate-region'?

`C-u C-x C-x' could still do both at once, for people who like that a
lot. 

> The change for C-d and DEL to delete all regions was too radically
> incompatible to make made without polling the users first.  The right
> thing to do is take that change out, then address the issue the right
> way: by polling the users.

It sounds rather odd to have `C-d' not delete the active region.  If
you (for instance) Shift-Right an area, and then press `DEL', I think
most people would expect the region you've just selected to be deleted.

So I think there are two completely separate issues here:

1) Should `C-x C-x' activate the region?  I think not, because it drives
   me totally insane.

2) Should `DEL' delete the active region?  I think it makes sense, but
   it might be too surprising.  And `C-w' already exists to do that, so
   there doesn't seem to be a really compelling reason for that
   behaviour.

-- 
(domestic pets only, the antidote for overdose, milk.)
  larsi@gnus.org * Lars Magne Ingebrigtsen





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]       ` <m3wrpae3ne.fsf@quimbies.gnus.org>
@ 2010-10-22 15:04         ` Andreas Schwab
  2010-10-22 15:47         ` Miles Bader
                           ` (7 subsequent siblings)
  8 siblings, 0 replies; 29+ messages in thread
From: Andreas Schwab @ 2010-10-22 15:04 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: 7260, rms, emacs-devel

Lars Magne Ingebrigtsen <larsi@gnus.org> writes:

> add `C-x C-a' for `activate-region'?

Note that ^X^A is already taken.

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] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]       ` <m3wrpae3ne.fsf@quimbies.gnus.org>
  2010-10-22 15:04         ` Andreas Schwab
@ 2010-10-22 15:47         ` Miles Bader
       [not found]         ` <m31v7iclqk.fsf@hase.home>
                           ` (6 subsequent siblings)
  8 siblings, 0 replies; 29+ messages in thread
From: Miles Bader @ 2010-10-22 15:47 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: 7260, rms, emacs-devel

Lars Magne Ingebrigtsen <larsi@gnus.org> writes:
> I wasn't present when the discussion to make `C-x C-x' do these things
> took place, but it seems like the current behaviour conflates to rather
> different actions -- exchange-point-and-mark, and activate-region.  How
> about just decoupling them altogether, and let `C-x C-x' revert to
> (only) doing what it's always done, and add `C-x C-a' for
> `activate-region'?

How about not doing that?

I don't disagree that having a dedicated key might be more
logical/elegant/whatever, but user interfaces, after all, are more about
what's convenient and familiar than what's the most minimal.

Saying "(only) doing what it's always done" is simply _wrong_ at this
point, because C-x C-x has had its current functionality for quite a
while -- if I interpret what I see in git correctly, at least since 1993!

-Miles

-- 
Conservative, n. A statesman enamored of existing evils, as opposed to a
Liberal, who wants to replace them with new ones.





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]         ` <m31v7iclqk.fsf@hase.home>
@ 2010-10-22 15:49           ` Miles Bader
  0 siblings, 0 replies; 29+ messages in thread
From: Miles Bader @ 2010-10-22 15:49 UTC (permalink / raw)
  To: Andreas Schwab; +Cc: Lars Magne Ingebrigtsen, emacs-devel, rms, 7260

Andreas Schwab <schwab@linux-m68k.org> writes:
>> add `C-x C-a' for `activate-region'?
>
> Note that ^X^A is already taken.

Hmm, doesn't seem to be in my Emacs...

-Miles

-- 
Friendless, adj. Having no favors to bestow. Destitute of fortune. Addicted to
utterance of truth and common sense.





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]         ` <87sjzyp6u3.fsf@catnip.gol.com>
@ 2010-10-22 16:10           ` Lars Magne Ingebrigtsen
  2010-10-21 12:53             ` Richard Stallman
                               ` (2 more replies)
  0 siblings, 3 replies; 29+ messages in thread
From: Lars Magne Ingebrigtsen @ 2010-10-22 16:10 UTC (permalink / raw)
  To: Miles Bader; +Cc: 7260, rms, emacs-devel

Miles Bader <miles@gnu.org> writes:

> Saying "(only) doing what it's always done" is simply _wrong_ at this
> point, because C-x C-x has had its current functionality for quite a
> while -- if I interpret what I see in git correctly, at least since 1993!

Huh.  I though transient-mark-mode was new(ish)?

-- 
(domestic pets only, the antidote for overdose, milk.)
  larsi@gnus.org * Lars Magne Ingebrigtsen





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
  2010-10-22 16:10           ` Lars Magne Ingebrigtsen
  2010-10-21 12:53             ` Richard Stallman
@ 2010-10-22 16:42             ` Andreas Schwab
       [not found]             ` <m3fwvyb2lz.fsf@hase.home>
  2 siblings, 0 replies; 29+ messages in thread
From: Andreas Schwab @ 2010-10-22 16:42 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: Miles Bader, emacs-devel, rms, 7260

Lars Magne Ingebrigtsen <larsi@gnus.org> writes:

> Huh.  I though transient-mark-mode was new(ish)?

etc/NEWS.19:

* Changes in version 19.

** If you enable Transient Mark mode, then the mark becomes "inactive"

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] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
  2010-10-21 12:53             ` Richard Stallman
@ 2010-10-22 16:44               ` David Kastrup
  2012-02-19  6:09               ` Chong Yidong
  1 sibling, 0 replies; 29+ messages in thread
From: David Kastrup @ 2010-10-22 16:44 UTC (permalink / raw)
  To: bug-gnu-emacs; +Cc: emacs-devel

Lars Magne Ingebrigtsen <larsi@gnus.org> writes:

> Miles Bader <miles@gnu.org> writes:
>
>> Saying "(only) doing what it's always done" is simply _wrong_ at this
>> point, because C-x C-x has had its current functionality for quite a
>> while -- if I interpret what I see in git correctly, at least since
>> 1993!
>
> Huh.  I though transient-mark-mode was new(ish)?

Nope.  Been around as long as I can remember.  It is just that it has
"recently" made active by default.

Temporary transient-mark-mode (sounds a bit redundant, doesn't it?) is
quite newer, 21.something I think.

-- 
David Kastrup






^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]             ` <m3fwvyb2lz.fsf@hase.home>
@ 2010-10-22 16:45               ` Lars Magne Ingebrigtsen
       [not found]               ` <m3ocamtbvo.fsf@quimbies.gnus.org>
  1 sibling, 0 replies; 29+ messages in thread
From: Lars Magne Ingebrigtsen @ 2010-10-22 16:45 UTC (permalink / raw)
  To: Andreas Schwab; +Cc: Miles Bader, emacs-devel, rms, 7260

Andreas Schwab <schwab@linux-m68k.org> writes:

>> Huh.  I though transient-mark-mode was new(ish)?
>
> etc/NEWS.19:
>
> * Changes in version 19.

I mean, as a thing that's on by default.  (Stuff that's not on by
default doesn't exist for most people.)  People really started
complaining about this behaviour this year, so I'm assuming something
changed somewhere.

-- 
(domestic pets only, the antidote for overdose, milk.)
  larsi@gnus.org * Lars Magne Ingebrigtsen





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]               ` <m3ocamtbvo.fsf@quimbies.gnus.org>
@ 2010-10-22 18:24                 ` Eli Zaretskii
  0 siblings, 0 replies; 29+ messages in thread
From: Eli Zaretskii @ 2010-10-22 18:24 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: miles, emacs-devel, schwab, rms, 7260

> From: Lars Magne Ingebrigtsen <larsi@gnus.org>
> Date: Fri, 22 Oct 2010 18:45:15 +0200
> Cc: Miles Bader <miles@gnu.org>, emacs-devel@gnu.org, rms@gnu.org,
> 	7260@debbugs.gnu.org
> 
> Andreas Schwab <schwab@linux-m68k.org> writes:
> 
> >> Huh.  I though transient-mark-mode was new(ish)?
> >
> > etc/NEWS.19:
> >
> > * Changes in version 19.
> 
> I mean, as a thing that's on by default.  (Stuff that's not on by
> default doesn't exist for most people.)  People really started
> complaining about this behaviour this year, so I'm assuming something
> changed somewhere.

  2008-03-23  Chong Yidong  <cyd@stupidchicken.com>

	  * simple.el (transient-mark-mode): Turn on by default.


Hardly "this year".

FWIW, the first thing I do in any Emacs I need to work is turn this
off.





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]       ` <m3wrpae3ne.fsf@quimbies.gnus.org>
                           ` (3 preceding siblings ...)
       [not found]         ` <87sjzyp6u3.fsf@catnip.gol.com>
@ 2010-10-23  7:46         ` Richard Stallman
  2010-10-23  7:46         ` Richard Stallman
                           ` (3 subsequent siblings)
  8 siblings, 0 replies; 29+ messages in thread
From: Richard Stallman @ 2010-10-23  7:46 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: emacs-devel, 7260

    I wasn't present when the discussion to make `C-x C-x' do these things
    took place, but it seems like the current behaviour conflates to rather
    different actions -- exchange-point-and-mark, and activate-region.

Combining the two actions was very convenient before the recent
change to C-d and DEL.  The problem has happened to me in fact
after C-x C-x, but I suspect it will also happen in other cases.

-- 
Richard Stallman
President, Free Software Foundation
51 Franklin St
Boston MA 02110
USA
www.fsf.org, www.gnu.org





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]       ` <m3wrpae3ne.fsf@quimbies.gnus.org>
                           ` (4 preceding siblings ...)
  2010-10-23  7:46         ` Richard Stallman
@ 2010-10-23  7:46         ` Richard Stallman
       [not found]         ` <E1P9Ynv-0005Fy-ER@fencepost.gnu.org>
                           ` (2 subsequent siblings)
  8 siblings, 0 replies; 29+ messages in thread
From: Richard Stallman @ 2010-10-23  7:46 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: emacs-devel, 7260

    I wasn't present when the discussion to make `C-x C-x' do these things
    took place, but it seems like the current behaviour conflates to rather
    different actions -- exchange-point-and-mark, and activate-region.

Combining the two actions was very convenient before the recent
change to C-d and DEL.  The problem has happened to me in fact
after C-x C-x, but I suspect it will also happen in other cases.

    It sounds rather odd to have `C-d' not delete the active region.  If
    you (for instance) Shift-Right an area, and then press `DEL', I think
    most people would expect the region you've just selected to be deleted.

After shift-arrows is a special case when it might be proper for DEL
and C-d to delete the region.

-- 
Richard Stallman
President, Free Software Foundation
51 Franklin St
Boston MA 02110
USA
www.fsf.org, www.gnu.org





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]         ` <E1P9Ynv-0005Fy-ER@fencepost.gnu.org>
@ 2010-10-23  9:38           ` Jan Djärv
       [not found]           ` <4CC2AD28.5060504@swipnet.se>
                             ` (2 subsequent siblings)
  3 siblings, 0 replies; 29+ messages in thread
From: Jan Djärv @ 2010-10-23  9:38 UTC (permalink / raw)
  To: rms; +Cc: Lars Magne Ingebrigtsen, emacs-devel, 7260



Richard Stallman skrev 2010-10-23 09.46:
>
>      It sounds rather odd to have `C-d' not delete the active region.  If
>      you (for instance) Shift-Right an area, and then press `DEL', I think
>      most people would expect the region you've just selected to be deleted.
>
> After shift-arrows is a special case when it might be proper for DEL
> and C-d to delete the region.
>

FWIW, I often mark a region with the mouse and press DEL to delete it.  It is 
a habit picked up from other programs.  But then again, I enabled delsel a 
long time ago, so I'm used to that behaviour.

	Jan D.





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]       ` <m3wrpae3ne.fsf@quimbies.gnus.org>
                           ` (6 preceding siblings ...)
       [not found]         ` <E1P9Ynv-0005Fy-ER@fencepost.gnu.org>
@ 2010-10-23 11:18         ` Bastien
       [not found]         ` <878w1pi2cl.fsf@altern.org>
  8 siblings, 0 replies; 29+ messages in thread
From: Bastien @ 2010-10-23 11:18 UTC (permalink / raw)
  To: Lars Magne Ingebrigtsen; +Cc: 7260, rms, emacs-devel

Lars Magne Ingebrigtsen <larsi@gnus.org> writes:

> So I think there are two completely separate issues here:
>
> 1) Should `C-x C-x' activate the region?  I think not, because it drives
>    me totally insane.

Same here (FWIW).

-- 
 Bastien





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]           ` <877hh9ng5m.fsf@lola.goethe.zz>
@ 2010-10-23 16:09             ` Lars Magne Ingebrigtsen
  0 siblings, 0 replies; 29+ messages in thread
From: Lars Magne Ingebrigtsen @ 2010-10-23 16:09 UTC (permalink / raw)
  To: David Kastrup; +Cc: emacs-devel, rms, 7260

David Kastrup <dak@gnu.org> writes:

> Would suggest an option for inverting the meaning of a prefix argument
> on C-x C-x while in transient-mark-mode.

The question would then be what the default should be.  :-)

Anyway, my impression is that the vast majority of kvetching about
transient-mark-mode and/or delsel mode is purely about `C-x C-x'.  If
that command didn't activate the region, I think many people who find
transient-mark-mode problematic would no longer feel that way.
transient-mark-mode is quite useful (qv. `M-;'), and it's a shame that
something is simple as `C-x C-x' should make so many people switch it
off completely.

So my suggestion is this: Apply the patch that reverses (sort of) the
prefix in the `C-x C-x' in the pretest Emacs, and see what people feel
about it then.  If people absolutely loathe how `C-x C-x' then works, we
can revert the change, but at least we'll have one more data point.

-- 
(domestic pets only, the antidote for overdose, milk.)
  larsi@gnus.org * Lars Magne Ingebrigtsen





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]           ` <4CC2AD28.5060504@swipnet.se>
@ 2010-10-23 17:26             ` James Cloos
       [not found]             ` <m3fwvwbz1s.fsf@jhcloos.com>
  1 sibling, 0 replies; 29+ messages in thread
From: James Cloos @ 2010-10-23 17:26 UTC (permalink / raw)
  To: Jan Djärv; +Cc: Lars Magne Ingebrigtsen, 7260, rms, emacs-devel

>>>>> "JD" == Jan Djärv <jan.h.d@swipnet.se> writes:

JD> FWIW, I often mark a region with the mouse and press DEL to delete it.
JD> It is a habit picked up from other programs.  But then again, I
JD> enabled delsel a long time ago, so I'm used to that behaviour.

Perhaps what would kill :^) the controversy would be a dwim version,
kill-or-delete, which would add the region to the kill buffer if it
is big enough, but not bother if it is small.  Using that for DEL &
C-d may cover both camps' wants.

The C-u prefix arg could invert the choice, in case you really want
to delete a huge region or want to cut-n-paste a small one.

AISI, it would only be useful when the region is active.  C-d should
continue to delete just the single character to the (logical) right
when the region is not active.

Acting based on whether any input events occurred between activating
the region and pressing C-d or DEL may be a reasonable alternative.
In that case, those two keys would only kill if used immediately
after activating the region.

I find that I almost never want to delete (rather than kill) a region.
But only /almost/ never.

I could deal with <activate-region> C-u C-d deleting the region.  But
unless the region is small enough to retype quickly and easily, it would
be painful for C-d on its own to delete the region.

-JimC
-- 
James Cloos <cloos@jhcloos.com>         OpenPGP: 1024D/ED7DAEA6





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]             ` <m3fwvwbz1s.fsf@jhcloos.com>
@ 2010-10-23 17:54               ` James Cloos
  0 siblings, 0 replies; 29+ messages in thread
From: James Cloos @ 2010-10-23 17:54 UTC (permalink / raw)
  To: Jan Djärv; +Cc: Lars Magne Ingebrigtsen, emacs-devel, rms, 7260

[I see my followup got truncated; trying again. -JimC]

>>>>> "JD" == Jan Djarv <jan.h.d@swipnet.se> writes:

JD> FWIW, I often mark a region with the mouse and press DEL to delete it.
JD> It is a habit picked up from other programs.  But then again, I
JD> enabled delsel a long time ago, so I'm used to that behaviour.

Perhaps what would kill :^) the controversy would be a dwim version,
kill-or-delete, which would add the region to the kill buffer if it
is big enough, but not bother if it is small.  Using that for DEL &
C-d may cover both camps' wants.

The C-u prefix arg could invert the choice, in case you really want
to delete a huge region or want to cut-n-paste a small one.

AISI, it would only be useful when the region is active.  C-d should
continue to delete just the single character to the (logical) right
when the region is not active.

Acting based on whether any input events occurred between activating
the region and pressing C-d or DEL may be a reasonable alternative.
In that case, those two keys would only kill if used immediately
after activating the region.

I find that I almost never want to delete (rather than kill) a region.
But only /almost/ never.

I could deal with <activate-region> C-u C-d deleting the region.  But
unless the region is small enough to retype quickly and easily, it would
be painful for C-d on its own to delete the region.

-JimC
-- 
James Cloos <cloos@jhcloos.com>         OpenPGP: 1024D/ED7DAEA6





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]         ` <E1P9Ynv-0005Fy-ER@fencepost.gnu.org>
  2010-10-23  9:38           ` Jan Djärv
       [not found]           ` <4CC2AD28.5060504@swipnet.se>
@ 2010-10-24 16:30           ` Chong Yidong
       [not found]           ` <87eibf3659.fsf@stupidchicken.com>
  3 siblings, 0 replies; 29+ messages in thread
From: Chong Yidong @ 2010-10-24 16:30 UTC (permalink / raw)
  To: rms; +Cc: Lars Magne Ingebrigtsen, 7260, emacs-devel

Richard Stallman <rms@gnu.org> writes:

>   It sounds rather odd to have `C-d' not delete the active region.  If
>   you (for instance) Shift-Right an area, and then press `DEL', I think
>   most people would expect the region you've just selected to be deleted.
>
> After shift-arrows is a special case when it might be proper for DEL
> and C-d to delete the region.

This might be OK, and indeed I think it should at least be an option.
One problem is that it can be confusing.  Currently, temporarily active
regions (i.e. shift-selected and/or mouse-selected) behave as much like
ordinary active regions as possible, with respect to user commands.  If
we make DEL behave differently for one type of region, what's the
justification for limiting ourselves to DEL?

For instance, in other X applications, shift-selecting a region and
typing a self-inserting character replaces the region.  By this
reasoning, shouldn't we enable Delete Selection mode style behavior for
shift-selected regions?





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
       [not found]           ` <87eibf3659.fsf@stupidchicken.com>
@ 2010-10-25 12:08             ` Richard Stallman
  0 siblings, 0 replies; 29+ messages in thread
From: Richard Stallman @ 2010-10-25 12:08 UTC (permalink / raw)
  To: Chong Yidong; +Cc: larsi, 7260, emacs-devel

      If
    we make DEL behave differently for one type of region, what's the
    justification for limiting ourselves to DEL?

DEL is so special that we need no "justification" for treating
it specially.  However, that's not what I recommend.  It's not
just DEL, it is also C-d.

    For instance, in other X applications, shift-selecting a region and
    typing a self-inserting character replaces the region.  By this
    reasoning, shouldn't we enable Delete Selection mode style behavior for
    shift-selected regions?

Maybe we should fully enable that behavior after shift-selections
and after mouse-selections.

-- 
Richard Stallman
President, Free Software Foundation
51 Franklin St
Boston MA 02110
USA
www.fsf.org, www.gnu.org





^ permalink raw reply	[flat|nested] 29+ messages in thread

* bug#7260: 24.0.50; DEL screwed up
  2010-10-21 12:53             ` Richard Stallman
  2010-10-22 16:44               ` David Kastrup
@ 2012-02-19  6:09               ` Chong Yidong
  1 sibling, 0 replies; 29+ messages in thread
From: Chong Yidong @ 2012-02-19  6:09 UTC (permalink / raw)
  To: 7260

> Today I typed DEL after yanking some text and typing C-x C-x to go to
> the beginning of it.  DEL surprised me by deleting the region.  This
> change causes a lot of trouble.

Closing, see

http://lists.gnu.org/archive/html/emacs-devel/2011-10/msg00743.html





^ permalink raw reply	[flat|nested] 29+ messages in thread

end of thread, other threads:[~2012-02-19  6:09 UTC | newest]

Thread overview: 29+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <mailman.4.1287666765.3734.bug-gnu-emacs@gnu.org>
2010-10-21 17:21 ` bug#7260: 24.0.50; DEL screwed up Lars Magne Ingebrigtsen
2010-10-21 18:19   ` Lennart Borgman
2010-10-21 18:26     ` Lars Magne Ingebrigtsen
2010-10-21 18:45   ` Drew Adams
2010-10-21 19:39   ` Chong Yidong
     [not found]   ` <mailman.8.1287690197.32629.bug-gnu-emacs@gnu.org>
2010-10-21 20:01     ` Lars Magne Ingebrigtsen
2010-10-21 20:16       ` Chong Yidong
2010-10-21 20:30         ` Lars Magne Ingebrigtsen
     [not found]   ` <A491447AE2F940C4A8A962F87022827B@us.oracle.com>
2010-10-22 12:22     ` Richard Stallman
     [not found]     ` <E1P9Gdq-0001N1-Pt@fencepost.gnu.org>
2010-10-22 13:52       ` Lars Magne Ingebrigtsen
     [not found]       ` <m3wrpae3ne.fsf@quimbies.gnus.org>
2010-10-22 15:04         ` Andreas Schwab
2010-10-22 15:47         ` Miles Bader
     [not found]         ` <m31v7iclqk.fsf@hase.home>
2010-10-22 15:49           ` Miles Bader
     [not found]         ` <87sjzyp6u3.fsf@catnip.gol.com>
2010-10-22 16:10           ` Lars Magne Ingebrigtsen
2010-10-21 12:53             ` Richard Stallman
2010-10-22 16:44               ` David Kastrup
2012-02-19  6:09               ` Chong Yidong
2010-10-22 16:42             ` Andreas Schwab
     [not found]             ` <m3fwvyb2lz.fsf@hase.home>
2010-10-22 16:45               ` Lars Magne Ingebrigtsen
     [not found]               ` <m3ocamtbvo.fsf@quimbies.gnus.org>
2010-10-22 18:24                 ` Eli Zaretskii
2010-10-23  7:46         ` Richard Stallman
2010-10-23  7:46         ` Richard Stallman
     [not found]         ` <E1P9Ynv-0005Fy-ER@fencepost.gnu.org>
2010-10-23  9:38           ` Jan Djärv
     [not found]           ` <4CC2AD28.5060504@swipnet.se>
2010-10-23 17:26             ` James Cloos
     [not found]             ` <m3fwvwbz1s.fsf@jhcloos.com>
2010-10-23 17:54               ` James Cloos
2010-10-24 16:30           ` Chong Yidong
     [not found]           ` <87eibf3659.fsf@stupidchicken.com>
2010-10-25 12:08             ` Richard Stallman
2010-10-23 11:18         ` Bastien
     [not found]         ` <878w1pi2cl.fsf@altern.org>
     [not found]           ` <877hh9ng5m.fsf@lola.goethe.zz>
2010-10-23 16:09             ` Lars Magne Ingebrigtsen

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).