* 2 ways to paste
@ 2008-11-06 15:38 tomer
2008-11-06 16:18 ` Xah
` (3 more replies)
0 siblings, 4 replies; 9+ messages in thread
From: tomer @ 2008-11-06 15:38 UTC (permalink / raw)
To: help-gnu-emacs
here his the scenario ( timed order):
1) i mark region A
2) i copy (alt+w) region B
now i want the have the possiblity to yank region A and region B each
with different command.
is it possible?
in other words , Is it possible to have 2 different indepenable
mechanism for
1) copy yank marking block (with mark and set).
2) copy yank block that was copied to clipboard by alt+w.
hope my question is cleared
Thanks
Tomer
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: 2 ways to paste
2008-11-06 15:38 2 ways to paste tomer
@ 2008-11-06 16:18 ` Xah
2008-11-06 22:59 ` Nikolaj Schumacher
[not found] ` <mailman.3022.1226012387.25473.help-gnu-emacs@gnu.org>
2008-11-06 17:06 ` Drew Adams
` (2 subsequent siblings)
3 siblings, 2 replies; 9+ messages in thread
From: Xah @ 2008-11-06 16:18 UTC (permalink / raw)
To: help-gnu-emacs
On Nov 6, 7:38 am, tomer <tomer1le...@walla.co.il> wrote:
> here his the scenario ( timed order):
> 1) i mark region A
> 2) i copy (alt+w) region B
>
> now i want the have the possiblity to yank region A and region B each
> with different command.
>
> is it possible?
>
> in other words , Is it possible to have 2 different indepenable
> mechanism for
> 1) copy yank marking block (with mark and set).
> 2) copy yank block that was copied to clipboard by alt+w.
>
> hope my question is cleared
(^_^) but am quite confused.
You want 2 independent clipboards, so that you can have different
texts in each, is that it?
If so, you can use emacs's so-called register.
See this tips page:
http://xahlee.org/emacs/emacs_esoteric.html
excerpt:
Q: I have a set of different texts i want to paste frequently. Is
there a way to use like multiple clipboards?
Yes. Select the region, then type “Ctrl+x r s” (or “Alt+x copy-to-
register”), give it a name such as 1. To paste it, type “Ctrl+x r
i” (or “Alt+x insert-register”).
If your text is frequently needed long term, such as a XML template or
signature, you can define a function and bind it to a key, so that it
inserts the string when you press a button. Here's a example:
(defun insert-p ()
"insert <p></p> at cursor point."
(interactive)
(insert "<p></p>")
(backward-char 4))
(global-set-key (kbd "<f8>") 'insert-p)
Put the above in your “.emacs”.
-----------------------
btw, your use of jargons is fairly confused.
Either use modern terms or stick with emacs's, throughout. Here's
simple table:
Modern Emacs
-----------------------------------
copy kill-ring-save
cut kill
paste yank
clipboard kill-ring
text selection region
window frame (sometimes “window” as in split-window-
vertically)
frame/pane window
left button mouse-1
mid button mouse-2
right button mouse-3
when you “mark”, you set a boundary to region. You don't “mark a
region”.
Xah
∑ http://xahlee.org/
☄
^ permalink raw reply [flat|nested] 9+ messages in thread
* RE: 2 ways to paste
2008-11-06 15:38 2 ways to paste tomer
2008-11-06 16:18 ` Xah
@ 2008-11-06 17:06 ` Drew Adams
[not found] ` <mailman.3009.1225991410.25473.help-gnu-emacs@gnu.org>
2008-11-06 23:00 ` Nikolaj Schumacher
3 siblings, 0 replies; 9+ messages in thread
From: Drew Adams @ 2008-11-06 17:06 UTC (permalink / raw)
To: 'tomer', help-gnu-emacs
> 1) i mark region A
> 2) i copy (alt+w) region B
>
> now i want the have the possiblity to yank region A and region B each
> with different command. is it possible?
>
> in other words, Is it possible to have 2 different indepenable
> mechanism for
> 1) copy yank marking block (with mark and set).
> 2) copy yank block that was copied to clipboard by alt+w.
1. Xah mentioned using registers.
2. You also have the secondary selection, which is like a second clipboard:
http://www.emacswiki.org/emacs/SecondarySelection. Very handy and probably
underused.
3. All text you kill or copy (`M-w') is available from the `kill-ring'. You can
yank (paste) any kill-ring item at any time.
In vanilla Emacs, you do that by `C-y M-y M-y M-y'... There are also various
ways to directly choose which item to paste, instead of cycling to it - see the
Emacs Wiki. In Icicles, for instance, `C-- C-y' (`icicle-completing-yank') lets
you use completion to choose the kill(s) to paste.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: 2 ways to paste
[not found] ` <mailman.3009.1225991410.25473.help-gnu-emacs@gnu.org>
@ 2008-11-06 22:29 ` tomer
2008-11-06 22:49 ` Drew Adams
2008-11-07 10:57 ` Bernardo Bacic
0 siblings, 2 replies; 9+ messages in thread
From: tomer @ 2008-11-06 22:29 UTC (permalink / raw)
To: help-gnu-emacs
Thanks for the reply
I will rephrase the question:
Is there an option to save a region to register immediately after it
is marked
(i.e mouse-1 goes up) (maybe mark hook?)
Thanks
Tomer
On Nov 6, 7:06 pm, "Drew Adams" <drew.ad...@oracle.com> wrote:
> > 1) i mark region A
> > 2) i copy (alt+w) region B
>
> > now i want the have the possiblity to yank region A and region B each
> > with different command. is it possible?
>
> > in other words, Is it possible to have 2 different indepenable
> > mechanism for
> > 1) copy yank marking block (with mark and set).
> > 2) copy yank block that was copied to clipboard by alt+w.
>
> 1. Xah mentioned using registers.
>
> 2. You also have the secondary selection, which is like a second clipboard:http://www.emacswiki.org/emacs/SecondarySelection. Very handy and probably
> underused.
>
> 3. All text you kill or copy (`M-w') is available from the `kill-ring'. You can
> yank (paste) any kill-ring item at any time.
>
> In vanilla Emacs, you do that by `C-y M-y M-y M-y'... There are also various
> ways to directly choose which item to paste, instead of cycling to it - see the
> Emacs Wiki. In Icicles, for instance, `C-- C-y' (`icicle-completing-yank') lets
> you use completion to choose the kill(s) to paste.
^ permalink raw reply [flat|nested] 9+ messages in thread
* RE: 2 ways to paste
2008-11-06 22:29 ` tomer
@ 2008-11-06 22:49 ` Drew Adams
2008-11-07 10:57 ` Bernardo Bacic
1 sibling, 0 replies; 9+ messages in thread
From: Drew Adams @ 2008-11-06 22:49 UTC (permalink / raw)
To: 'tomer', help-gnu-emacs
> Is there an option to save a region to register immediately after it
> is marked (i.e mouse-1 goes up) (maybe mark hook?)
Not that I know of. But you could probably bind mouse 1 to a command that does
that.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: 2 ways to paste
2008-11-06 16:18 ` Xah
@ 2008-11-06 22:59 ` Nikolaj Schumacher
[not found] ` <mailman.3022.1226012387.25473.help-gnu-emacs@gnu.org>
1 sibling, 0 replies; 9+ messages in thread
From: Nikolaj Schumacher @ 2008-11-06 22:59 UTC (permalink / raw)
To: Xah; +Cc: help-gnu-emacs
Xah <xahlee@gmail.com> wrote:
> Modern Emacs
> -----------------------------------
> window frame (sometimes “window” as in split-window-
> vertically)
I don't think there is such an exception. The "window" in
`split-window-vertically' refers to the selected window not to a frame.
regards,
Nikolaj Schumacher
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: 2 ways to paste
2008-11-06 15:38 2 ways to paste tomer
` (2 preceding siblings ...)
[not found] ` <mailman.3009.1225991410.25473.help-gnu-emacs@gnu.org>
@ 2008-11-06 23:00 ` Nikolaj Schumacher
3 siblings, 0 replies; 9+ messages in thread
From: Nikolaj Schumacher @ 2008-11-06 23:00 UTC (permalink / raw)
To: tomer; +Cc: help-gnu-emacs
tomer <tomer1levin@walla.co.il> wrote:
> here his the scenario ( timed order):
> 1) i mark region A
> 2) i copy (alt+w) region B
I'm confused. This doesn't seem possible in Emacs (in this order).
To copy a region, you need to move the cursor to B, and then region A is
no longer selected. Are you using Emacs in a terminal? In that case
Emacs doesn't know about region A.
regards,
Nikolaj Schumacher
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: 2 ways to paste
[not found] ` <mailman.3022.1226012387.25473.help-gnu-emacs@gnu.org>
@ 2008-11-07 2:13 ` Xah
0 siblings, 0 replies; 9+ messages in thread
From: Xah @ 2008-11-07 2:13 UTC (permalink / raw)
To: help-gnu-emacs
On Nov 6, 2:59 pm, Nikolaj Schumacher <m...@nschum.de> wrote:
> Xah <xah...@gmail.com> wrote:
> > Modern Emacs
> > -----------------------------------
> > window frame (sometimes “window” as in split-window-
> > vertically)
>
> I don't think there is such an exception. The "window" in
> `split-window-vertically' refers to the selected window not to a frame.
you right. Thanks. My statement was a afterthought add-in trying to
make emacs look bad. lol
Xah
∑ http://xahlee.org/
☄
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: 2 ways to paste
2008-11-06 22:29 ` tomer
2008-11-06 22:49 ` Drew Adams
@ 2008-11-07 10:57 ` Bernardo Bacic
1 sibling, 0 replies; 9+ messages in thread
From: Bernardo Bacic @ 2008-11-07 10:57 UTC (permalink / raw)
To: help-gnu-emacs
> Is there an option to save a region to register immediately after it
> is marked
> (i.e mouse-1 goes up) (maybe mark hook?)
click with mouse-1 at the start of the region
click with mouse-3 at the end of the region
the region should be available in the kill ring (under X window manager at least)
not in a register but it may be close enough
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2008-11-07 10:57 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-06 15:38 2 ways to paste tomer
2008-11-06 16:18 ` Xah
2008-11-06 22:59 ` Nikolaj Schumacher
[not found] ` <mailman.3022.1226012387.25473.help-gnu-emacs@gnu.org>
2008-11-07 2:13 ` Xah
2008-11-06 17:06 ` Drew Adams
[not found] ` <mailman.3009.1225991410.25473.help-gnu-emacs@gnu.org>
2008-11-06 22:29 ` tomer
2008-11-06 22:49 ` Drew Adams
2008-11-07 10:57 ` Bernardo Bacic
2008-11-06 23:00 ` Nikolaj Schumacher
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).