GNU bug report logs - #2534
NS: clipboard-kill-ring-save and clipboard-yank etc. not available

Previous Next

Packages: emacs, ns;

Reported by: David Reitter <david.reitter <at> gmail.com>

Date: Mon, 2 Mar 2009 03:20:03 UTC

Severity: normal

Done: David Reitter <reitter <at> cmu.edu>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (Emacs bug Tracking System)
To: David Reitter <david.reitter <at> gmail.com>
Subject: bug#2534 closed by David Reitter <reitter <at> cmu.edu> (fixed)
Date: Mon, 04 May 2009 16:35:09 +0000
[Message part 1 (text/plain, inline)]
This is an automatic notification regarding your bug report
which was filed against the emacs,ns package:

#2534: NS: clipboard-kill-ring-save and clipboard-yank etc. not available

It has been closed by David Reitter <reitter <at> cmu.edu>.

Their explanation is attached below along with your original report.
If this explanation is unsatisfactory and you have not received a
better one in a separate message then please contact David Reitter <reitter <at> cmu.edu> by
replying to this email.


-- 
2534: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=2534
Emacs Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: David Reitter <reitter <at> cmu.edu>
To: 2534-done <at> debbugs.gnu.org
Subject: fixed
Date: Mon, 4 May 2009 12:27:46 -0400
fixed by removing the apparently obsolete code in term/ns-win.el that  
deletes these functions

[Message part 3 (message/rfc822, inline)]
From: David Reitter <david.reitter <at> gmail.com>
To: emacs-pretest-bug <at> gnu.org
Subject: NS: clipboard-kill-ring-save and clipboard-yank etc. not available
Date: Sun, 1 Mar 2009 22:13:47 -0500
[Message part 4 (text/plain, inline)]
A number of functions such as `clipboard-kill-ring-save' are not  
available in the NS port because term/ns-win.el unbinds them.
It took me a long time to figure out, because they are pre-loaded in  
menu-bar.el and present in `load-history'.

In the interest of compatibility with existing Emacs 22 code, and also  
with Emacs 23 code written on other platforms, these functions should  
exist and do what they're documented to do.

Note that commands like `ns-copy-including-secondary' are bound to  
menu bar items and to shortcuts such as Command-C (when CUA mode is  
off), but they are not documented.  I would happily write some  
docstrings, but it isn't clear to me why one would always want to set  
the secondary "cut buffer" in this situation.



term/ns-win.el:

;; Must come after keybindings.

(fmakunbound 'clipboard-yank)
(fmakunbound 'clipboard-kill-ring-save)
(fmakunbound 'clipboard-kill-region)
(fmakunbound 'menu-bar-enable-clipboard)

...

(defun ns-copy-including-secondary ()
  (interactive)
  (call-interactively 'kill-ring-save)
  (ns-store-cut-buffer-internal 'SECONDARY
				(buffer-substring (point) (mark t))))
(defun ns-paste-secondary ()
  (interactive)
  (insert (ns-get-cut-buffer-internal 'SECONDARY)))

[smime.p7s (application/pkcs7-signature, attachment)]

This bug report was last modified 16 years and 78 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.