evil-paste-pop broken with interprogram-paste-function

Mark Tran mark.tran at gmail.com
Sun Sep 8 10:35:39 CEST 2013


It looks like 'yank-pop' also doesn't behave properly with
'interprogram-paste-function' though in a different way—I have to call it
multiple times before it begins cycling. 'my-paste-pop' has the same
behavior as yank-pop.


On Sun, Sep 8, 2013 at 12:36 AM, Frank Fischer <frank-fischer at shadow-soft.de
> wrote:

> Am Sat, 7 Sep 2013 23:56:38 -0700
> schrieb Mark Tran <mark.tran at gmail.com>:
>
> > In my Emacs setup, I have 'interprogram-paste-function' set to a
> > function that returns the contents of the OS X system clipboard. This
> > prevents 'evil-paste-pop' and 'evil-paste-pop-next' from cycling
> > through the kill ring because the evil-paste-* functions call
> > 'current-kill', which first calls 'interprogram-paste-function'
> > before the kill ring. This causes evil-paste-pop to always paste the
> > same value from the system clipboard.
>
> Calling `current-kill` is the same as Emacs' `yank-pop` does, so I
> wonder if this problem also occurs if you use `yank-pop` (e.g. C-z to
> change to emacs-state and then M-y for yank-pop)?
>
> > Is there anyway to get this working properly with
> > interprogram-paste-function?
>
> You could try to write a new command that temporarily sets
> `interprogram-paste-function` to nil (untested):
>
> (defun my-paste-pop (count)
>   (interactive "p")
>   (let (interprogram-paste-function)
>     (evil-paste-pop count)))
>
> and then bind it to C-p
>
> (define-key evil-normal-state-map (kbd "C-p") 'my-paste-pop)
>
> Does this help?
>
> Best regards,
> Frank
>
>
> _______________________________________________
> implementations-list mailing list
> implementations-list at lists.ourproject.org
> https://lists.ourproject.org/cgi-bin/mailman/listinfo/implementations-list
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://lists.ourproject.org/pipermail/implementations-list/attachments/20130908/a0cc4b62/attachment.htm 


More information about the implementations-list mailing list