unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Ctrl-x Ctrl-x (exchange-point-and-mark)
@ 2010-05-10 19:42 Harry Putnam
  2010-05-10 20:34 ` Sean Sieger
                   ` (2 more replies)
  0 siblings, 3 replies; 15+ messages in thread
From: Harry Putnam @ 2010-05-10 19:42 UTC (permalink / raw)
  To: help-gnu-emacs

I see there are no customizing option matching
`exchange-point-and-mark' (Ctrl-x Ctrl-x)

I wondered if I can do anyghing about the current behavior where when
the exchange is made, the area in between is selected and highlighted.

I don't want to turn off the newish behavior of how regions are
selected, where it takes two strikes of spc bar to turn it off.  I
know there is a way to turn that off, but wondered if I might be able
to ditch that un-wanted behavior some other way.




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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
  2010-05-10 19:42 Ctrl-x Ctrl-x (exchange-point-and-mark) Harry Putnam
@ 2010-05-10 20:34 ` Sean Sieger
  2010-05-11 10:53   ` Harry Putnam
                     ` (2 more replies)
  2010-05-10 21:10 ` Štěpán Němec
  2010-05-16 10:50 ` Uday S Reddy
  2 siblings, 3 replies; 15+ messages in thread
From: Sean Sieger @ 2010-05-10 20:34 UTC (permalink / raw)
  To: help-gnu-emacs

Harry Putnam <reader@newsguy.com> writes:

    I see there are no customizing option matching
    `exchange-point-and-mark' (Ctrl-x Ctrl-x)

C-g doesn't suit you?

    I wondered if I can do anyghing about the current behavior where when
    the exchange is made, the area in between is selected and highlighted.

    I don't want to turn off the newish behavior of how regions are
    selected, where it takes two strikes of spc bar to turn it off.  I
    know there is a way to turn that off, but wondered if I might be able
    to ditch that un-wanted behavior some other way.




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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
       [not found] <mailman.10.1273520565.11383.help-gnu-emacs@gnu.org>
@ 2010-05-10 21:01 ` Andreas Politz
  0 siblings, 0 replies; 15+ messages in thread
From: Andreas Politz @ 2010-05-10 21:01 UTC (permalink / raw)
  To: help-gnu-emacs

Harry Putnam <reader@newsguy.com> writes:

> I see there are no customizing option matching
> `exchange-point-and-mark' (Ctrl-x Ctrl-x)
>
> I wondered if I can do anyghing about the current behavior where when
> the exchange is made, the area in between is selected and highlighted.
>
> I don't want to turn off the newish behavior of how regions are
> selected, where it takes two strikes of spc bar to turn it off.  I
> know there is a way to turn that off, but wondered if I might be able
> to ditch that un-wanted behavior some other way.

You could invert the meaning of the prefix arg with some advice.

(defadvice exchange-point-and-mark (before negate-interactive-arg activate)
  "Logically negate the interactive ARG."
  (interactive
   (list (not current-prefix-arg))))

-ap


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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
  2010-05-10 19:42 Ctrl-x Ctrl-x (exchange-point-and-mark) Harry Putnam
  2010-05-10 20:34 ` Sean Sieger
@ 2010-05-10 21:10 ` Štěpán Němec
  2010-05-16 10:50 ` Uday S Reddy
  2 siblings, 0 replies; 15+ messages in thread
From: Štěpán Němec @ 2010-05-10 21:10 UTC (permalink / raw)
  To: Harry Putnam; +Cc: help-gnu-emacs

Harry Putnam <reader@newsguy.com> writes:

> I see there are no customizing option matching
> `exchange-point-and-mark' (Ctrl-x Ctrl-x)
>
> I wondered if I can do anyghing about the current behavior where when
> the exchange is made, the area in between is selected and highlighted.
>
> I don't want to turn off the newish behavior of how regions are
> selected, where it takes two strikes of spc bar to turn it off.  I
> know there is a way to turn that off, but wondered if I might be able
> to ditch that un-wanted behavior some other way.

Did you actually read the documentation of `exchange-point-and-mark'?
Unless I'm missing something, using a prefix argument should do what you
want.

