all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* mouse and Delete key
@ 2005-07-30 22:03 Baloff
  2005-07-31  0:35 ` Drew Adams
  0 siblings, 1 reply; 3+ messages in thread
From: Baloff @ 2005-07-30 22:03 UTC (permalink / raw)


Hello

I was reading the node on the mouse commands, this is not working, 

Mouse Commands for Editing
==========================
...
   If you select a region with any of these mouse commands, and then
immediately afterward type the <DELETE> function key, it deletes the
region that you selected. 

I mouse-1 say at the beginning of a line and mouse-3 past the end char. 
then hit the <Delete> key. it does not delete the line "region" but
only the last character.

what am I doing wrong, how can I delete a region. I usually do C-w but that 
puts it in the kill buffer.

thanks

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

* RE: mouse and Delete key
  2005-07-30 22:03 mouse and Delete key Baloff
@ 2005-07-31  0:35 ` Drew Adams
  0 siblings, 0 replies; 3+ messages in thread
From: Drew Adams @ 2005-07-31  0:35 UTC (permalink / raw)


    I was reading the node on the mouse commands, this is not working,

Very good to hear that you are reading the doc! Good initiative.

    Mouse Commands for Editing
    ==========================
    ...
       If you select a region with any of these mouse commands, and then
    immediately afterward type the <DELETE> function key, it deletes the
    region that you selected.

The text goes on to say this (next sentence):

 The <BACKSPACE> function key and the ASCII
 character <DEL> do not do this; if you type any other key in between
 the mouse command and <DELETE>, it does not do this.

    I mouse-1 say at the beginning of a line and mouse-3 past the end char.
    then hit the <Delete> key. it does not delete the line "region" but
    only the last character.

    what am I doing wrong, how can I delete a region. I usually do
    C-w but that puts it in the kill buffer.

This kind of info always helps us help you: What emacs version are you
running? Do this to find out: `C-h v emacs-version' (or choose Help>About
Emacs in the menu).

I'd guess that you are trying to use the Backspace key, also known as `DEL',
not the Delete key. On my (PC) keyboard, the Delete key is labeled "Delete"
and is just below the Insert key in the middle keypad (which is just to the
left of the numeric keypad).

An alternative to using Delete is to use `C-d'. If you don't have a Delete
key, try that.

Try this: `C-h k <hit the key that you _think_ is "Delete">

It should say something like this:

 C-d (translated from <delete>) runs the command delete-char
    which is an interactive built-in function in `C source code'.
 It is bound to C-d, <deletechar>.
 (delete-char n &optional killflag)

 Delete the following n characters (previous if n is negative).
 Optional second arg killflag non-nil means kill instead (save in kill
ring).
 Interactively, n is the prefix arg, and killflag is set if
 n was explicitly specified.

Keep reading and experimenting - you're on the right track now.

BTW - If you are using the mouse anyway, the quickest way to delete the
selection (region) you've created is just to click mouse-3 again, without
moving the mouse. For example: mouse-1; move mouse; mouse-3; mouse-3.

This does put the region in the kill ring. But so does the method above:
mouse-1; move mouse; mouse-3; <Delete>.

Why don't you want the region in the kill ring? Are you aware that you can
get to (that is, paste) older kill-ring entries by using `C-y M-y M-y...'?

HTH

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

* Re: mouse and Delete key
       [not found] <mailman.2135.1122770344.20277.help-gnu-emacs@gnu.org>
@ 2005-07-31  3:23 ` Baloff
  0 siblings, 0 replies; 3+ messages in thread
From: Baloff @ 2005-07-31  3:23 UTC (permalink / raw)


"Drew Adams" <drew.adams@oracle.com> writes:

>    
> 
>     Mouse Commands for Editing
>     ==========================
>     ...
>        If you select a region with any of these mouse commands, and then
>     immediately afterward type the <DELETE> function key, it deletes the
>     region that you selected.
> 
> The text goes on to say this (next sentence):
> 
>  The <BACKSPACE> function key and the ASCII
>  character <DEL> do not do this; if you type any other key in between
>  the mouse command and <DELETE>, it does not do this.
> 
> 
> This kind of info always helps us help you: What emacs version are you
> running? Do this to find out: `C-h v emacs-version' (or choose Help>About
> Emacs in the menu).

emacs-version's value is "21.4.1"

> 
> I'd guess that you are trying to use the Backspace key, also known as `DEL',
> not the Delete key. On my (PC) keyboard, the Delete key is labeled "Delete"
> and is just below the Insert key in the middle keypad (which is just to the
> left of the numeric keypad).

yes, it is exactly as you described, in my Logitech Internet
Keyboard. Delete key under the Insert in the middle keypad.

> 
> An alternative to using Delete is to use `C-d'. If you don't have a Delete
> key, try that.
> 
> Try this: `C-h k <hit the key that you _think_ is "Delete">
> 
> It should say something like this:
> 
>  C-d (translated from <delete>) runs the command delete-char
>     which is an interactive built-in function in `C source code'.
>  It is bound to C-d, <deletechar>.
>  (delete-char n &optional killflag)
> 
>  Delete the following n characters (previous if n is negative).
>  Optional second arg killflag non-nil means kill instead (save in kill
> ring).
>  Interactively, n is the prefix arg, and killflag is set if
>  n was explicitly specified.
> 
true, thanks, that works

> Keep reading and experimenting - you're on the right track now.
thanks for the encouragements, I needed it.
> 
> BTW - If you are using the mouse anyway, the quickest way to delete the
> selection (region) you've created is just to click mouse-3 again, without
> moving the mouse. For example: mouse-1; move mouse; mouse-3; mouse-3.
> 
> This does put the region in the kill ring. But so does the method above:
> mouse-1; move mouse; mouse-3; <Delete>.
> 
> Why don't you want the region in the kill ring? Are you aware that you can
> get to (that is, paste) older kill-ring entries by using `C-y M-y M-y...'?
> 
> HTH

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

end of thread, other threads:[~2005-07-31  3:23 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-07-30 22:03 mouse and Delete key Baloff
2005-07-31  0:35 ` Drew Adams
     [not found] <mailman.2135.1122770344.20277.help-gnu-emacs@gnu.org>
2005-07-31  3:23 ` Baloff

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.