diff options
| author | Richard M. Stallman | 1996-10-26 18:13:52 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1996-10-26 18:13:52 +0000 |
| commit | 0a6231f5fcbe2915a0458dade891c71c249dd016 (patch) | |
| tree | 4b57ea2f45e9b50affda281c9ed37883f67b68c8 | |
| parent | 5f65549e3f9db70dfffe763c9a037dbf010a8a8c (diff) | |
| download | emacs-0a6231f5fcbe2915a0458dade891c71c249dd016.tar.gz emacs-0a6231f5fcbe2915a0458dade891c71c249dd016.zip | |
(mouse-sel-set-selection-function): Doc fix.
Use x-select-text, for the primary selection.
(mouse-sel-get-selection-function):
Use x-cut-buffer-or-selection-value, for the primary selection.
| -rw-r--r-- | lisp/mouse-sel.el | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/lisp/mouse-sel.el b/lisp/mouse-sel.el index d3a63095bbc..fdcd9a3e623 100644 --- a/lisp/mouse-sel.el +++ b/lisp/mouse-sel.el | |||
| @@ -185,17 +185,24 @@ where SELECTION-NAME = name of selection | |||
| 185 | type for this selection should be stored.") | 185 | type for this selection should be stored.") |
| 186 | 186 | ||
| 187 | (defvar mouse-sel-set-selection-function | 187 | (defvar mouse-sel-set-selection-function |
| 188 | (if (fboundp 'x-set-selection) | 188 | (function (lambda (selection value) |
| 189 | 'x-set-selection) | 189 | (if (eq selection 'PRIMARY) |
| 190 | (x-select-text value) | ||
| 191 | (x-set-selection selection value)))) | ||
| 190 | "Function to call to set selection. | 192 | "Function to call to set selection. |
| 191 | Called with two arguments: | 193 | Called with two arguments: |
| 192 | 194 | ||
| 193 | SELECTION, the name of the selection concerned, and | 195 | SELECTION, the name of the selection concerned, and |
| 194 | VALUE, the text to store.") | 196 | VALUE, the text to store. |
| 197 | This sets the selection as well as the cut buffer for the older applications. | ||
| 198 | Use (setq mouse-sel-set-selection-function 'x-set-selection) if you don't care | ||
| 199 | for them.") | ||
| 195 | 200 | ||
| 196 | (defvar mouse-sel-get-selection-function | 201 | (defvar mouse-sel-get-selection-function |
| 197 | (if (fboundp 'x-get-selection) | 202 | (function (lambda (selection) |
| 198 | 'x-get-selection) | 203 | (if (eq selection 'PRIMARY) |
| 204 | (x-cut-buffer-or-selection-value) | ||
| 205 | (x-get-selection selection)))) | ||
| 199 | "Function to call to get the selection. | 206 | "Function to call to get the selection. |
| 200 | Called with one argument: | 207 | Called with one argument: |
| 201 | 208 | ||