public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* Windows clipboard and Emacs yank, kill-region, and kill-ring-save
@ 2012-08-08 21:11 Tim McDaniel
  2012-08-08 21:59 ` Ken Brown
  0 siblings, 1 reply; 8+ messages in thread
From: Tim McDaniel @ 2012-08-08 21:11 UTC (permalink / raw)
  To: cygwin

I have updated my packages to the latest versions.  I have long had
installed
- emacs
- emacs-X11
- emacs-el
- xemacs-emacs-common
- X11

In Emacs, ^Y is the default keystroke for the basic "yank", to paste
the contents of the most recently element of the kill ring (the text
most recently cut or copied in Emacs).  Until some time in the past
few weeks, I am 80% sure that ^Y would grab out of the Windows
clipboard -- that is, I could copy in Windows using ^C or Ctrl-Ins,
and then use ^Y in Emacs to paste it.

But I think that sometime in the last few weeks, perhaps with the
end-of-July update of Emacs in Cygwin, it stopped working.  Now, ^Y
only pastes what was killed (or copied) in Emacs.  Similarly, if I
kill or copy text in Emacs, it's not put into the Window clipboard.

Any Emacs users out there?

Am I misremembering the old behavior?  At home I use Linux, and there
the X clipboard and Emacs clipboard usually work together (modulo
X having more than one).

If I'm not, did something change, and can I do some setting to obviate
it in Emacs?

-- 
Tim McDaniel, tmcd@panix.com

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

* Re: Windows clipboard and Emacs yank, kill-region, and kill-ring-save
  2012-08-08 21:11 Windows clipboard and Emacs yank, kill-region, and kill-ring-save Tim McDaniel
@ 2012-08-08 21:59 ` Ken Brown
  2012-08-08 23:04   ` Tim McDaniel
  0 siblings, 1 reply; 8+ messages in thread
From: Ken Brown @ 2012-08-08 21:59 UTC (permalink / raw)
  To: cygwin

On 8/8/2012 4:49 PM, Tim McDaniel wrote:
> I have updated my packages to the latest versions.  I have long had
> installed
> - emacs
> - emacs-X11
> - emacs-el
> - xemacs-emacs-common
> - X11
>
> In Emacs, ^Y is the default keystroke for the basic "yank", to paste
> the contents of the most recently element of the kill ring (the text
> most recently cut or copied in Emacs).  Until some time in the past
> few weeks, I am 80% sure that ^Y would grab out of the Windows
> clipboard -- that is, I could copy in Windows using ^C or Ctrl-Ins,
> and then use ^Y in Emacs to paste it.
>
> But I think that sometime in the last few weeks, perhaps with the
> end-of-July update of Emacs in Cygwin, it stopped working.  Now, ^Y
> only pastes what was killed (or copied) in Emacs.  Similarly, if I
> kill or copy text in Emacs, it's not put into the Window clipboard.
>
> Any Emacs users out there?
>
> Am I misremembering the old behavior?  At home I use Linux, and there
> the X clipboard and Emacs clipboard usually work together (modulo
> X having more than one).
>
> If I'm not, did something change, and can I do some setting to obviate
> it in Emacs?

There have been some changes in how emacs handles selections, starting 
with emacs-24.1.  Look at the NEWS file ('C-h n') and search for 
"selection changes".  It describes the changes and tells you how to 
restore the old behavior.

Ken


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

* Re: Windows clipboard and Emacs yank, kill-region, and kill-ring-save
  2012-08-08 21:59 ` Ken Brown
@ 2012-08-08 23:04   ` Tim McDaniel
  2012-08-19 19:29     ` Ken Jackson
  0 siblings, 1 reply; 8+ messages in thread
From: Tim McDaniel @ 2012-08-08 23:04 UTC (permalink / raw)
  Cc: cygwin

On Wed, 8 Aug 2012, Ken Brown <kbrown@cornell.edu> wrote:
> There have been some changes in how emacs handles selections,
> starting with emacs-24.1.  Look at the NEWS file ('C-h n') and
> search for "selection changes".  It describes the changes and tells
> you how to restore the old behavior.

Yes!  The important one for me is

(setq x-select-enable-primary t)

Thank you very much for the quick and informative answer!

-- 
Tim McDaniel, tmcd@panix.com

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

