oae / gnome-shell-pano

Next-gen Clipboard Manager for Gnome Shell
https://extensions.gnome.org/extension/5278/pano/
GNU General Public License v2.0
1.11k stars 60 forks source link

feature: Show the icon of an app where the entity comes from #11

Closed marcinjahn closed 2 years ago

marcinjahn commented 2 years ago

It would be nice to see a small icon of an app where a given copied item comes from. It would help to distinguish the items on the list a bit.

Feature inspired by https://onmyway133.com/pastepal/.

marcinjahn commented 2 years ago

I'm not sure if that's even possible, do the copied items have an information about the source where they come from?

rmnscnce commented 2 years ago

In reply to @marcinjahn:

do the copied items have an information about the source where they come from

No, but it's straightforward to implement using the Shell API by querying the active window information when the copy request was done and then appending it into the ClipboardContent object. Sure, it will slow down the process but it should be negligible (it's probably how PastePal does it on macOS as well -- same concept with a different implementation detail).

oae commented 2 years ago

Thank you for the suggestion. I will look into it.

oae commented 2 years ago

As I checked, gnome-shell clipboard API doesn't expose the owner of the clipboard. Only relying on the focused window can be inconsistent. So I will not be implementing this feature.