Štěpán



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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
  2010-05-10 20:34 ` Sean Sieger
@ 2010-05-11 10:53   ` Harry Putnam
  2010-05-11 11:47     ` Richard Riley
       [not found]   ` <mailman.3.1273575216.918.help-gnu-emacs@gnu.org>
  2010-05-16  9:47   ` Uday S Reddy
  2 siblings, 1 reply; 15+ messages in thread
From: Harry Putnam @ 2010-05-11 10:53 UTC (permalink / raw)
  To: help-gnu-emacs

Sean Sieger <sean.sieger@gmail.com> writes:

> Harry Putnam <reader@newsguy.com> writes:
>
>     I see there are no customizing option matching
>     `exchange-point-and-mark' (Ctrl-x Ctrl-x)
>

> C-g doesn't suit you?
No not really... its actually quicker to strike spc bar twice (to me)

What I had hoped for was some setting so that there wouldn't be yet
more clickety clack to exchange point and mark .. I don't understand
why it defaults to selecting the region.  

Maybe I'm using C-x C-x for the wrong purpose (to return to previous
location) and should be using registers.. but again, its more messing
around.  That would require. 
  C-x r spc <select name> <enter>
  C-x r j  <select name <enter> to return

As opposed to C-x C-x

Maybe there are more ways to return to previous location?

[...]

Štěpán Němec <stepnem@gmail.com> writes:

[...]

> Did you actually read the documentation of `exchange-point-and-mark'?
> Unless I'm missing something, using a prefix argument should do what you

I saw that, yes but wasn't looking for a solution that involved more
key strokes.  Striking spc bar twice is bad enough but at least fairly
quick. 

Something like C-1 C-x C-x might get to be routine.. but doesn't seem
so handy just at a few tests.




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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
       [not found]   ` <mailman.3.1273575216.918.help-gnu-emacs@gnu.org>
@ 2010-05-11 11:38     ` Barry Margolin
  0 siblings, 0 replies; 15+ messages in thread
From: Barry Margolin @ 2010-05-11 11:38 UTC (permalink / raw)
  To: help-gnu-emacs

In article <mailman.3.1273575216.918.help-gnu-emacs@gnu.org>,
 Harry Putnam <reader@newsguy.com> wrote:

> Sean Sieger <sean.sieger@gmail.com> writes:
> 
> > Harry Putnam <reader@newsguy.com> writes:
> >
> >     I see there are no customizing option matching
> >     `exchange-point-and-mark' (Ctrl-x Ctrl-x)
> >
> 
> > C-g doesn't suit you?
> No not really... its actually quicker to strike spc bar twice (to me)
> 
> What I had hoped for was some setting so that there wouldn't be yet
> more clickety clack to exchange point and mark .. I don't understand
> why it defaults to selecting the region. 

This is the usual way to activate the mark.
 
> 
> Maybe I'm using C-x C-x for the wrong purpose (to return to previous
> location) and should be using registers.. but again, its more messing
> around.  That would require. 

You can use C-u C-@ to pop the mark ring.