* Re: Windows clipboard and Emacs yank, kill-region, and kill-ring-save
  2012-08-08 23:04   ` Tim McDaniel
@ 2012-08-19 19:29     ` Ken Jackson
  2012-08-19 20:32       ` Ken Brown
  0 siblings, 1 reply; 8+ messages in thread
From: Ken Jackson @ 2012-08-19 19:29 UTC (permalink / raw)
  To: cygwin

On 08/08/2012 06:17 PM, Tim McDaniel wrote:
> On Wed, 8 Aug 2012, Ken Brown <kbrown@cornell.edu> wrote:
>> There have been some changes in how emacs handles selections,
>> starting with emacs-24.1.  Look at the NEWS file ('C-h n') and
>> search for "selection changes".  It describes the changes and tells
>> you how to restore the old behavior.
>
> Yes!  The important one for me is
>
> (setq x-select-enable-primary t)
>
> Thank you very much for the quick and informative answer!

Are you talking about X11 emacs, or emacs in a terminal?

I have this in my ~/.emacs file on both Linux and Cygwin:
(setq x-select-enable-clipboard t)

I see in the news file that it's now set by default.
It has always worked in graphical emacs but has never
worked in a terminal on either Linux or Cygwin.

But I sure would like it to work in a terminal.  Are you
able to paste clipboard text in emacs in a terminal?

-Ken


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

* Re: Windows clipboard and Emacs yank, kill-region, and kill-ring-save
  2012-08-19 19:29     ` Ken Jackson
@ 2012-08-19 20:32       ` Ken Brown
  2012-08-19 22:05         ` Ken Jackson
  0 siblings, 1 reply; 8+ messages in thread
From: Ken Brown @ 2012-08-19 20:32 UTC (permalink / raw)
  To: cygwin

On 8/19/2012 2:50 PM, Ken Jackson wrote:
> On 08/08/2012 06:17 PM, Tim McDaniel wrote:
>> On Wed, 8 Aug 2012, Ken Brown <kbrown@cornell.edu> wrote:
>>> There have been some changes in how emacs handles selections,
>>> starting with emacs-24.1.  Look at the NEWS file ('C-h n') and
>>> search for "selection changes".  It describes the changes and tells
>>> you how to restore the old behavior.
>>
>> Yes!  The important one for me is
>>
>> (setq x-select-enable-primary t)
>>
>> Thank you very much for the quick and informative answer!
>
> Are you talking about X11 emacs, or emacs in a terminal?
>
> I have this in my ~/.emacs file on both Linux and Cygwin:
> (setq x-select-enable-clipboard t)
>
> I see in the news file that it's now set by default.
> It has always worked in graphical emacs but has never
> worked in a terminal on either Linux or Cygwin.
>
> But I sure would like it to work in a terminal.  Are you
> able to paste clipboard text in emacs in a terminal?

When I run emacs in mintty, I can paste clipboard text with Shift-Insert.

Ken


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

* Re: Windows clipboard and Emacs yank, kill-region, and kill-ring-save
  2012-08-19 20:32       ` Ken Brown
@ 2012-08-19 22:05         ` Ken Jackson
  2012-08-19 23:22           ` Ken Brown
  2012-08-29 19:43           ` Andy Koppe
  0 siblings, 2 replies; 8+ messages in thread
From: Ken Jackson @ 2012-08-19 22:05 UTC (permalink / raw)
  To: cygwin

On 08/19/2012 03:54 PM, Ken Brown wrote:
> On 8/19/2012 2:50 PM, Ken Jackson wrote:
>> I have this in my ~/.emacs file on both Linux and Cygwin:
>> (setq x-select-enable-clipboard t)
>>
>> I see in the news file that it's now set by default.
>> It has always worked in graphical emacs but has never
>> worked in a terminal on either Linux or Cygwin.
>>
>> But I sure would like it to work in a terminal.  Are you
>> able to paste clipboard text in emacs in a terminal?
>
> When I run emacs in mintty, I can paste clipboard text with Shift-Insert.
>
> Ken
>
Ah!  That works!  Thank you.

But there are still a couple problems.

