[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#28930: 24.5; cua-mode does not replace keyboard shortcuts in Edit me
From: |
Lars Ingebrigtsen |
Subject: |
bug#28930: 24.5; cua-mode does not replace keyboard shortcuts in Edit menu |
Date: |
Sat, 31 Jul 2021 18:19:49 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Lars Ingebrigtsen <larsi@gnus.org> writes:
> Let's see... this is from this stuff:
>
> (bindings--define-key menu [copy]
> ;; ns-win.el said: Substitute a Copy function that works better
> ;; under X (for GNUstep).
> `(menu-item "Copy" ,(if (featurep 'ns)
> 'ns-copy-including-secondary
> 'kill-ring-save)
> :enable mark-active
> :help "Copy text in region between mark and current
> position"
> :keys ,(if (featurep 'ns)
> "\\[ns-copy-including-secondary]"
> "\\[kill-ring-save]")))
>
> (etc)
>
> I guess we could add a case for cua-mode in the :keys here, too?
No, we can't -- that has to be computed dynamically, and :keys doesn't
allow that. I think?
I tried to use :filter, but it couldn't figure out how to use that to
return a dynamically generated menu item -- is that even possible?
Perhaps we should just allow :keys to be a lambda? Any opinions?
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no