-- 
Barry Margolin, barmar@alum.mit.edu
Arlington, MA
*** PLEASE post questions in newsgroups, not directly to me ***
*** PLEASE don't copy me on replies, I'll read them in the group ***


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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
  2010-05-11 10:53   ` Harry Putnam
@ 2010-05-11 11:47     ` Richard Riley
  2010-05-11 13:21       ` Harry Putnam
  0 siblings, 1 reply; 15+ messages in thread
From: Richard Riley @ 2010-05-11 11:47 UTC (permalink / raw)
  To: help-gnu-emacs

Harry Putnam <reader@newsguy.com> writes:

> Sean Sieger <sean.sieger@gmail.com> writes:
>
>> Harry Putnam <reader@newsguy.com> writes:
>>
>>     I see there are no customizing option matching
>>     `exchange-point-and-mark' (Ctrl-x Ctrl-x)
>>
>
>> C-g doesn't suit you?
> No not really... its actually quicker to strike spc bar twice (to me)
>
> What I had hoped for was some setting so that there wouldn't be yet
> more clickety clack to exchange point and mark .. I don't understand
> why it defaults to selecting the region.  
>
> Maybe I'm using C-x C-x for the wrong purpose (to return to previous
> location) and should be using registers.. but again, its more messing
> around.  That would require. 
>   C-x r spc <select name> <enter>
>   C-x r j  <select name <enter> to return
>
> As opposed to C-x C-x
>
> Maybe there are more ways to return to previous location?
>
> [...]
>
> Štěpán Němec <stepnem@gmail.com> writes:
>
> [...]
>
>> Did you actually read the documentation of `exchange-point-and-mark'?
>> Unless I'm missing something, using a prefix argument should do what you
>
> I saw that, yes but wasn't looking for a solution that involved more
> key strokes.  Striking spc bar twice is bad enough but at least fairly
> quick. 
>
> Something like C-1 C-x C-x might get to be routine.. but doesn't seem
> so handy just at a few tests.
>

I tend to use C-x C-x and then M-w rather than C-g. Yes, it does copy too but any paste
is soon rid of by M-y.  Heh, looking at it, it seems somewhat convoluted
but it works well for me with the way my hands rest on the keyboard.




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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
  2010-05-11 11:47     ` Richard Riley
@ 2010-05-11 13:21       ` Harry Putnam
  2010-05-11 14:06         ` Tim Visher
  2010-05-11 14:07         ` Sean Sieger
  0 siblings, 2 replies; 15+ messages in thread
From: Harry Putnam @ 2010-05-11 13:21 UTC (permalink / raw)
  To: help-gnu-emacs

> I tend to use C-x C-x and then M-w rather than C-g. Yes, it does
> copy too but any paste is soon rid of by M-y.  Heh, looking at it,
> it seems somewhat convoluted but it works well for me with the way
> my hands rest on the keyboard.

He he... .  How do you hit it?

left thumb to `M' and left middle/index finger to `w'

It seems pretty awkward here.. double strike to spc bar to loose
the highlight seems quickest... but I've been using for a while too.

Ever since the new highlight defaults come into effect.

Although C-g would be a close second.  Some how I never thought of
C-g.  I use it dozens of times a day to stop all kinds of things,
just never occurred to me to use it for this purpose (loosing the
hightlight).  It might grow on me.




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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
  2010-05-11 13:21       ` Harry Putnam
@ 2010-05-11 14:06         ` Tim Visher
  2010-05-11 22:02           ` Harry Putnam
  2010-05-11 14:07         ` Sean Sieger
  1 sibling, 1 reply; 15+ messages in thread
From: Tim Visher @ 2010-05-11 14:06 UTC (permalink / raw)
  To: Harry Putnam; +Cc: help-gnu-emacs

On Tue, May 11, 2010 at 9:21 AM, Harry Putnam <reader@newsguy.com> wrote:
> Ever since the new highlight defaults come into effect.
>
> Although C-g would be a close second.  Some how I never thought of
> C-g.  I use it dozens of times a day to stop all kinds of things,
> just never occurred to me to use it for this purpose (loosing the
> hightlight).  It might grow on me.

Am I understanding correctly that what you're trying to accomplish is
to not have the current region highlighted when you C-x C-x?

If that's the case, why not just `M-x customize-variable
transient-mark-mode`?  I didn't like the highlighting of the region so
I prefer turning tranient mark mode on manually (`C-SPC C-SPC`) if I
want it (almost never) rather than having it on all the time.

Another option that would avoid transient-mark-mode would be to use
pop-global-mark with `C-u C-SPC` instead of `C-x C-x` which doesn't
leave the mark active, if your only goal is to return to a previous
location and forget about the current location.

-- 

In Christ,

Timmy V.

http://burningones.com/
http://five.sentenc.es/ - Spend less time on e-mail



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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
  2010-05-11 13:21       ` Harry Putnam
  2010-05-11 14:06         ` Tim Visher
@ 2010-05-11 14:07         ` Sean Sieger
  1 sibling, 0 replies; 15+ messages in thread
