From: Konstantin Kharlamov <hi-angel@yandex.ru>
To: 56325@debbugs.gnu.org
Subject: bug#56325: [REGRESSION] (clipboard-yank) always pastes from kill-ring after text copy
Date: Thu, 30 Jun 2022 16:48:19 +0300 [thread overview]
Message-ID: <a319d5f7117925c25c8beb67d69970217285311e.camel@yandex.ru> (raw)
After upgrade to latest development version at:
fb0d95984b: Put the obsoletion earlier in the *Help* buffer
I found out that using (clipboard-yank) and (x-clipboard-yank) when
`select-enable-clipboard` is set to t, after copying a text to
clipboard once, results in them pasting from kill-ring instead of
clipboard.
# Steps to reproduce
1. Create /tmp/.emacs file with the following content:
(setq select-enable-clipboard nil
inhibit-startup-screen t)
(defun clipboard-yank-test ()
(interactive)
(let ((select-enable-clipboard t))
(clipboard-yank)))
(global-set-key "\C-y" 'clipboard-yank-test)
(defun clipboard-copy-fixed ()
(interactive)
(let ((select-enable-clipboard t))
(clipboard-kill-ring-save (region-beginning)(region-end))))
(global-set-key "\M-w" 'clipboard-copy-fixed)
2. Launch `HOME=/tmp/ emacs`
3. [you're in a *scratch* buffer] Move caret till word "create" on the
2nd line, select it by pressing M-f, then copy to the system clipboard
by pressing M-w
4. Move caret to another word, e.g. "file"
5. Delete the word "file" by pressing M-d
5. Press C-y to paste the current clipboard content
## Expected
A word "create" will be inserted as it is in the system clipboard.
Note: (clipboard-yank-test) pastes from the system clipboard not the
kill-ring due to `select-enable-clipboard` being set locally to t.
## Actual
The word you deleted in *scratch* buffer will be inserted instead of
"create".
next reply other threads:[~2022-06-30 13:48 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-30 13:48 Konstantin Kharlamov [this message]
[not found] ` <handler.56325.B.165659692129643.ack@debbugs.gnu.org>
2022-06-30 21:01 ` bug#56325: [REGRESSION] (clipboard-yank) always pastes from kill-ring after text copy Konstantin Kharlamov
2022-07-01 2:23 ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-01 7:10 ` Konstantin Kharlamov
2022-07-01 8:27 ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a319d5f7117925c25c8beb67d69970217285311e.camel@yandex.ru \
--to=hi-angel@yandex.ru \
--cc=56325@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.