1) Shift-Insert is a huge improvement, but is still a little
    clunky.  I'd like to tie it to Shift-Ctrl-Y, but when I
    press CTRL-h Shift-Insert, the *Help* window cryptically
    reports, "T runs the command self-insert-command".  What
    command is actually running?

2) How can I go the other way--copy from emacs in a terminal
    to the Windows clipboard?

-Ken Jackson


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

* Re: Windows clipboard and Emacs yank, kill-region, and kill-ring-save
  2012-08-19 22:05         ` Ken Jackson
@ 2012-08-19 23:22           ` Ken Brown
  2012-08-29 19:43           ` Andy Koppe
  1 sibling, 0 replies; 8+ messages in thread
From: Ken Brown @ 2012-08-19 23:22 UTC (permalink / raw)
  To: cygwin

On 8/19/2012 5:18 PM, Ken Jackson wrote:
> On 08/19/2012 03:54 PM, Ken Brown wrote:
>> On 8/19/2012 2:50 PM, Ken Jackson wrote:
>>> I have this in my ~/.emacs file on both Linux and Cygwin:
>>> (setq x-select-enable-clipboard t)
>>>
>>> I see in the news file that it's now set by default.
>>> It has always worked in graphical emacs but has never
>>> worked in a terminal on either Linux or Cygwin.
>>>
>>> But I sure would like it to work in a terminal.  Are you
>>> able to paste clipboard text in emacs in a terminal?
>>
>> When I run emacs in mintty, I can paste clipboard text with Shift-Insert.
>>
>> Ken
>>
> Ah!  That works!  Thank you.
>
> But there are still a couple problems.
>
> 1) Shift-Insert is a huge improvement, but is still a little
>     clunky.  I'd like to tie it to Shift-Ctrl-Y, but when I
>     press CTRL-h Shift-Insert, the *Help* window cryptically
>     reports, "T runs the command self-insert-command".  What
>     command is actually running?

"T" was probably the first character of the text you pasted.  I think 
it's mintty that processes the Shift-Insert; emacs never sees it.

> 2) How can I go the other way--copy from emacs in a terminal
>     to the Windows clipboard?

Select it with the mouse.  Again, it's mintty that's doing the copying 
here; emacs doesn't see the mouse operations.

Ken


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

* Re: Windows clipboard and Emacs yank, kill-region, and kill-ring-save
  2012-08-19 22:05         ` Ken Jackson
  2012-08-19 23:22           ` Ken Brown
@ 2012-08-29 19:43           ` Andy Koppe
  1 sibling, 0 replies; 8+ messages in thread
From: Andy Koppe @ 2012-08-29 19:43 UTC (permalink / raw)
  To: cygwin

On 19 August 2012 22:18, Ken Jackson wrote:
> On 08/19/2012 03:54 PM, Ken Brown wrote:
>>
>> On 8/19/2012 2:50 PM, Ken Jackson wrote:
>>>
>>> I have this in my ~/.emacs file on both Linux and Cygwin:
>>> (setq x-select-enable-clipboard t)
>>>
>>> I see in the news file that it's now set by default.
>>> It has always worked in graphical emacs but has never
>>> worked in a terminal on either Linux or Cygwin.
>>>
>>> But I sure would like it to work in a terminal.  Are you
>>> able to paste clipboard text in emacs in a terminal?
>>
>>
>> When I run emacs in mintty, I can paste clipboard text with Shift-Insert.
>>
>> Ken
>>
> Ah!  That works!  Thank you.
>
> But there are still a couple problems.
>
> 1) Shift-Insert is a huge improvement, but is still a little
>    clunky.  I'd like to tie it to Shift-Ctrl-Y

In mintty, you can enable Ctrl+Shift+letter shortcuts including
Ctrl+Shift+Y for Paste on the Keys page of its options.

Andy

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

end of thread, other threads:[~2012-08-29 18:55 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-08-08 21:11 Windows clipboard and Emacs yank, kill-region, and kill-ring-save Tim McDaniel
2012-08-08 21:59 ` Ken Brown
2012-08-08 23:04   ` Tim McDaniel
2012-08-19 19:29     ` Ken Jackson
2012-08-19 20:32       ` Ken Brown
2012-08-19 22:05         ` Ken Jackson
2012-08-19 23:22           ` Ken Brown
2012-08-29 19:43           ` Andy Koppe

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