From: Sean Sieger @ 2010-05-11 14:07 UTC (permalink / raw)
  To: help-gnu-emacs

Harry Putnam <reader@newsguy.com> writes:

    > I tend to use C-x C-x and then M-w rather than C-g. Yes, it does
    > copy too but any paste is soon rid of by M-y.  Heh, looking at it,
    > it seems somewhat convoluted but it works well for me with the way
    > my hands rest on the keyboard.

    He he... .  How do you hit it?

    left thumb to `M' and left middle/index finger to `w'

Right middle finger and left ring finger.




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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
  2010-05-11 14:06         ` Tim Visher
@ 2010-05-11 22:02           ` Harry Putnam
  2010-05-13 14:43             ` Tim Visher
  0 siblings, 1 reply; 15+ messages in thread
From: Harry Putnam @ 2010-05-11 22:02 UTC (permalink / raw)
  To: help-gnu-emacs

Tim Visher <tim.visher@gmail.com> writes:

> Am I understanding correctly that what you're trying to accomplish is
> to not have the current region highlighted when you C-x C-x?

Your understanding it alright, just missing what was in the OP:

Harry wrote in OP:
> > I don't want to turn off the newish behavior of how regions are
> > selected, where it takes two strikes of spc bar to turn it off.  I
> > know there is a way to turn that off, but wondered if I might be
> > able to ditch that un-wanted behavior some other way.

> Another option that would avoid transient-mark-mode would be to use
> pop-global-mark with `C-u C-SPC` instead of `C-x C-x` which doesn't
> leave the mark active, if your only goal is to return to a previous
> location and forget about the current location.

That is a good one to know but I mostly do flip back and forth, but
thanks for the tip... I didn't know about C-u C-spc




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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
  2010-05-11 22:02           ` Harry Putnam
@ 2010-05-13 14:43             ` Tim Visher
  2010-05-14  1:30               ` Harry Putnam
  0 siblings, 1 reply; 15+ messages in thread
From: Tim Visher @ 2010-05-13 14:43 UTC (permalink / raw)
  To: Harry Putnam; +Cc: help-gnu-emacs

On Tue, May 11, 2010 at 6:02 PM, Harry Putnam <reader@newsguy.com> wrote:
> Tim Visher <tim.visher@gmail.com> writes:
>
>> Am I understanding correctly that what you're trying to accomplish is
>> to not have the current region highlighted when you C-x C-x?
>
> Your understanding it alright, just missing what was in the OP:
>
> Harry wrote in OP:
>> > I don't want to turn off the newish behavior of how regions are
>> > selected, where it takes two strikes of spc bar to turn it off.  I
>> > know there is a way to turn that off, but wondered if I might be
>> > able to ditch that un-wanted behavior some other way.

Whoops.  I guess my next question would be why you don't want to just
turn it off.  What does that feature do that you're using?  Perhaps by
elaborating in that direction we could come to a solution that meets
your needs.

-- 

In Christ,

Timmy V.

http://burningones.com/
http://five.sentenc.es/ - Spend less time on e-mail



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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
  2010-05-13 14:43             ` Tim Visher
@ 2010-05-14  1:30               ` Harry Putnam
  0 siblings, 0 replies; 15+ messages in thread
From: Harry Putnam @ 2010-05-14  1:30 UTC (permalink / raw)
  To: help-gnu-emacs

Tim Visher <tim.visher@gmail.com> writes:

> On Tue, May 11, 2010 at 6:02 PM, Harry Putnam <reader@newsguy.com> wrote:
>> Tim Visher <tim.visher@gmail.com> writes:
>>
>>> Am I understanding correctly that what you're trying to accomplish is
>>> to not have the current region highlighted when you C-x C-x?
>>
>> Your understanding it alright, just missing what was in the OP:
>>
>> Harry wrote in OP:
>>> > I don't want to turn off the newish behavior of how regions are
>>> > selected, where it takes two strikes of spc bar to turn it off.  I
>>> > know there is a way to turn that off, but wondered if I might be
>>> > able to ditch that un-wanted behavior some other way.
>
> Whoops.  I guess my next question would be why you don't want to just
> turn it off.  What does that feature do that you're using?  Perhaps by
> elaborating in that direction we could come to a solution that meets
> your needs.

