help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Emacs kill/copy under X versus under Windows


From: Jeff Clough
Subject: Emacs kill/copy under X versus under Windows
Date: Sun, 30 Aug 2009 12:54:17 -0400
User-agent: Thunderbird 2.0.0.23 (Windows/20090812)

While dinking around with kill/yank and copy/paste to answer a question posted earlier, I stumbled upon something that I'd like to know how to fix.

Running 22.3 on both Windows and X, I notice a difference in how Emacs interacts with the clipboard.

Under X, killing and yanking text with the "normal" commands (such as kill-line) only diddles the kill ring and doesn't touch the clipboard selection. Copying text in another application does not affect what you get when doing C-y in Emacs. C-y doesn't care about your clipboard selection at all and neither does C-k, etc. When you *do* care about such things, there are specific commands (like "Copy" from the menu) that let you do things.

Under Windows, this isn't true at all. Whatever you last killed goes straight to the clipboard, and whatever you last copied in another application gets dumped into your buffer with a yank. What's worse, try this in Windows:

1.  Type a line of text in Emacs and do a kill-line on it.
2.  Copy a different line of text from some other application.
3. Do a (car kill-ring) in emacs. See it display the text you typed from step #1.
4.  Do a C-y in emacs, this dumps in the text from step #2.
5. Do (car kill-ring) again and see that the text from #2 has magically been added to the kill ring.

I should note that C-y, C-k and the like are all mapped to functions with the same names on both platforms (yank and kill-line, respectively) and doing a describe-function on these functions has no hint they should be working any differently.

So we have different behavior between ports for I don't know what reason (is it really assumed that someone capable of downloading and using Emacs on their Windows box is going to be confused by the behavior found on X systems?), and some *truly* nutty behavior under the Windows side.

Is there some way to make Emacs on Windows behave itself and ignore the clipboard unless told otherwise, just like under X?

Jeff

--

Author of the Genesys System
A "free" universal role-playing game.
http://www.chaosphere.com/genesys/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]