comparison lisp/select.el @ 371:cc15677e0335 r21-2b1

Import from CVS: tag r21-2b1
author cvs
date Mon, 13 Aug 2007 11:03:08 +0200
parents c9ae480b1fff
children 8626e4521993
comparison
equal deleted inserted replaced
370:bd866891f083 371:cc15677e0335
66 (x (x-yank-clipboard-selection)) 66 (x (x-yank-clipboard-selection))
67 (mswindows (mswindows-paste-clipboard)) 67 (mswindows (mswindows-paste-clipboard))
68 (otherwise nil))) 68 (otherwise nil)))
69 69
70 (defun selection-owner-p (&optional selection) 70 (defun selection-owner-p (&optional selection)
71 "Return t if current XEmacs process owns the given Selection. 71 "Return t if current emacs process owns the given Selection.
72 The arg should be the name of the selection in question, typically one 72 The arg should be the name of the selection in question, typically one
73 of the symbols PRIMARY, SECONDARY, or CLIPBOARD. (For convenience, 73 of the symbols PRIMARY, SECONDARY, or CLIPBOARD. (For convenience,
74 the symbol nil is the same as PRIMARY, and t is the same as 74 the symbol nil is the same as PRIMARY, and t is the same as
75 SECONDARY.)" 75 SECONDARY.)"
76 (interactive) 76 (interactive)
247 'valid-simple-selection-p) 247 'valid-simple-selection-p)
248 248
249 (defun cut-copy-clear-internal (mode) 249 (defun cut-copy-clear-internal (mode)
250 (or (memq mode '(cut copy clear)) (error "unkown mode %S" mode)) 250 (or (memq mode '(cut copy clear)) (error "unkown mode %S" mode))
251 (or (selection-owner-p) 251 (or (selection-owner-p)
252 (error "XEmacs does not own the primary selection")) 252 (error "emacs does not own the primary selection"))
253 (setq last-command nil) 253 (setq last-command nil)
254 (or primary-selection-extent 254 (or primary-selection-extent
255 (error "the primary selection is not an extent?")) 255 (error "the primary selection is not an extent?"))
256 (save-excursion 256 (save-excursion
257 (let (rect-p b s e) 257 (let (rect-p b s e)