I'm pretty much decided its not a bit enough annoyance to do much else
about.

I hated the default `on' regional highlight when they first changed
it. You used to have to activate it on purpose.  But secretly it was
growing on me I guess, because recently turning it off, and I missed
it right away.
I don't really purposely use it... its just a visual reminder of what
you have in the region... handy lots of times just knowing that.




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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
  2010-05-10 20:34 ` Sean Sieger
  2010-05-11 10:53   ` Harry Putnam
       [not found]   ` <mailman.3.1273575216.918.help-gnu-emacs@gnu.org>
@ 2010-05-16  9:47   ` Uday S Reddy
  2 siblings, 0 replies; 15+ messages in thread
From: Uday S Reddy @ 2010-05-16  9:47 UTC (permalink / raw)
  To: help-gnu-emacs

On 5/10/2010 9:34 PM, Sean Sieger wrote:
> Harry Putnam<reader@newsguy.com>  writes:
>
>      I see there are no customizing option matching
>      `exchange-point-and-mark' (Ctrl-x Ctrl-x)
>
> C-g doesn't suit you?

There is at least one situation where C-g doesn't suit me (or any one, for that matter).

Once you set the mark down and start an incremental-search, you can't type C-g because that would cancel the search. The highlighting then feels incredibly sticky.

Cheers,
Uday




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

* Re: Ctrl-x Ctrl-x (exchange-point-and-mark)
  2010-05-10 19:42 Ctrl-x Ctrl-x (exchange-point-and-mark) Harry Putnam
  2010-05-10 20:34 ` Sean Sieger
  2010-05-10 21:10 ` Štěpán Němec
@ 2010-05-16 10:50 ` Uday S Reddy
  2 siblings, 0 replies; 15+ messages in thread
From: Uday S Reddy @ 2010-05-16 10:50 UTC (permalink / raw)
  To: help-gnu-emacs

On 5/10/2010 8:42 PM, Harry Putnam wrote:
> I see there are no customizing option matching
> `exchange-point-and-mark' (Ctrl-x Ctrl-x)
>
> I wondered if I can do anyghing about the current behavior where when
> the exchange is made, the area in between is selected and highlighted.

If you put the following advice in your .emacs file, normal C-x C-x will have the effect of C-u C-x C-x and vice versa.

(defadvice exchange-point-and-mark (before toggled-mark activate)
   "Toggle activation of mark for exchange-point-and-mark."
   (interactive "P")
   (ad-set-arg 0 (null (ad-get-arg 0))))

This doesn't quite do what I would have liked myself.  Ideally, C-x C-x should keep the mark active if it is already active and refrain from activating it afresh.  This advice ends up deactivating the mark.  Can anybody beef up the advice more to get the better behavior?

Cheers,
Uday






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

end of thread, other threads:[~2010-05-16 10:50 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-10 19:42 Ctrl-x Ctrl-x (exchange-point-and-mark) Harry Putnam
2010-05-10 20:34 ` Sean Sieger
2010-05-11 10:53   ` Harry Putnam
2010-05-11 11:47     ` Richard Riley
2010-05-11 13:21       ` Harry Putnam
2010-05-11 14:06         ` Tim Visher
2010-05-11 22:02           ` Harry Putnam
2010-05-13 14:43             ` Tim Visher
2010-05-14  1:30               ` Harry Putnam
2010-05-11 14:07         ` Sean Sieger
     [not found]   ` <mailman.3.1273575216.918.help-gnu-emacs@gnu.org>
2010-05-11 11:38     ` Barry Margolin
2010-05-16  9:47   ` Uday S Reddy
2010-05-10 21:10 ` Štěpán Němec
2010-05-16 10:50 ` Uday S Reddy
     [not found] <mailman.10.1273520565.11383.help-gnu-emacs@gnu.org>
2010-05-10 21:01 ` Andreas Politz

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